Add openai-java v3.0+ instrumentation#9959
Add openai-java v3.0+ instrumentation#9959gh-worker-dd-mergequeue-cf854d[bot] merged 121 commits intomasterfrom
Conversation
…stead of forcing it
…d "streamed async request completion test with withRawResponse"
Call decorateWithResponse from the wrappers
Rename span resources to be aligned with trace-py Add http.client resource assertion
Test case renaming
Reorder tests by synch, async
Fix Embeddings fixture for the latestDepTest when base64
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 21025e87d0
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
dd-trace-core/src/main/java/datadog/trace/llmobs/writer/ddintake/LLMObsSpanMapper.java
Show resolved
Hide resolved
amarziali
left a comment
There was a problem hiding this comment.
I don't know the API in depth but the instrumentation looks ok from my standpoint.
Kyle-Verhoog
left a comment
There was a problem hiding this comment.
great stuff yury 👏
just found one major inconsistency with the tag prefix which i think might be responsible for a bunch of the behaviour we were seeing in the bugbash
...java/openai-java-3.0/src/main/java/datadog/trace/instrumentation/openai_java/CommonTags.java
Show resolved
Hide resolved
...ava-3.0/src/main/java/datadog/trace/instrumentation/openai_java/ChatCompletionDecorator.java
Outdated
Show resolved
Hide resolved
...enai-java-3.0/src/main/java/datadog/trace/instrumentation/openai_java/ResponseDecorator.java
Outdated
Show resolved
Hide resolved
...nai-java-3.0/src/main/java/datadog/trace/instrumentation/openai_java/EmbeddingDecorator.java
Outdated
Show resolved
Hide resolved
...nai-java-3.0/src/main/java/datadog/trace/instrumentation/openai_java/EmbeddingDecorator.java
Outdated
Show resolved
Hide resolved
...ava-3.0/src/main/java/datadog/trace/instrumentation/openai_java/ChatCompletionDecorator.java
Outdated
Show resolved
Hide resolved
...ai-java-3.0/src/main/java/datadog/trace/instrumentation/openai_java/CompletionDecorator.java
Outdated
Show resolved
Hide resolved
...ava-3.0/src/main/java/datadog/trace/instrumentation/openai_java/ChatCompletionDecorator.java
Show resolved
Hide resolved
...nai-java-3.0/src/main/java/datadog/trace/instrumentation/openai_java/EmbeddingDecorator.java
Outdated
Show resolved
Hide resolved
Thanks, Kyle! The tag prefix is stripped by the LLMObsSpanMapper, which doesn't affect the cost calculation. I think the prefix was introduced to scope and hide LLMObs-specific data when passed via span tags. This didn't change with this PR. |
|
/merge |
|
View all feedbacks in Devflow UI.
The expected merge time in
|
0253f31
into
master
What Does This Do
Adds openai-java v3.0+ instrumentation for completions, chat completions, embeddings, and responses.
Motivation
Additional Notes
Contributor Checklist
type:and (comp:orinst:) labels in addition to any useful labelsclose,fixor any linking keywords when referencing an issue.Use
solvesinstead, and assign the PR milestone to the issueJira ticket: AIDM-163