Skip to main content

Sigil Python Framework Module: OpenAI Agents

sigil-sdk-openai-agents provides callback handlers that map OpenAI Agents lifecycle events into Sigil generation recorder lifecycles.

Installation

pip install sigil-sdk sigil-sdk-openai-agents
pip install openai-agents

Quickstart

from sigil_sdk import Client
from sigil_sdk_openai_agents import with_sigil_openai_agents_hooks

client = Client()
run_options = with_sigil_openai_agents_hooks(None, client=client, provider_resolver="auto")
# Runner.run(agent, input="...", hooks=run_options["hooks"])

Native hooks wiring

from sigil_sdk import Client
from sigil_sdk_openai_agents import with_sigil_openai_agents_hooks

client = Client()
run_options = with_sigil_openai_agents_hooks(None, client=client, provider_resolver="auto")
# Runner.run(agent, input="...", hooks=run_options["hooks"])

Conversation mapping

Conversation ID precedence:

  1. conversation_id / session_id / group_id
  2. thread_id
  3. deterministic fallback sigil:framework:openai-agents:<run_id>

Metadata and lineage

Required framework tags:

  • sigil.framework.name=openai-agents
  • sigil.framework.source=handler
  • sigil.framework.language=python

Metadata includes:

  • required: sigil.framework.run_type
  • optional: sigil.framework.run_id, sigil.framework.thread_id, sigil.framework.parent_run_id, sigil.framework.component_name, sigil.framework.retry_attempt, sigil.framework.event_id

Provider resolver

Resolver order: explicit provider option -> framework metadata -> model prefix inference -> custom.

Troubleshooting

  • If conversations are fragmented, pass stable session_id or conversation_id in callback metadata.
  • If provider is inferred as custom, set provider="openai" (or another provider) on handler init.
  • Always call client.shutdown() during teardown.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sigil_sdk_openai_agents-0.9.3.tar.gz (9.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sigil_sdk_openai_agents-0.9.3-py3-none-any.whl (7.4 kB view details)

Uploaded Python 3

File details

Details for the file sigil_sdk_openai_agents-0.9.3.tar.gz.

File metadata

  • Download URL: sigil_sdk_openai_agents-0.9.3.tar.gz
  • Upload date:
  • Size: 9.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for sigil_sdk_openai_agents-0.9.3.tar.gz
Algorithm Hash digest
SHA256 914d07f871e392602e3c986fcedf912e4b1edca467caa8391ed89525146fb211
MD5 30729be7e3d0cc79a8105173c0bf10c4
BLAKE2b-256 2acb7fb16dc12af6bded2ca6b0350d113e10c632cf97b6d8a5c6ae23c14b2bbc

See more details on using hashes here.

Provenance

The following attestation bundles were made for sigil_sdk_openai_agents-0.9.3.tar.gz:

Publisher: python-sdks-publish.yml on grafana/sigil-sdk

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sigil_sdk_openai_agents-0.9.3-py3-none-any.whl.

File metadata

File hashes

Hashes for sigil_sdk_openai_agents-0.9.3-py3-none-any.whl
Algorithm Hash digest
SHA256 ab5a444fd2a54464507ad6d6bf821a9e4568a71531925a7b7a29462cc8b760df
MD5 932bd7eb663584aa267df82cf9840b1e
BLAKE2b-256 b51fc8ad051df42cbc833b1f3b665e7bf86bd70ddb380139753ca30b953dd919

See more details on using hashes here.

Provenance

The following attestation bundles were made for sigil_sdk_openai_agents-0.9.3-py3-none-any.whl:

Publisher: python-sdks-publish.yml on grafana/sigil-sdk

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.9.3 This release

2 files

0.9.2

2 files

0.9.1

2 files

0.9.0

2 files

0.8.0

2 files

0.7.0

2 files

0.6.0

2 files

0.5.0

2 files

0.4.0

2 files

0.3.0

2 files

0.2.1

2 files

0.2.0

2 files

0.1.5

2 files

0.1.4

2 files

0.1.3

2 files

0.1.2

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page