njerschow/openai-api

How to use streams?

sabetAI opened this issue · 2 comments

If I set the stream parameter to true, how do I read from it and display it in real-time? The only methods available for me to hook into are then/catch/finally, wouldn't an on method help in this case?

Anyone?

Streams aren't natively supported by this package. I would suggest to ask the community here: https://community.openai.com/