auto-verify
Skill1 starsChanged 5 months agoMITView on GitHub
Automatic verification harness — Agent checks its own work after completing a task. Reduces human verification burden.
1 other project uses a version of this.
Adopted by
Most recently taken up by
- zjunlp/Mechanisttheir own version, first seen Jul 11, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- zjunlp/Mechanist★ 75same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository3 other files it gives its agents.
- auto-auditSkill
- auto-reviewSkill
- harness-bridgeSkill
The file
We split this skill into the rules it gives an agent
8 rules. About 0 are common, 7 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈7
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 42
Only run tools that exist in the project.
- Distinctive: line 113
After auto-fix, re-run verification.
- Distinctive: line 119
Test failures after 2 correction attempts
- Distinctive: line 120
No verification tools available in the project
- Distinctive: line 155
Don't run full project test suite on every change — only run tests related to changed files.
- Very specific: line 156
Don't assume tools exist — always check first with [ -f ...
- Distinctive: line 157
Don't auto-fix type errors or logic bugs — only auto-fix lint/style.
- Distinctive: line 158
Don't run verification on files you didn't change — stick to git diff output.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Auto-Verify Skill
Agent completes a task → this skill triggers → automated quality checks run → pass = deliver, fail = auto-fix or escalate.
Verification Pipeline
Step 1: Detect what was changed
git diff --name-only HEAD (or git status for uncommitted changes)Classify each changed file by type:
.ts/.js/.py/.go→ code.md/.txt→ docs.yaml/.json/.toml→ config.css/.scss/.less→ style
Step 2: Run type-specific checks
Code files (.ts/.js/.py)
# TypeScript/JavaScript
npx tsc --noEmit # type check
npx eslint <changed-files> # lint (if .eslintrc exists)
npm run test -- --changed # run related tests (if available)
# Python
python -m py_compile <file> # syntax check
ruff check <file> # lint (if ruff installed)
pytest <related-test-file> # run related tests (if available)Only run tools that exist in the project. Check first:
[ -f "tsconfig.json" ] && echo "has-ts"
[ -f ".eslintrc*" ] || [ -f "eslint.config.*" ] && echo "has-eslint"
[ -f "pytest.ini" ] || [ -f "pyproject.toml" ] && echo "has-pytest"Config files (.yaml/.json/.toml)
# Validate YAML syntax
python3 -c "import yaml; yaml.safe_load(open('<file>'))"
# Validate JSON syntax
python3 -c "import json; json.load(open('<file>'))"
# Validate TOML syntax
python3 -c "import tomllib; tomllib.load(open('<file>', 'rb'))"Doc files (.md)
# Check markdown lint (if mdlint available)
npx markdownlint <file>
# Check link integrity (relative links only — local files)
grep -oP '\[.*?\]\((?!http)(.*?)\)' <file> | check each path existsStep 3: Aggregate results
Build a verification report:
VERIFICATION REPORT
===================
Files changed: 3
- src/auth.ts (code)
- config.yaml (config)
- README.md (docs)
Checks run: 5
✅ tsc --noEmit: PASS (0 errors)
✅ yaml safe_load: PASS
✅ markdown link check: PASS
❌ eslint src/auth.ts: FAIL (2 errors)
- line 12: unexpected var, use let/const
- line 34: missing return type annotation
⚠️ pytest: SKIPPED (no test found for auth.ts)
Overall: FAIL (1 check failed)Step 4: Decision logic
| Result | Action |
| ALL PASS | Proceed — commit/deliver results |
| MINOR FAIL (lint/style) | Auto-fix with patch, re-verify, then proceed |
| MAJOR FAIL (type errors, test failures) | Return failure details to the calling agent for self-correction |
| NO CHECKS AVAILABLE | Proceed with warning — flag for human review if gateway connected |
Step 5: Auto-fix loop (minor failures only)
For lint/style issues, attempt auto-fix:
npx eslint --fix <file> # auto-fix lint
npx prettier --write <file> # auto-fix formatAfter auto-fix, re-run verification. Max 3 auto-fix cycles. If still failing after 3 cycles, escalate.
Step 6: Escalation trigger
Escalate to human ONLY when:
- Type errors that can't be auto-fixed
- Test failures after 2 correction attempts
- No verification tools available in the project
- Security/compliance concerns detected
Executable Script
本 Skill 提供可执行脚本,可直接运行或通过 MCP 工具调用:
# 直接运行(终端)
python3 skills/auto-verify/verify.py --path . --packs security,coding --output table
# JSON 输出(机器可读)
python3 skills/auto-verify/verify.py --path . --packs security,coding --output json
# 通过 MCP 工具调用
mcp__harness-cook__harness_check path="." pack_names=["security", "coding"]脚本功能:
- 获取 git diff 变更文件列表
- 调用 harness
ComplianceEngine合规扫描(支持 coding/security/data/devops 规则包) - 对变更文件做语法检查(Python/YAML/JSON/TOML)
- 输出验证报告(通过/失败 + 详细违规列表)
退出码:0 = 全部通过,1 = 有违规或检查失败
与 Step 2 的关系
脚本中的合规扫描对应 Step 2 的"类型检查"步骤,额外提供了:
- harness ComplianceEngine 合规扫描(检查安全违规、编码规范等)
- 多格式输出(table/json)
- 退出码支持(可直接在 CI/CD 中使用)
Pitfalls
- Don't run full project test suite on every change — only run tests related to changed files. Full suite is too slow and wastes tokens.
- Don't assume tools exist — always check first with
[ -f ... ]orwhich. - Don't auto-fix type errors or logic bugs — only auto-fix lint/style. Logic errors need the calling agent to reason about.
- Don't run verification on files you didn't change — stick to
git diffoutput. - For projects without any verification infrastructure, don't block delivery — just note "unverified" and proceed.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

