rde-eval
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseRun a local rule evaluation
运行本地规则评估
Use React Doctor Evals (RDE) for bounded local iteration. Use only after the change has a pushed pull request.
run-parity使用React Doctor Evals (RDE) 进行有限的本地迭代。仅在变更已推送至拉取请求后使用。
run-parityPrepare both checkouts
准备两个代码仓库
sh
export REACT_DOCTOR_CHECKOUT=/absolute/path/to/react-doctor
export RDE_CHECKOUT=/absolute/path/to/react-doctor-evals
git -C "$RDE_CHECKOUT" pull --ff-only
ni -C "$RDE_CHECKOUT"
nr -C "$RDE_CHECKOUT" build
nr -C "$REACT_DOCTOR_CHECKOUT" buildThe spec reads uncommitted React Doctor changes. Run RDE commands from the eval checkout.
path:sh
export REACT_DOCTOR_CHECKOUT=/absolute/path/to/react-doctor
export RDE_CHECKOUT=/absolute/path/to/react-doctor-evals
git -C "$RDE_CHECKOUT" pull --ff-only
ni -C "$RDE_CHECKOUT"
nr -C "$RDE_CHECKOUT" build
nr -C "$REACT_DOCTOR_CHECKOUT" buildpath:Run a bounded sample
运行有限样本
sh
cd "$RDE_CHECKOUT"
node dist/cli.js run "path:$REACT_DOCTOR_CHECKOUT" --runner local --take 100
node dist/cli.js digest "path:$REACT_DOCTOR_CHECKOUT" --rule <rule-id>
node dist/cli.js digest "path:$REACT_DOCTOR_CHECKOUT" --json --rule <rule-id> > <artifact-directory>/hits.jsonIncrease only after tests and the first sample pass.
--takesh
cd "$RDE_CHECKOUT"
node dist/cli.js run "path:$REACT_DOCTOR_CHECKOUT" --runner local --take 100
node dist/cli.js digest "path:$REACT_DOCTOR_CHECKOUT" --rule <rule-id>
node dist/cli.js digest "path:$REACT_DOCTOR_CHECKOUT" --json --rule <rule-id> > <artifact-directory>/hits.json仅在测试和首次样本通过后增加的值。
--takeInspect target-rule hits
检查目标规则匹配结果
For each hit, or a representative sample when counts are high:
- Open the pinned repository at the reported location.
- Compare the code with the rule contract.
- Classify the hit as true positive, false positive, or unsupported.
- Add a rule regression test for each false positive.
- Add confirmed false positives to the regression corpus.
fuzz - Rebuild and rerun the same sample.
Record repository count separately from project-root count. Do not treat error records as clean scans.
对于每个匹配结果,或者当数量较多时选取代表性样本:
- 在报告的位置打开固定的代码仓库。
- 将代码与规则约定进行对比。
- 将匹配结果分类为真阳性、假阳性或不支持。
- 为每个假阳性添加规则回归测试。
- 将已确认的假阳性添加到回归语料库。
fuzz - 重新构建并重新运行相同的样本。
单独记录仓库数量与项目根目录数量。不要将错误记录视为干净扫描。
Report results
报告结果
Report checkout revisions, target rule, repositories, project roots, diagnostics, inspected hits, fixed false positives, and the artifact path. State any setup error or skipped repository.
After local validation, return to . That skill decides whether to invoke pull request parity.
rule-validate报告代码仓库版本、目标规则、仓库、项目根目录、诊断信息、已检查的匹配结果、已修复的假阳性以及工件路径。说明任何设置错误或跳过的仓库。
本地验证完成后,回到。该skill会决定是否调用拉取请求一致性检查。
rule-validate