#Inconsistent image with gpt-4-vision-preview

1 messages · Page 1 of 1 (latest)

keen tundra
#

When I use the API with gpt-4-vision-preview and I pass an image, the image is not always being detected. As a response I get that it can't help me without an image. I tested the base64, and am certain that it is correct.

type: 'image_url',
image_url: {
    url: `data:image/png;base64,${imageData}`,
    detail: 'low'
},
chilly ridgeBOT
#

Hi @keen tundra. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave:

#

Based on the information provided in the extracts, it seems like there might be an issue with the way you're structuring your request. The correct format for sending base64 images to the GPT-4 Vision API is as follows:

{
"type": "image_url", 
"image_url": 
{
      "url": "data:image/jpeg;base64,iVBORw0KGgoAAAANSUhEUgAA…"
}
}

This was mentioned in a forum post (https://community.openai.com/t/495864) on the OpenAI community.

Also, it's important to note that the GPT-4 Vision API does not currently support the detail parameter as per the extract (https://community.openai.com/t/477563) from another forum post.

If you're still encountering issues, it might be helpful to review the vision developer guide (https://platform.openai.com/docs/guides/vision) and the help article (https://help.openai.com/en/articles/8555496-gpt-4-vision-api) on using GPT-4 with images.

Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: