feat: add eval:inventory CLI command and reporting logic#28009
Conversation
|
📊 PR Size: size/L
|
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request introduces a new development utility for the evaluation framework, enabling developers to easily audit and inventory existing test cases. By providing a CLI command to aggregate and categorize evaluation tests, it enhances visibility into the test suite's structure and policy classifications. Additionally, the PR includes necessary stability improvements to the test infrastructure and comprehensive unit tests for the new reporting logic. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize the Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request introduces an eval inventory CLI tool and helper utilities to scan, aggregate, and format reports on eval source files, along with comprehensive unit tests. Feedback on the changes highlights an issue in the custom sort comparator within scripts/utils/eval-inventory.ts, where a violation of the reflexivity rule of Array.prototype.sort when comparing identical '(no suite)' values could lead to unstable sorting behavior.
Summary
Adds
npm run eval:inventory, a repo-local command for listing the eval cases currently defined underevals/.This builds on the static eval analyzer by scanning
*.eval.tsand*.eval.tsxfiles, collecting the cases it finds, and printing a stable text report grouped by policy and suite.Details
scripts/eval-inventory-cli.tsas the command entry point.scripts/utils/eval-inventory.tsto:evals/analyzeEvalSourcefor each fileeval:inventorynpm script.Pre-Merge Checklist
@gundermanc pls have a look