feat(trg): let the llm judge target transcripts, files, and created-files lists - #154
Conversation
PR SummaryMedium Risk Overview
Judge payloads are rebuilt around what was targeted: legacy structured JSON for default/ Payload sizing moves from per-artifact 8KB excerpts to one shared 8,000-byte budget with fair shares, rollover, truncation markers, Reviewed by Cursor Bugbot for commit d4fe22a. Bugbot is set up for automated code reviews on this repo. Configure here. |
|
Warning Review limit reachedNext included review available in 48 minutes. View limit detailsLimit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Review configuration: ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (5)
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 |
e498943 to
b2b7e89
Compare
a70defc to
1c4da1c
Compare
ed1749b to
84170e2
Compare
b25dc79 to
9c16481
Compare
84170e2 to
bd2c2a4
Compare
…iles lists The judge could only ever see the implicit final-text-plus-outputs blob, so an assertion about the transcript or a specific file had no way to tell the judge what to look at. A per-artifact excerpt cap with no total ceiling also meant payload size grew unbounded with artifact count and could silently drop content without saying so. created_files reuses the artifact index already persisted on the run record instead of walking the output directory a second time. Transcript truncation keeps the tail rather than the head, since the run's outcome and its most recent tool calls sit at the end of the transcript. The budget guards against being asked for more placements than the slot count it was given, rather than panicking on a division by zero. Signed-off-by: Yordis Prieto <yordis.prieto@gmail.com>
An explicit target on an llm grader stated what to look at; the mechanical shortcut and any_output's file walk both ignored that statement, so a declared target could be silently misgraded and any_output could miss nested files a mechanical grader would have found. created_files also stripped a raw string prefix from artifact paths, which a separator mismatch could leave unstripped. The judge could not be pointed at a picture the run produced, even though both providers it speaks to accept image content parts; a file target resolving to one always failed as unreadable text instead. A flat byte cap on the transcript payload could cut through the exact message a criterion was about and gave no sign that anything was missing. Signed-off-by: Yordis Prieto <yordis.prieto@gmail.com>
The judge is shown the run's opening message so it can tell how the run began, and the byte it was charged for a newline that is never written cost it that message on transcripts that were within budget all along. Signed-off-by: Yordis Prieto <yordis.prieto@gmail.com>
16cd6dc to
27a2e9e
Compare
…ires Signed-off-by: Yordis Prieto <yordis.prieto@gmail.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
Reviewed by Cursor Bugbot for commit d4fe22a. Configure here.
| GraderOutcome::Deferred { criterion, target } => { | ||
| let mut result = match options.grader { | ||
| GraderMode::Llm | GraderMode::Auto => grade_with_llm(&criterion, ctx, session)?, | ||
| GraderMode::Llm | GraderMode::Auto => grade_with_llm(&criterion, &target, declarative, ctx, session)?, |
There was a problem hiding this comment.
LLM results omit declared target
Medium Severity
describe now prefixes a non-default target onto an llm grader, but the deferred path publishes grade_with_llm's result whose assertion is only the raw criterion. Two graders that share a criterion and differ only by target therefore land in results under the same key, and the report no longer shows which target the judge actually saw.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit d4fe22a. Configure here.


Stacked on #152.