The model seems correct. However I think you might be missing await in the following line:
const response = openai.createChatCompletion({
so it becomes const response = await openai.createChatCompletion({
You might also want to test it without the stream. I’m not familiar enough with this to get it running with stream on, but it’s a lot easier to debug problems like this with it off. It seems like response.data.choices[0].message
might be a different structure to the actual streamed response.