gap-trap — Gated Quality Framework for Agent-Written Code
Installs and refines a repo quality framework where every agent-facing rule is backed by a gate that fails a commit, push, or CI run.
Dev & CodingAdvanced★ 144⑂ 6AI score 9/10Last updated: Sep 15, 2026
What it does
- Discovers your repo (stack, test/lint commands, CI provider, architecture-contract candidates, history-derived domain facts) and confirms a single plan before touching files.
- Writes
AGENTS.md,AGENTS.project.md,CLAUDE.md, andagents/instruction files from templates, migrating rules out of existing.cursorrules, Copilot instructions, orCONTRIBUTING.mdrow by row. - Adds gates in your own test runner and CI: instruction gate, proven-red test, PR body check, a ratchet with violation counters, and a mutation smoke for risky modules.
- Proves each gate red with a scratch violation, reverts it, runs the full test command, and commits one logical change at a time.
refinemode audits ungated rules and stale contract symbols, then proposes the next rules and gates as one PR — deleting unjustified rules as readily as adding gates.
Who it's for
- Teams and solo devs whose repos are mostly written by coding agents.
- Anyone whose AGENTS.md/CLAUDE.md rules are ignored because nothing enforces them.
- Maintainers who want quality debt tracked as numbers (ratchet counters) instead of vibes.
Examples
gap-trap setupon a fresh repo: up to six contracts, a full gate set, an instruction word budget, and a report of which contracts are onlyGate: review.gap-trap refineafter your first incident: prunes dead rules, adds gates where code actually broke.- Saying "gate the rules" or "make the agents' code match the rules" triggers the same workflow.
· · · Install guide · · ·
Try it now, no install
Paste this into Claude to use the skill without installing anything.
Read the instructions in this file and follow them to help me: https://raw.githubusercontent.com/pliablepixels/gap-trap/HEAD/gap-trap/SKILL.md What I want: (describe your task here)
If Claude can't open the link, open it yourself and paste the contents instead.
↓ If it works for you, download the ZIP below and install it. Then it runs on its own — no pasting each time.
Install in the Claude app (no terminal)
- Download the ZIP with the button below.
- In Claude, open Settings → Capabilities and turn on 'Code execution and file creation'. (one time)
- Go to Customize → Skills → + → 'Upload a skill' and upload the ZIP.
Install in Claude Code
Let Claude do it — paste this into Claude Code
Install the skill I found on Claude Skill Mart. Copy the gap-trap folder from the GitHub repo pliablepixels/gap-trap into my ~/.claude/skills/gap-trap/. When it's done, tell me in one line what this skill can do.
Install with a command instead
git clone https://github.com/pliablepixels/gap-trap.git /tmp/gap-trap && mkdir -p ~/.claude/skills && cp -r /tmp/gap-trap/gap-trap ~/.claude/skills/gap-trap⚠ This is a third-party skill. Check the source repository before installing.
- Open a terminal.
- Clone the repo:
git clone https://github.com/pliablepixels/gap-trap.git /tmp/gap-trap - Create the skills folder:
mkdir -p ~/.claude/skills - Copy the skill in:
cp -r /tmp/gap-trap/gap-trap ~/.claude/skills/gap-trap - Start Claude Code and switch to Opus with
/model— the skill refuses to run on Sonnet or Haiku. - From your target repository, ask for
gap-trap setup. - Review the plan summary and the file diffs before approving; the skill also installs the
slop-mopskill into~/.claude/skills.
View source on GitHub ↗License: MIT