stream parameter to True within the chat.completions.create method. The API then returns an iterable containing the chunks of the message.
Similarly, the same can be done in TypeScript by setting the stream property to true within the chat.completions.create method.

