Skip to content

Offer Continue when the output limit cuts a chat reply off - #574

Merged
m1ab0t merged 1 commit into
twinnydotdev:devfrom
officialasishkumar:feat/continue-cut-off-reply
Nov 16, 2026
Merged

m1ab0t merged 1 commit into
twinnydotdev:devfrom
officialasishkumar:feat/continue-cut-off-reply

Conversation

@officialasishkumar

Copy link
Copy Markdown
Contributor

Closes #156

When a backend ends a chat reply with finish_reason: "length" (the output token cap), the reply stops part-way and nothing tells the user.

  • ChatGeneration now records that on the reply's meta (cutOff).
  • The reply footer shows cut off, and the existing Continue button is offered on the last reply, as it already is for stopped replies and replies that ran out of tool steps. Continue asks the model to carry on exactly where it stopped without repeating itself.
  • Test: the flag is set for a length finish, and not for stop or for backends that report no reason.

Checked: tsc --noEmit and eslint on the touched files are clean; the new test passes.

When a backend ends a reply with finish_reason "length", the reply stops
part-way and nothing said so. The chat now records that on the reply's
meta (cutOff), marks it "cut off" in the footer and offers the existing
Continue button on it, as it already does for stopped replies and replies
that ran out of tool steps.

Adds a test that the flag is set for a length finish and not for stop or
for backends that report no reason.

Signed-off-by: Asish Kumar <officialasishkumar@gmail.com>
@chatgpt-codex-connector

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-13T05:02:22.634007Z
We couldn’t complete this review. Comment @codex review to try again.
9ae868c PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@rjmacarthy
rjmacarthy changed the base branch from main to dev November 16, 2026 11:39
@m1ab0t
m1ab0t merged commit 84e608d into twinnydotdev:dev Nov 16, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

In chat mode, add a "generate more" button when reaching the max token limit

2 participants