Dooy / chatgpt-web-midjourney-proxy

One UI is all done with chatgpt web, midjourney, gpts,suno-v3,luma ; Simultaneous support Web / PWA / Linux / Win / MacOS platform
https://vercel.ddaiai.com
MIT License
3.99k stars 1.05k forks source link

[Feature Request] Add `Continue` button when ChatGPT message length is reached. #405

Open Sarkhad opened 2 weeks ago

Sarkhad commented 2 weeks ago

Given

When ChatGPT message length is reached Server-Sent Event contains finish_reason='length' instead of null or 'stop'.

data.detail.choices[0].finish_reason === 'length'

Acceptance criteria As a user, when ChatGPT response message length is reached, I wish to have clickable "Continue" button to let ChatGPT complete its response. As a user, I would like to see the continue button in the same place where the 'Stop Responding' one is seen.

Dooy commented 2 weeks ago

ok, You don't see this sign of data.detail.choices[0].finish_reason === 'length' all the time.

Sarkhad commented 2 weeks ago

ok, You don't see this sign of data.detail.choices[0].finish_reason === 'length' all the time.

Yes, I don't. But when the stream ends with finish_reason=length the button should appear.

{"id":"chatcmpl-xxx","object":"chat.completion.chunk","created":1718290711,"model":"gpt-4o-2024-05-13","system_fingerprint":"xxx","choices":[{"index":0,"delta":{},"logprobs":null,"finish_reason":"length"}]}
Dooy commented 2 weeks ago

Можете ли вы привести несколько примеров и моделей ключевых слов?

Sarkhad commented 2 weeks ago

Можете ли вы привести несколько примеров и моделей ключевых слов?

To trigger this behaviour just ask any OpenAI's model to generate an long response. The only difference is the last chunk contains 'length' instead of 'stop'.

image image

P. S. On the screenshots is a bit modified site.

bject":"chat.completion.chunk","created":1718291604,"model":"gpt-4o-2024-05-13","system_fingerprint":"fp_319be4768e","choices":[{"index":0,"delta":{"content":" effort"},"logprobs":null,"finish_reason":null}]} | 19:13:42.230 |     | message | {"id":"chatcmpl-9ZgQeD4GtxTkaLBvU8E89lKIOEXic","object":"chat.completion.chunk","created":1718291604,"model":"gpt-4o-2024-05-13","system_fingerprint":"fp_319be4768e","choices":[{"index":0,"delta":{"content":"."},"logprobs":null,"finish_reason":null}]} | 19:13:42.230 |     | message | {"id":"chatcmpl-9ZgQeD4GtxTkaLBvU8E89lKIOEXic","object":"chat.completion.chunk","created":1718291604,"model":"gpt-4o-2024-05-13","system_fingerprint":"fp_319be4768e","choices":[{"index":0,"delta":{},"logprobs":null,"finish_reason":"length"}]} | 19:13:42.230

Dooy commented 2 weeks ago

ok