verify_lean
Checks new code changes for bloat, missing error handling, and security issues, then returns a pass or block gate to prevent committing faulty code.
Instructions
Call when you finish a change, before you report done or commit.
Checks new code for three things. Bloat: duplicates of existing code, dead code, unused imports, redundant
checks, single-implementation abstractions, pass-through wrappers, hand-rolled stdlib functions, unneeded
dependencies. Error handling: swallowed exceptions, missing timeouts, unchecked subprocesses, unclosed files,
imports of project modules or names that don't exist. Security: injection, hard-coded secrets, verify=False,
unsafe deserialization, unknown or vulnerable packages. diff is a unified diff; omit it to check the working
tree against HEAD.
Returns gate=pass|block with findings. Fix blocking findings or reject wrong ones via record_feedback.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "verify_lean"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| diff | No | ||
| repo | No |