opentelemetry-instrumentation-openai 0.38.0__py3-none-any.whl → 0.38.1__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.

@@ -5,8 +5,6 @@ from opentelemetry.instrumentation.instrumentor import BaseInstrumentor
5
5
 
6
6
  from opentelemetry.instrumentation.openai.shared.config import Config
7
7
  from opentelemetry.instrumentation.openai.utils import is_openai_v1
8
- from opentelemetry.instrumentation.openai.v0 import OpenAIV0Instrumentor
9
- from opentelemetry.instrumentation.openai.v1 import OpenAIV1Instrumentor
10
8
 
11
9
  _instruments = ("openai >= 0.27.0",)
12
10
 
@@ -38,12 +36,20 @@ class OpenAIInstrumentor(BaseInstrumentor):
38
36
 
39
37
  def _instrument(self, **kwargs):
40
38
  if is_openai_v1():
39
+ from opentelemetry.instrumentation.openai.v1 import OpenAIV1Instrumentor
40
+
41
41
  OpenAIV1Instrumentor().instrument(**kwargs)
42
42
  else:
43
+ from opentelemetry.instrumentation.openai.v0 import OpenAIV0Instrumentor
44
+
43
45
  OpenAIV0Instrumentor().instrument(**kwargs)
44
46
 
45
47
  def _uninstrument(self, **kwargs):
46
48
  if is_openai_v1():
49
+ from opentelemetry.instrumentation.openai.v1 import OpenAIV1Instrumentor
50
+
47
51
  OpenAIV1Instrumentor().uninstrument(**kwargs)
48
52
  else:
53
+ from opentelemetry.instrumentation.openai.v0 import OpenAIV0Instrumentor
54
+
49
55
  OpenAIV0Instrumentor().uninstrument(**kwargs)
@@ -1 +1 @@
1
- __version__ = "0.38.0"
1
+ __version__ = "0.38.1"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: opentelemetry-instrumentation-openai
3
- Version: 0.38.0
3
+ Version: 0.38.1
4
4
  Summary: OpenTelemetry OpenAI instrumentation
5
5
  License: Apache-2.0
6
6
  Author: Gal Kleinman
@@ -1,4 +1,4 @@
1
- opentelemetry/instrumentation/openai/__init__.py,sha256=ly0ZPoOTAVRo1f0EeKfyTWj8_HLna3kZfIo9GWgUJk4,1888
1
+ opentelemetry/instrumentation/openai/__init__.py,sha256=g_RyqxN0DEaPegyaFfoZVskxnaPMGx6Yrc9wZvkx7r8,2086
2
2
  opentelemetry/instrumentation/openai/shared/__init__.py,sha256=Ha5oEgK0VrdTu10wdxs-Dqwcv2fbqw1mqlXlsngH7kg,9493
3
3
  opentelemetry/instrumentation/openai/shared/chat_wrappers.py,sha256=YYEYBSyqcOSlb5VNORs3LL-J749sk9ZZbOpCn8JikIU,28306
4
4
  opentelemetry/instrumentation/openai/shared/completion_wrappers.py,sha256=de35aM1Bjsk3GsfNAdu009OF_mdeFB7H_jBsc4LOKY0,7101
@@ -10,8 +10,8 @@ opentelemetry/instrumentation/openai/v0/__init__.py,sha256=02-bXv0aZbscMYO2W3jsH
10
10
  opentelemetry/instrumentation/openai/v1/__init__.py,sha256=B2Ut0X14KQS5in_0jLBMCvXQK73SqBy2rBFIDk5ZRkc,8688
11
11
  opentelemetry/instrumentation/openai/v1/assistant_wrappers.py,sha256=08ZB03chvpzF-v2dtpHKCToJmm5ztYSwKhBq3pbpPlI,7191
12
12
  opentelemetry/instrumentation/openai/v1/event_handler_wrapper.py,sha256=4HsnPwR450NA5w-KDgMfQjK8U4do_M-sMMPU4LjXyiQ,3444
13
- opentelemetry/instrumentation/openai/version.py,sha256=GJwyrcH1eJOX_p_9H-LSIMO2ADxtxl7estBuQ7PgzCM,23
14
- opentelemetry_instrumentation_openai-0.38.0.dist-info/METADATA,sha256=qEvV3MsmEgcjTd9F4I4bk0dNRLrgYkeACMdUTxq9NBY,2186
15
- opentelemetry_instrumentation_openai-0.38.0.dist-info/WHEEL,sha256=IYZQI976HJqqOpQU6PHkJ8fb3tMNBFjg-Cn-pwAbaFM,88
16
- opentelemetry_instrumentation_openai-0.38.0.dist-info/entry_points.txt,sha256=vTBfiX5yXji5YHikuJHEOoBZ1TFdPQ1EI4ctd2pZSeE,93
17
- opentelemetry_instrumentation_openai-0.38.0.dist-info/RECORD,,
13
+ opentelemetry/instrumentation/openai/version.py,sha256=tv6kGs6brWBL9uSYr_0VbHxU9OxLYR2pNofcLT9Ti3k,23
14
+ opentelemetry_instrumentation_openai-0.38.1.dist-info/METADATA,sha256=PHvoA4_yXARoM6aB37nfORQdSGFEReWKdgXL_bLUYBs,2186
15
+ opentelemetry_instrumentation_openai-0.38.1.dist-info/WHEEL,sha256=IYZQI976HJqqOpQU6PHkJ8fb3tMNBFjg-Cn-pwAbaFM,88
16
+ opentelemetry_instrumentation_openai-0.38.1.dist-info/entry_points.txt,sha256=vTBfiX5yXji5YHikuJHEOoBZ1TFdPQ1EI4ctd2pZSeE,93
17
+ opentelemetry_instrumentation_openai-0.38.1.dist-info/RECORD,,