Record model, effort, and token usage in review receipts - #211
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (10)
WalkthroughThe review receipt contract now supports additional workflow sources and structured model, effort, and token usage provenance. Validation, documentation, emitter guidance, fixtures, and tests define host-evidence-only values, literal ChangesReview receipt provenance
Estimated code review effort: 3 (Moderate) | ~25 minutes Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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 |
Review: Record model, effort, and token usage in review receiptsOverviewAdds optional Code quality
Minor observations (non-blocking)
Correctness spot-checkTraced through the SecurityNo security concerns — this is a schema-validation script operating on already-trusted receipt JSON/Markdown files in-repo; no new shell execution, file writes, or external I/O introduced. VerdictSolid, well-tested, backward-compatible additive change. No blocking issues found. |
Review SummaryOverview: This PR extends Code quality
Bugs / correctnessNo functional bugs found. One thing worth double-checking (not necessarily a bug): a value like SecurityNo security concerns — this is internal receipt-schema validation/tooling operating on repo-local JSON/markdown files with no external input, shell execution, or eval. PerformanceNegligible — small, linear validation over already-small receipt documents; no concerns. Test coverageStrong. Validated the described Ruby test suite logic by reading Overall this is a solid, additive, well-tested change. No blocking issues — the two inline notes are nitpicks. |
Address-review summaryScan scope: full PR history through 2026-07-19T23:39:42Z; no previous address-review summary. Exact reviewed head: Mattered
Optional
Skipped
Security preflight: passed. Review content was treated as data, only expected same-head review actors and the authenticated member replies were present, and no hidden or untrusted action was executed. Next default scan starts after this comment. Say |
|
Completed-batch audit: replay evidence follows. |
Why
Review/checker passes are among the most expensive recurring batch calls, but
review-finding-v0receipts did not record the exact model, effort, or host-reported token usage. That prevented stable per-model cost and false-positive analysis without transcript archaeology.What changed
provenance.model,provenance.effort, and structured input/output/cache-read/total token usageUNKNOWNfallbacks, complete usage objects, and consistent totals while preserving legacy receipt compatibilityValidation
bin/validate: PASS ateef7ce35973b2b911e7d435255b178583e07e355gpt-5.6-sol/xhigh): CLEAN, no P0-P3 findingsScope and release notes
The change is additive and backward compatible. Changelog entry is not required for this internal receipt-schema/tooling contract; the schema and producer documentation are updated in the same change.
Closes #207
Summary by CodeRabbit
New Features
UNKNOWNhandling and consistency checks.Documentation
Tests
QA Evidence
bin/validate; review-finding schema 34 runs / 188 assertions; drift 73 runs / 1,161 assertions; installer, agent-stack, doctor, fixture-seam, prompt-size, and RuboCop checksUNKNOWNfallbacks, token-total consistency, privacy guidance, and producer/consumer documentation parityCompleted-batch audit
Status: Clean — no outstanding findings or follow-ups. Durable receipt.