ztjhz / BetterChatGPT

An amazing UI for OpenAI's ChatGPT (Website + Windows + MacOS + Linux)
http://bettergpt.chat/
Creative Commons Zero v1.0 Universal
8.2k stars 2.77k forks source link

How can I increase the typing speed of the output - GPT4 ? #347

Closed magedhelmy1 closed 1 year ago

magedhelmy1 commented 1 year ago

Hi, I was wondering if there is somewhere in the code where can I tweak the typing speed or make it paste the output in chunks like it is in GPT4-32k. Thank you! :)

mariodian commented 1 year ago

https://github.com/ztjhz/BetterChatGPT/blob/6a022d94249e5f7f6ba67de3aeac5d87a5aa7d45/src/api/api.ts#L82-L91

stream: false response is returned as one big chunk when model stops generating

stream: true response is returned in numerous smaller chunks as it is generated

like it is in GPT4-32k

That's just a model with larger context size. It has nothing to do with how data is returned to user.

magedhelmy1 commented 1 year ago

Hi Mariodian,

having

stream: false,

gives the error

Cannot read properties of undefined (reading 'content')
mariodian commented 1 year ago

Yeah, it makes sense. You'd have to heavily modify useSubmit.ts which currently only reads from stream.