push#484
Conversation
…tize fix(openai): strip leaked tool result markers
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 882d0d16ac
ℹ️ 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".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if closeLoc == nil { | ||
| *inside = true | ||
| break |
There was a problem hiding this comment.
Avoid suppressing all text after unmatched <|Tool|>
When a text chunk contains an opening tool marker without a matching close marker in the same or later chunks (for example, a literal token example like <|Tool|> or a close variant not matched by leakedToolResultCloseMarkerPattern), this branch flips inside to true and causes every subsequent chunk to be discarded from visible output. In streaming paths this can truncate the rest of an otherwise valid assistant response, rather than just stripping leaked tool payload.
Useful? React with 👍 / 👎.
💻 变更类型 | Change Type
🔀 变更说明 | Description of Change
push
📝 补充信息 | Additional Information