pyconverters-openai_vision 0.5.36__py3-none-any.whl → 0.5.38__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.
- pyconverters_openai_vision/__init__.py +1 -1
- pyconverters_openai_vision/openai_vision.py +2 -12
- {pyconverters_openai_vision-0.5.36.dist-info → pyconverters_openai_vision-0.5.38.dist-info}/METADATA +1 -1
- pyconverters_openai_vision-0.5.38.dist-info/RECORD +7 -0
- pyconverters_openai_vision-0.5.36.dist-info/RECORD +0 -7
- {pyconverters_openai_vision-0.5.36.dist-info → pyconverters_openai_vision-0.5.38.dist-info}/WHEEL +0 -0
- {pyconverters_openai_vision-0.5.36.dist-info → pyconverters_openai_vision-0.5.38.dist-info}/entry_points.txt +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"""OpenAIVision converter"""
|
|
2
|
-
__version__ = "0.5.
|
|
2
|
+
__version__ = "0.5.38"
|
|
@@ -147,10 +147,6 @@ class OpenAIVisionConverterBase(ConverterBase):
|
|
|
147
147
|
PREFIX: str = ""
|
|
148
148
|
oauth_token: OAuthToken = OAuthToken()
|
|
149
149
|
|
|
150
|
-
@classmethod
|
|
151
|
-
def is_model_gpt_5_model(cls, model: str) -> bool:
|
|
152
|
-
return "gpt-5" in model
|
|
153
|
-
|
|
154
150
|
def compute_args(self, params: OpenAIVisionBaseParameters, source: UploadFile, kind
|
|
155
151
|
) -> Dict[str, Any]:
|
|
156
152
|
data = source.file.read()
|
|
@@ -171,11 +167,10 @@ class OpenAIVisionConverterBase(ConverterBase):
|
|
|
171
167
|
},
|
|
172
168
|
binary_block
|
|
173
169
|
]})
|
|
174
|
-
max_tokens_param = 'max_completion_tokens' if self.is_model_gpt_5_model(params.model_str) else 'max_tokens'
|
|
175
170
|
kwargs = {
|
|
176
171
|
'model': params.model_str,
|
|
177
172
|
'messages': messages,
|
|
178
|
-
|
|
173
|
+
'max_tokens': params.max_tokens,
|
|
179
174
|
'temperature': params.temperature,
|
|
180
175
|
'top_p': params.top_p,
|
|
181
176
|
'n': params.n,
|
|
@@ -362,10 +357,6 @@ class OpenAIVisionProcessorBase(ProcessorBase):
|
|
|
362
357
|
PREFIX: str = ""
|
|
363
358
|
oauth_token: OAuthToken = OAuthToken()
|
|
364
359
|
|
|
365
|
-
@classmethod
|
|
366
|
-
def is_model_gpt_5_model(cls, model: str) -> bool:
|
|
367
|
-
return "gpt-5" in model
|
|
368
|
-
|
|
369
360
|
def compute_args(self, params: OpenAIVisionProcessorBaseParameters, source: str, kind
|
|
370
361
|
) -> Dict[str, Any]:
|
|
371
362
|
if kind.mime.startswith("image"):
|
|
@@ -384,11 +375,10 @@ class OpenAIVisionProcessorBase(ProcessorBase):
|
|
|
384
375
|
},
|
|
385
376
|
binary_block
|
|
386
377
|
]})
|
|
387
|
-
max_tokens_param = 'max_completion_tokens' if self.is_model_gpt_5_model(params.model_str) else 'max_tokens'
|
|
388
378
|
kwargs = {
|
|
389
379
|
'model': params.model_str,
|
|
390
380
|
'messages': messages,
|
|
391
|
-
|
|
381
|
+
'max_tokens': params.max_tokens,
|
|
392
382
|
'temperature': params.temperature,
|
|
393
383
|
'top_p': params.top_p,
|
|
394
384
|
'n': params.n,
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
pyconverters_openai_vision/__init__.py,sha256=3A5S776Ll53ppRREl4pWtKE_bidstJRi9FI6GEKawAU,52
|
|
2
|
+
pyconverters_openai_vision/openai_utils.py,sha256=XI4WYZ-EAVG0Vxd5yUDuZNDgEzqHJeriScxTUusi1oo,7740
|
|
3
|
+
pyconverters_openai_vision/openai_vision.py,sha256=1wrjAhTpHdldkcW8BtdZhUgKowJPAoFoP4lQjKPI9nA,23330
|
|
4
|
+
pyconverters_openai_vision-0.5.38.dist-info/entry_points.txt,sha256=NR0re-yebKKyhApky1I6nDQzjJQfEyfOkJlJju0Ngzo,404
|
|
5
|
+
pyconverters_openai_vision-0.5.38.dist-info/WHEEL,sha256=G2gURzTEtmeR8nrdXUJfNiB3VYVxigPQ-bEQujpNiNs,82
|
|
6
|
+
pyconverters_openai_vision-0.5.38.dist-info/METADATA,sha256=FlMVJfyWLJouofO0ECVmFnfNdsrThhUIh8oOMh7eoYg,2662
|
|
7
|
+
pyconverters_openai_vision-0.5.38.dist-info/RECORD,,
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
pyconverters_openai_vision/__init__.py,sha256=-BX6FHKC8AX-7vCq_-SC81FmeXDVkY1SIy4vU9f9-gU,52
|
|
2
|
-
pyconverters_openai_vision/openai_utils.py,sha256=XI4WYZ-EAVG0Vxd5yUDuZNDgEzqHJeriScxTUusi1oo,7740
|
|
3
|
-
pyconverters_openai_vision/openai_vision.py,sha256=Lp8g8KbTvRznOrC7dPRM-C9qmZcgzs-Kq6QidHtZwA4,23780
|
|
4
|
-
pyconverters_openai_vision-0.5.36.dist-info/entry_points.txt,sha256=NR0re-yebKKyhApky1I6nDQzjJQfEyfOkJlJju0Ngzo,404
|
|
5
|
-
pyconverters_openai_vision-0.5.36.dist-info/WHEEL,sha256=G2gURzTEtmeR8nrdXUJfNiB3VYVxigPQ-bEQujpNiNs,82
|
|
6
|
-
pyconverters_openai_vision-0.5.36.dist-info/METADATA,sha256=govETANuIkSFp_1AAH1t2AxwryMgupNpZ2VERpWhbyI,2662
|
|
7
|
-
pyconverters_openai_vision-0.5.36.dist-info/RECORD,,
|
{pyconverters_openai_vision-0.5.36.dist-info → pyconverters_openai_vision-0.5.38.dist-info}/WHEEL
RENAMED
|
File without changes
|
|
File without changes
|