Repository navigation
fix(plugins): improve tool schemas to reduce model parse failures - #222
Conversation
- bash: stronger `justification` wording in description and schema. - batch: accept `tool_uses` as an alias for `tool_calls` and clarify the array item shape, fixing the common provider envelope mismatch. - edit/multiedit: add `old_string`/`new_string` descriptions to the schema; make `path` required at the object level. - grep: mark `pattern` required at the object level and add parameter descriptions. - read: mark `path` required at the object level. - todo_write: add an explicit `status` enum description. - Regenerate `n00n-token-profile/baselines/cold_start.json` to account for the intentional schema/prompt growth.
|
Warning Review limit reached
Next review available in: 32 minutes You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (9)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_ea5539fa-191b-4273-bf20-33d9fec24763) |
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.Scanned FilesNone |
Add the missing changelog.d fragment for this PR.
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_2beda632-0ace-4a10-8dea-cbcf8875cf8e) |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_7c16dfb4-42ae-4ce3-8b0b-5fb3c21e8a06) |
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 6d9285d4d7
ℹ️ 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".
|
@cursor review |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
Autofix Details
Bugbot Autofix prepared a fix for the issue found in the latest run.
- ✅ Fixed: Batch restore ignores tool_uses alias
- restore and header now read tool_calls or the tool_uses alias from persisted raw input, so reopen rebuilds children and the tool-count header.
You can send follow-ups to the cloud agent here.
Schema validation remaps tool_uses to tool_calls before the handler runs, but restore and header receive persisted raw model JSON. Read either key so reopen rebuilds children and the tool count header.
|
@codex review |
|
@cursor review |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 787688c. Configure here.
|
Codex Review: Didn't find any major issues. 🚀 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
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". |
41593d1 to
f8ad769
Compare
|
@codex review |
|
@cursor review |
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_58438a82-fb62-40fa-9d26-ddf36f9d8508) |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f8ad769e7a
ℹ️ 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".
There was a problem hiding this comment.
Criterion
Details
| Benchmark suite | Current: 5c34bc2 | Previous: 84c2c28 | Ratio |
|---|---|---|---|
fib/jit_mlua_hook |
6831839 ns/iter (± 276715) |
8426589 ns/iter (± 110410) |
0.81 |
fib/jit_watchdog |
2246489 ns/iter (± 40437) |
1717091 ns/iter (± 25793) |
1.31 |
fib/jit_none |
2251775 ns/iter (± 63327) |
1717158 ns/iter (± 12889) |
1.31 |
fib/interp_mlua_hook |
8263465 ns/iter (± 180341) |
9475873 ns/iter (± 25319) |
0.87 |
fib/interp_watchdog |
4350687 ns/iter (± 26262) |
3377220 ns/iter (± 11487) |
1.29 |
fib/interp_none |
4338113 ns/iter (± 83661) |
3350648 ns/iter (± 36411) |
1.29 |
buffer_rw/jit_mlua_hook |
586214 ns/iter (± 5133) |
856795 ns/iter (± 2515) |
0.68 |
buffer_rw/jit_watchdog |
192493 ns/iter (± 644) |
104862 ns/iter (± 23251) |
1.84 |
buffer_rw/jit_none |
192958 ns/iter (± 2398) |
104660 ns/iter (± 7010) |
1.84 |
buffer_rw/interp_mlua_hook |
1070279 ns/iter (± 25623) |
1260740 ns/iter (± 3130) |
0.85 |
buffer_rw/interp_watchdog |
619919 ns/iter (± 9727) |
532122 ns/iter (± 990) |
1.16 |
buffer_rw/interp_none |
605292 ns/iter (± 10616) |
531006 ns/iter (± 1202) |
1.14 |
splash_render_120x40 |
81290 ns/iter (± 1511) |
65764 ns/iter (± 200) |
1.24 |
splash_render_200x60 |
163506 ns/iter (± 21051) |
100937 ns/iter (± 6740) |
1.62 |
This comment was automatically generated by workflow using github-action-benchmark.
|
@codex review |
|
@cursor review |
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_22d673d4-a631-4939-8d8b-62141d9052c1) |
|
Codex Review: Didn't find any major issues. Chef's kiss. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
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". |
|
@cursor review verbose=true |
|
Bugbot request id: serverGenReqId_da1b3241-6114-41e8-b892-7d0c37f975ef |
Bugbot rules debugNo rules were used for this review. https://cursor.com/docs/bugbot#team-rules Bugbot request id: serverGenReqId_da1b3241-6114-41e8-b892-7d0c37f975ef |
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_da1b3241-6114-41e8-b892-7d0c37f975ef) |
- Replace the confounded positive-only test with two targeted cases: restore with state and restore from LLM output with no state. - Add a negative test for malformed tool_uses input that should fall back to a plain view. - Assert exact child header text so alias parsing is verified independently of pre-seeded state.
There was a problem hiding this comment.
w0wl0lxd has reached the 50-credit limit for trial accounts. To continue receiving code reviews, upgrade your plan.
There was a problem hiding this comment.
w0wl0lxd has reached the 50-credit limit for trial accounts. To continue receiving code reviews, upgrade your plan.
There was a problem hiding this comment.
w0wl0lxd has reached the 50-credit limit for trial accounts. To continue receiving code reviews, upgrade your plan.
Summary
Improves the built-in tool schemas and descriptions to reduce two recurring model-side log patterns:
tool input parse failed(e.g., missingnew_string, wrong batch envelope)unbounded command execution (missing justification)Changes
bash: strongerjustificationrequirement wording.batch: accepttool_usesas an alias fortool_calls; clarify the array item shape.edit/multiedit: addold_string/new_stringfield descriptions and top-levelpathrequirement.grep: top-levelpatternrequirement and parameter descriptions.read: top-levelpathrequirement.todo_write: explicitstatusenum description.n00n-token-profile/baselines/cold_start.jsonfor the intentional schema/prompt growth.Test plan
cargo clippy --all --tests -- -D warningscleancargo nextest run --workspacepasses (4422 passed, 1 skipped)styluacleanNote
Low Risk
Mostly schema metadata and batch restore/header input normalization; behavior changes are limited to accepting
tool_useson batch UI restore and clearer model-facing contracts.Overview
Tightens built-in tool JSON schemas and copy so models hit fewer parse/validation errors (
missing new_string, wrong batch envelope, unbounded bash withoutjustification).batch: Documentstool_callsmore explicitly, adds schemaaliastool_uses, and uses a sharedtool_calls_ofhelper in header/restore so persisted history that still saystool_usesrenders like live parse. Newrestore_accepts_tool_uses_aliastest inbatch_policy.rs.Other plugins: Clearer field descriptions and top-level
requiredwhere it helps (read/grep/edit/multiedit/todo_write);bashstates that broad commands fail withoutjustification.Docs:
site/docs/content/tools/_index.mdaligned with the schema text; changelog entry222.fixed.md.Reviewed by Cursor Bugbot for commit ca3705d. Bugbot is set up for automated code reviews on this repo. Configure here.