“The content to listen for a response at https://platform.openai.com/docs/guides/text-generation/chat-completions-response-format operates as response.choices[0].message.content in the latest OpenAI package. I might be wrong, but if I am right, it seems that the document needs to be updated.”
Hi! and welcome!
Maybe you oversaw the brackets
choices = [{}],
choices [0] = {}