opentelemetry-instrumentation-openai 0.46.1__py3-none-any.whl → 0.46.2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of opentelemetry-instrumentation-openai might be problematic. Click here for more details.

@@ -418,9 +418,15 @@ def set_data_attributes(traced_response: TracedData, span: Span):
418
418
  )
419
419
  tool_call_index += 1
420
420
  elif block_dict.get("type") == "reasoning":
421
- _set_span_attribute(
422
- span, f"{GEN_AI_COMPLETION}.0.reasoning", block_dict.get("summary")
423
- )
421
+ reasoning_summary = block_dict.get("summary")
422
+ if reasoning_summary is not None and reasoning_summary != []:
423
+ if isinstance(reasoning_summary, (dict, list)):
424
+ reasoning_value = json.dumps(reasoning_summary)
425
+ else:
426
+ reasoning_value = reasoning_summary
427
+ _set_span_attribute(
428
+ span, f"{GEN_AI_COMPLETION}.0.reasoning", reasoning_value
429
+ )
424
430
  # TODO: handle other block types, in particular other calls
425
431
 
426
432
 
@@ -1 +1 @@
1
- __version__ = "0.46.1"
1
+ __version__ = "0.46.2"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: opentelemetry-instrumentation-openai
3
- Version: 0.46.1
3
+ Version: 0.46.2
4
4
  Summary: OpenTelemetry OpenAI instrumentation
5
5
  License: Apache-2.0
6
6
  Author: Gal Kleinman
@@ -13,9 +13,9 @@ opentelemetry/instrumentation/openai/v0/__init__.py,sha256=FhpVbP8NqjN2We_srppZ_
13
13
  opentelemetry/instrumentation/openai/v1/__init__.py,sha256=oLst4xav77tTteZKXo59uyb-2IWqw_xOafaSMzTxq9g,13255
14
14
  opentelemetry/instrumentation/openai/v1/assistant_wrappers.py,sha256=oa5xYEDELFN9luvSn3y1xhSs37yRYY_Pwh6htqOs8gc,11297
15
15
  opentelemetry/instrumentation/openai/v1/event_handler_wrapper.py,sha256=AT-eDZOFP-K_mm-ecdgQaILoIsEiItZmtwzwAuse86Q,4350
16
- opentelemetry/instrumentation/openai/v1/responses_wrappers.py,sha256=AIvpkGC0yTdRRPVzjRDuRo8oAJD1_lBKvsSSxFbPqJs,28124
17
- opentelemetry/instrumentation/openai/version.py,sha256=mFmwJPEwG1jNjQaGSh3_xNo8JgOV3wGtKGQxe0qvmTo,23
18
- opentelemetry_instrumentation_openai-0.46.1.dist-info/METADATA,sha256=Tjeq9eQ23x1UA0mT-AAkHn6evo7YLaBVd453CIDyi00,2157
19
- opentelemetry_instrumentation_openai-0.46.1.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
20
- opentelemetry_instrumentation_openai-0.46.1.dist-info/entry_points.txt,sha256=vTBfiX5yXji5YHikuJHEOoBZ1TFdPQ1EI4ctd2pZSeE,93
21
- opentelemetry_instrumentation_openai-0.46.1.dist-info/RECORD,,
16
+ opentelemetry/instrumentation/openai/v1/responses_wrappers.py,sha256=7d6Z6rK6AoANgOMQajmrbJ7tZDq3uZpHRJP7sj545AU,28492
17
+ opentelemetry/instrumentation/openai/version.py,sha256=lWEdbG8IshPF1zUeQxPyfsi3uFhuXQmN7phOE5OaeI8,23
18
+ opentelemetry_instrumentation_openai-0.46.2.dist-info/METADATA,sha256=GOKwiZRHVr0E69yFINrk5m12pczRqg4CCbe8ns_PsiQ,2157
19
+ opentelemetry_instrumentation_openai-0.46.2.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
20
+ opentelemetry_instrumentation_openai-0.46.2.dist-info/entry_points.txt,sha256=vTBfiX5yXji5YHikuJHEOoBZ1TFdPQ1EI4ctd2pZSeE,93
21
+ opentelemetry_instrumentation_openai-0.46.2.dist-info/RECORD,,