Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OpenAI - update semantic conventions to the latest version, write logs based events instead of span events #2925

Merged
merged 14 commits into from
Oct 30, 2024

Conversation

lmolkova
Copy link
Contributor

@lmolkova lmolkova commented Oct 26, 2024

Description

  • Update OpenAI semantic conventions to the 1.28.0
    • changes span events to log based events
    • adds a few new openai-specific attributes
    • adds opt-in flag for event contents
  • Add tests

TODOs:

  • we need opt-in flag for contents
  • changelog

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

Does This PR Require a Core Repo Change?

  • Yes. - Link to PR:
  • No.

Checklist:

See contributing.md for styleguide, changelog guidelines, and more.

  • Followed the style guidelines of this project
  • Changelogs have been updated
  • Unit tests have been added
  • Documentation has been updated

@lmolkova lmolkova requested a review from a team as a code owner October 26, 2024 07:59
CONTRIBUTING.md Outdated Show resolved Hide resolved
@lmolkova lmolkova changed the title [WIP] OpenAI - update semantic conventions to the latest version, write logs based events instead of span events OpenAI - update semantic conventions to the latest version, write logs based events instead of span events Oct 28, 2024
Copy link
Contributor

@lzchen lzchen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@lmolkova lmolkova force-pushed the openai-update-semconv-to-latest branch from 9baa3d7 to 70eed99 Compare October 29, 2024 20:25
Copy link
Contributor

@karthikscale3 karthikscale3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looking good. nice work @lmolkova

@alizenhom
Copy link

looking good, thanks for doing this @lmolkova

lmolkova and others added 5 commits October 30, 2024 08:58
…entelemetry/instrumentation/openai_v2/utils.py

Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>
…pen-telemetry#2909)

httpx: rewrote patching to use wrapt instead of subclassing client

Porting of httpx instrumentation to patch async transport methods instead of substituting the client. That is because the current approach will instrument httpx by instantianting another client with a custom transport class and this will race with code already subclassing. This one uses wrapt to patch the default httpx transport classes.

---------

Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>
@lzchen lzchen merged commit 07c3324 into open-telemetry:main Oct 30, 2024
536 checks passed
@lmolkova lmolkova deleted the openai-update-semconv-to-latest branch November 7, 2024 20:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants