OpenAI icon indicating copy to clipboard operation
OpenAI copied to clipboard

StreamableQuery parity

Open kalafus opened this issue 1 year ago • 2 comments

make StreamableQuery symmetrically convert ChatQuery objects to non-streamable mode on the fly

What

ChatQuery initialized with stream = true can be used in .chats

Why

parity with non-streamable StreamableQuery being made streamable as needed.

Affected Areas

ChatQuery

kalafus avatar Feb 05 '24 03:02 kalafus

Quality Gate Passed Quality Gate passed

Issues
0 New issues

Measures
0 Security Hotspots
No data about Coverage
1.0% Duplication on New Code

See analysis details on SonarCloud

sonarqubecloud[bot] avatar Feb 15 '24 22:02 sonarqubecloud[bot]

as it stands, the presumption is that ChatQuery will be created as non-streamable, and needs be made streamable on-demand. could also, for example, take away the stream parameter at ChatQuery initialization. that might make more sense, as the stream parameter is perfunctory if it is being changed as needed.

another option could be to eliminate both the default to stream: false as well as the whole concept of the Streamable protocol. at present, setting stream to false is an illusion -- there is no such thing in this API, seeing as a new struct is created with stream: true whenever needed.

thoughts?

kalafus avatar Feb 16 '24 16:02 kalafus