node-chatgpt-api icon indicating copy to clipboard operation
node-chatgpt-api copied to clipboard

AI responds multiple times But only the last reply will be displayed and recorded.

Open Czx1235 opened this issue 1 year ago • 5 comments

Describe the bug When AI responds multiple times at once,All replies except for the first reply's first character will disappear, and only the last reply will be displayed and recorded. This is what I am looking for.But only for a moment image And then it became like this, and all the previous content disappeared.The cache file is the same. image

To Reproduce Steps to reproduce the behavior: 1.Set some special system messages 2.Let AI reply multiple times at once

Expected behavior All AI replies are displayed and stored

Screenshots image

Node.js version (please complete the following information):

  • OS:Windows 11
  • Version 19

Package version (please complete the following information):

  • 1.35.0

Additional context Allowing AI to respond multiple times at once with no more than 30 words can effectively bypass censorship.Maybe you can add this feature.

Czx1235 avatar Apr 18 '23 17:04 Czx1235

I tried to solve it myself.Thank you for your project. Here is the result. image And here is my modification. image image Perhaps this will be useful for your project. Anyway, thanks!

Czx1235 avatar Apr 19 '23 07:04 Czx1235

Feel free to submit a pull request, but otherwise I'll keep this issue open until it's fixed.

waylaidwanderer avatar Apr 19 '23 07:04 waylaidwanderer

I am not a professional, and there are still many bugs in the code I modified.So let's hope someone can fix it.

Czx1235 avatar Apr 19 '23 23:04 Czx1235

A PR would still be valuable.

kq514550 avatar May 02 '23 08:05 kq514550

Yes, PR is still valuable, but the main bug is not this. I tried to fix some on my own, but I am a novice on GitHub, so I am not very good at using it like pull request.I can only paste the code I have modified, sorry. Here. image image image image

Czx1235 avatar May 02 '23 08:05 Czx1235