A local-first, project-scoped SQLite memory engine that shares coding decisions and project state across AI coding agents like Claude Code, Cursor, and Codex CLI.
wanshuiyin/HERO-Anti-OverDefense
A paste-in rules block that stops coding agents like Claude Code and Codex from over-defending, over-building and adding unneeded checks.
- Stars
- 801
- Forks
- 28
- Open issues
- 0
- Last commit
- 2 days ago
What is it?
HERO names four shapes of over-defensive behaviour in coding agents: Hashing (checksums nothing needs), Edge cases (guarding inputs the project never receives), Rubrics (scoring tables and re-verification loops replacing judgement), and Overbuild (feature flags, migration frameworks and compatibility layers nobody asked for). The project provides a short contract, RULES.md, that you paste into the config file your agent loads automatically, such as CLAUDE.md, AGENTS.md, .cursorrules or copilot-instructions.md.
The repository also includes a catalogue of observed cases, each with what was asked, what the agent did, why it was disproportionate and what a proportionate result looks like. These are meant to be quoted back to the agent when it insists on unnecessary hardening, not loaded into its config. Optional add-ons cover Codex Goal execution reminders and a Markdown session handoff workflow for continuing work in a fresh conversation.
The project states that the rules help but do not enforce behaviour, since they are natural-language instructions that a stronger system constraint can override. Its core rules need no installation and work with Claude Code, Codex, Antigravity, Cursor, GitHub Copilot, Windsurf and Gemini CLI.
Key features
- 01Provides a paste-in rules block that scopes what an agent proposes to fix.
- 02Defines four failure families: hashing, edge cases, rubrics and overbuild.
- 03Ships a catalogue of observed cases with proportionate alternatives.
- 04Includes a short version of the rules at about half the length.
- 05Offers an optional Codex Goal reminder skill and a session handoff skill.
Use cases
- Keeping Claude Code or Codex focused on the requested feature instead of building scaffolding around it.
- Reducing unnecessary checksums, feature flags and compatibility layers in agent-written code.
- Running long unattended agent sessions with rules that stay loaded in the project config.
- Continuing a task in a fresh conversation using a saved Markdown handoff.
In collections
Topics
FAQ
- What is HERO-Anti-OverDefense?
- A paste-in rules block that stops coding agents like Claude Code and Codex from over-defending, over-building and adding unneeded checks. HERO names four shapes of over-defensive behaviour in coding agents: Hashing (checksums nothing needs), Edge cases (guarding inputs the project never receives), Rubrics (scoring tables and re-verification loops replacing judgement), and Overbuild (feature flags, migration frameworks and compatibility layers nobody asked for). The project provides a short contract, RULES.md, that you paste into the config file your agent loads automatically, such as CLAUDE.md, AGENTS.md, .cursorrules or copilot-instructions.md.
- Is HERO-Anti-OverDefense free to use? What license does it have?
- HERO-Anti-OverDefense is open source under the MIT license. Check the license terms before using it in commercial products.
- Is HERO-Anti-OverDefense still maintained?
- Actively maintained. The last commit to HERO-Anti-OverDefense was on Nov 6, 2026.
- What can I use HERO-Anti-OverDefense for?
- Keeping Claude Code or Codex focused on the requested feature instead of building scaffolding around it. Reducing unnecessary checksums, feature flags and compatibility layers in agent-written code. Running long unattended agent sessions with rules that stay loaded in the project config. Continuing a task in a fresh conversation using a saved Markdown handoff.
- Where can I get HERO-Anti-OverDefense?
- The source code and installation instructions are on GitHub: https://github.com/wanshuiyin/HERO-Anti-OverDefense
Summary generated by AI from the project's README. GitHub stats refresh daily.
Related projects
An Agent Skill that rewrites AI-generated Japanese into more natural, readable Japanese for technical articles, specs, and PR descriptions.
A portable Agent Skill that removes AI-writing tells from prose, repairing narrative structure in fiction and applying venue-specific rules to professional documents.
A set of 24 open-source agent skills that steer Claude Code, Codex, Cursor and opencode toward less generic, more deliberately designed UI output.
A curated directory of 1000+ Claude Skills and plugins for Claude Code, Claude.ai and coding agents like Codex, Cursor and Gemini CLI.
A local desktop kernel that plugs multiple native coding agents (Claude Code, Pi, OpenCode, Cursor CLI and more) into the official Codex Desktop UI with task handoff between them.