continue icon indicating copy to clipboard operation
continue copied to clipboard

Sending images to gpt-4-turbo returns error

Open evertjr opened this issue 10 months ago • 1 comments

Before submitting your bug report

Relevant environment info

- OS: macOS
- Continue: Preview
- IDE: vscode

Description

When using GPT-4-Turbo as a model for openai, sending a image returns a error, the image type should be image_url instead of ImageUrl. When using GPT-4-Turbo-Vision-Preview it works but this model is outdated now as the latest GPT-4 Turbo supports image input as well.

To reproduce

in config json:

{
  "title": "GPT-4-Turbo",
  "provider": "openai",
  "apiKey": "key",
  "model": "gpt-4-turbo"
},

1 - attach an image in the chat area 2 - Send it 3 - A popup error appears

Log output

HTTP 400 Bad Request from https://api.openai.com/v1/chat/completions  {   "error": {     "message": "Invalid value: 'imageUrl'. Supported values are: 'text' and 'image_url'.",     "type": "invalid_request_error",     "param": "messages[4].content[0].type",     "code": "invalid_value"   } }

evertjr avatar Apr 28 '24 15:04 evertjr

@evertjr just fixed here (https://github.com/continuedev/continue/commit/04d8d0e7650de13b5479848f24b316af82d32127). I'll release a new version later today

sestinj avatar Apr 28 '24 15:04 sestinj

I just realize that sending images is a feature of Continue over Microsoft copilot, which has not supported the feature yet.

dbsxdbsx avatar Jun 04 '24 01:06 dbsxdbsx