cohere-python icon indicating copy to clipboard operation
cohere-python copied to clipboard

Flush stdout in chat_stream example in README

Open srithon opened this issue 1 year ago • 1 comments

By default, without explicitly flushing stdout, Python only flushes the output buffer when it encounters newlines. This makes it look like generations are only being returned line-by-line. This misunderstanding led me to file this issue under the Golang SDK, wrongly thinking that this was an issue with the Cohere SDK as a whole rather than just being a byproduct of Python's output buffering.

srithon avatar Apr 28 '24 00:04 srithon

CLA assistant check
All committers have signed the CLA.

CLAassistant avatar Apr 28 '24 00:04 CLAassistant