Getting error message when try to input an image

An error message of “TypeError: Object of type bytes is not JSON serializable” is received as trying to input an image as raw bytes.

with open('download.png', 'rb') as file:
    raw_bytes =
content = ["Describe the image!"]
content.append({"image": raw_bytes})
response = openai.ChatCompletion.create(
                    {"role": "system", "content": "You are a helpful assistant."},
                    {"role": "user", "content": content}

This feature is not operational yet even with the new model, AFAIK…

It seems so… However, this feature was shown in the demo.

Right. They’re rolling it out slowly, though, I believe.

Patience is a virtue! :wink:

I’m sure it’ll be here soon…

Keep waiting…
Hope to see soon.

1 Like