After switching to GPT-3 from GPT-4o, for example, if there is an image in the conversation history, the OpenAI API raises the following error:
openai.BadRequestError: Error code: 400 - {'error': {'message': 'Invalid content type. image_url is only supported by certain models.', 'type': 'invalid_request_error', 'param': 'messages.[3].content.[1].type', 'code': None}}
A possible solution is to discard images from the context after switching to a non-multimodal model, aiming to preserve the current context with the previous model.
After switching to GPT-3 from GPT-4o, for example, if there is an image in the conversation history, the OpenAI API raises the following error:
openai.BadRequestError: Error code: 400 - {'error': {'message': 'Invalid content type. image_url is only supported by certain models.', 'type': 'invalid_request_error', 'param': 'messages.[3].content.[1].type', 'code': None}}
A possible solution is to discard images from the context after switching to a non-multimodal model, aiming to preserve the current context with the previous model.