Skip to content

Commit 0f92478

Browse files
feat(genai-openai): OpenAI responses extractors (#4337)
* wip: pydantic based responses api attributes extraction. * polish: fixing the linting around files. * refactor: update changelog. * polish: removing pydantic hard dependency and making pydantic version compatible with openai supported version. * wip: tox validation for pydantic 1.x version. * generated new workflows. * adding the pydantic test to new test file and removing old files. * wip: generated workflows. * wip: removed unwanted truthiness checks and simplified the test suite. * polish: fixed precommit. --------- Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>
1 parent af11fc7 commit 0f92478

File tree

6 files changed

+864
-0
lines changed

6 files changed

+864
-0
lines changed

.github/workflows/test.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -252,6 +252,25 @@ jobs:
252252
- name: Run tests
253253
run: tox -e py314-test-instrumentation-openai-v2-latest -- -ra
254254

255+
py313-test-instrumentation-openai-v2-pydantic1_ubuntu-latest:
256+
name: instrumentation-openai-v2-pydantic1 3.13 Ubuntu
257+
runs-on: ubuntu-latest
258+
timeout-minutes: 30
259+
steps:
260+
- name: Checkout repo @ SHA - ${{ github.sha }}
261+
uses: actions/checkout@v4
262+
263+
- name: Set up Python 3.13
264+
uses: actions/setup-python@v5
265+
with:
266+
python-version: "3.13"
267+
268+
- name: Install tox
269+
run: pip install tox-uv
270+
271+
- name: Run tests
272+
run: tox -e py313-test-instrumentation-openai-v2-pydantic1 -- -ra
273+
255274
pypy3-test-instrumentation-openai-v2-oldest_ubuntu-latest:
256275
name: instrumentation-openai-v2-oldest pypy-3.9 Ubuntu
257276
runs-on: ubuntu-latest

instrumentation-genai/opentelemetry-instrumentation-openai-v2/CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1919
([#4280](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/4280))
2020
- Add async wrappers for OpenAI Responses API streams and response stream managers
2121
([#4325](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/4325))
22+
- Add strongly typed Responses API extractors with validation and content
23+
extraction improvements
24+
([#4337](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/4337))
2225

2326
## Version 2.3b0 (2025-12-24)
2427

0 commit comments

Comments
 (0)