You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Bug description
When trying to send an image to any provider (that supports vision), error 500 occurs, although there is no error in the GUI, and everything works. Also, with a simple text message, everything works.
Screenshots
Environment
3.10
Russia
Additional context
from g4f.client import Client
from g4f.Provider.Blackbox import Blackbox
client = Client(
provider=Blackbox
)
response = client.chat.completions.create(
model="blackbox",
messages=[{"role": "user", "content": "What are on this image?"}],
image=open("image.png", "rb")
)
print(response.choices[0].message.content)
Traceback (most recent call last): File "C:\Projects\FreeMultimodalChat\chat.py", line 7, in <module> response = client.chat.completions.create( File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\g4f\client\client.py", line 118, in create return response if stream else next(response) File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\g4f\client\client.py", line 57, in iter_append_model_and_provider for chunk in response: File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\g4f\client\client.py", line 29, in iter_response for idx, chunk in enumerate(response): File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\g4f\providers\base_provider.py", line 223, in create_completion yield loop.run_until_complete(await_callback(gen.__anext__)) File "C:\Users\logaa\AppData\Local\Programs\Python\Python310\lib\asyncio\base_events.py", line 649, in run_until_complete return future.result() File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\g4f\providers\base_provider.py", line 52, in await_callback return await callback() File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\g4f\Provider\Blackbox.py", line 71, in create_async_generator response.raise_for_status() File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\aiohttp\client_reqrep.py", line 1088, in raise_for_status raise ClientResponseError( aiohttp.client_exceptions.ClientResponseError: 500, message='Internal Server Error', url=URL('https://www.blackbox.ai/api/chat')
The text was updated successfully, but these errors were encountered:
Bug description
When trying to send an image to any provider (that supports vision), error 500 occurs, although there is no error in the GUI, and everything works. Also, with a simple text message, everything works.
Screenshots
Environment
Additional context
Traceback (most recent call last): File "C:\Projects\FreeMultimodalChat\chat.py", line 7, in <module> response = client.chat.completions.create( File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\g4f\client\client.py", line 118, in create return response if stream else next(response) File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\g4f\client\client.py", line 57, in iter_append_model_and_provider for chunk in response: File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\g4f\client\client.py", line 29, in iter_response for idx, chunk in enumerate(response): File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\g4f\providers\base_provider.py", line 223, in create_completion yield loop.run_until_complete(await_callback(gen.__anext__)) File "C:\Users\logaa\AppData\Local\Programs\Python\Python310\lib\asyncio\base_events.py", line 649, in run_until_complete return future.result() File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\g4f\providers\base_provider.py", line 52, in await_callback return await callback() File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\g4f\Provider\Blackbox.py", line 71, in create_async_generator response.raise_for_status() File "C:\Projects\FreeMultimodalChat\.venv\lib\site-packages\aiohttp\client_reqrep.py", line 1088, in raise_for_status raise ClientResponseError( aiohttp.client_exceptions.ClientResponseError: 500, message='Internal Server Error', url=URL('https://www.blackbox.ai/api/chat')
The text was updated successfully, but these errors were encountered: