Skip to content

Commit 0ea0849

Browse files
authored
HYBIM-696: Fix openai-v2 PyPI page links and README (#333)
- Update PyPI badge to splunk-otel-instrumentation-openai - Fix pip install command to use correct Splunk package name - Update References link to SDOT GitHub repo - Fix project URLs in pyproject.toml to signalfx/splunk-otel-python-contrib
1 parent e3df1e1 commit 0ea0849

3 files changed

Lines changed: 31 additions & 7 deletions

File tree

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

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1515
- Add `gen_ai.request.stream` attribute for streaming requests
1616
- Add `gen_ai.response.time_to_first_chunk` attribute and metric for streaming requests
1717

18+
### Fixed
19+
20+
- Fix PyPI badge, install command, and references in README.rst to use correct
21+
`splunk-otel-instrumentation-openai` package name instead of upstream
22+
- Fix project URLs in pyproject.toml to point to SDOT repo (`signalfx/splunk-otel-python-contrib`)
23+
1824
### Changed
1925

2026
- **Always populate messages and tool arguments on Python objects**`input_messages`, `output_messages`, and tool call `arguments` are now always set on `LLMInvocation`/`ToolCall` regardless of `OTEL_INSTRUMENTATION_GENAI_CAPTURE_MESSAGE_CONTENT`. The emitter layer controls what reaches telemetry, enabling evaluators to access full content even in `NO_CONTENT` mode.
@@ -34,7 +40,7 @@ Initial release of `splunk-otel-instrumentation-openai` package.
3440
- Update tool call handling
3541
([#135](https://github.com/signalfx/splunk-otel-python-contrib/pull/135))
3642
- Add suppression key handling
37-
([#155](https://github.com/signalfx/splunk-otel-python-contrib/pull/135))
43+
([#155](https://github.com/signalfx/splunk-otel-python-contrib/pull/155))
3844
- Move events/logs and metrics to handler-based emitters
3945
([#158](https://github.com/signalfx/splunk-otel-python-contrib/pull/158))
4046
- Fix service tier attribute names: use `GEN_AI_OPENAI_REQUEST_SERVICE_TIER` for request

instrumentation-genai/opentelemetry-instrumentation-openai-v2/README.rst

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ OpenTelemetry OpenAI Instrumentation
33

44
|pypi|
55

6-
.. |pypi| image:: https://badge.fury.io/py/opentelemetry-instrumentation-openai-v2.svg
7-
:target: https://pypi.org/project/opentelemetry-instrumentation-openai-v2/
6+
.. |pypi| image:: https://badge.fury.io/py/splunk-otel-instrumentation-openai.svg
7+
:target: https://pypi.org/project/splunk-otel-instrumentation-openai/
88

99
This library allows tracing LLM requests and logging of messages made by the
1010
`OpenAI Python API library <https://pypi.org/project/openai/>`_. It also captures
@@ -40,7 +40,7 @@ If your application is already instrumented with OpenTelemetry, add this
4040
package to your requirements.
4141
::
4242

43-
pip install opentelemetry-instrumentation-openai-v2
43+
pip install splunk-otel-instrumentation-openai
4444

4545
If you don't have an OpenAI application, yet, try our `examples <examples>`_
4646
which only need a valid OpenAI API key.
@@ -89,6 +89,24 @@ Message content such as the contents of the prompt, completion, function argumen
8989
are not captured by default. To capture message content as log events, set the environment variable
9090
`OTEL_INSTRUMENTATION_GENAI_CAPTURE_MESSAGE_CONTENT` to `true`.
9191

92+
See the `upstream OpenTelemetry documentation <https://github.com/open-telemetry/opentelemetry-python-contrib/tree/main/instrumentation-genai/opentelemetry-instrumentation-openai-v2#enabling-message-content>`_ for more details.
93+
94+
Suppressing nested instrumentation
95+
***********************************
96+
97+
When using multiple instrumentations together (e.g., LangChain + OpenAI), the higher-level
98+
instrumentation automatically sets ``SUPPRESS_LANGUAGE_MODEL_INSTRUMENTATION_KEY`` in the
99+
OpenTelemetry context to prevent duplicate spans for the same underlying LLM call.
100+
101+
This is handled transparently — **no user configuration is needed**. For example, when
102+
LangChain instrumentation is active alongside OpenAI instrumentation, you will see
103+
LangChain spans without redundant nested OpenAI spans.
104+
105+
.. note::
106+
107+
This is not an environment variable and cannot be configured for zero-code instrumentation.
108+
It is a context key managed programmatically by instrumentation libraries.
109+
92110
Uninstrument
93111
************
94112

@@ -106,7 +124,7 @@ To uninstrument clients, call the uninstrument method:
106124
107125
References
108126
----------
109-
* `OpenTelemetry OpenAI Instrumentation <https://opentelemetry-python-contrib.readthedocs.io/en/latest/instrumentation-genai/openai.html>`_
127+
* `Splunk OpenTelemetry OpenAI Instrumentation <https://github.com/signalfx/splunk-otel-python-contrib/tree/main/instrumentation-genai/opentelemetry-instrumentation-openai-v2>`_
110128
* `OpenTelemetry Project <https://opentelemetry.io/>`_
111129
* `OpenTelemetry Python Examples <https://github.com/open-telemetry/opentelemetry-python/tree/main/docs/examples>`_
112130

instrumentation-genai/opentelemetry-instrumentation-openai-v2/pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ instruments = [
3535
openai = "opentelemetry.instrumentation.openai_v2:OpenAIInstrumentor"
3636

3737
[project.urls]
38-
Homepage = "https://github.com/open-telemetry/opentelemetry-python-contrib/tree/main/instrumentation-genai/opentelemetry-instrumentation-openai-v2"
39-
Repository = "https://github.com/open-telemetry/opentelemetry-python-contrib"
38+
Homepage = "https://github.com/signalfx/splunk-otel-python-contrib/tree/main/instrumentation-genai/opentelemetry-instrumentation-openai-v2"
39+
Repository = "https://github.com/signalfx/splunk-otel-python-contrib"
4040

4141
[tool.hatch.version]
4242
path = "src/opentelemetry/instrumentation/openai_v2/version.py"

0 commit comments

Comments
 (0)