The idea
For us, a design, an adversarial review, a build, an independent code review and a deploy gate catch real defects. They also cost hours and a lot of tokens. For a typo or a cold-path tweak that cost buys very little.
This is how we work at High Impact Group. We share it as it is, not as a standard or a recommendation. Take what is useful and change the rest to fit your own stakes.
Pick the process by risk. Size is a poor guide. Start every change at the lowest tier that fits. Go up only when a named trigger applies. Keep the full process for the few kinds of change where a mistake is expensive or hard to undo.
Four tiers
- Docs, tests, copy
- Tooling and agent config
- Cold path, small, easy to revert
- Covered by a test that can fail
- Shared helpers, generators
- Prompt wording, scheduled jobs, anything that sends to a customer
- Migrations, money, auth, privacy
- Your product's core loop
How to assign a tier
- Start low. Tier 1 is the default for code. Tier 0 for docs, tests and config.
- Escalate on a named trigger only. Keep a short table of triggers in your repo. "It feels risky" is not a trigger. If you cannot name the row, stay put.
- Never go back down after a trigger fires. Whoever finds the trigger raises the tier and says so.
- Write the tier in the PR on one line. A CI check can fail PRs that have no tier line.
- The owner can override with one word: "tier 1".
Our trigger table is built for our own stakes, and yours will differ. Our Tier 3 rows: schema migrations, deleting or rewriting stored user data, billing, auth and access control, privacy-sensitive data, and the one code path your product depends on. Our Tier 2 rows: shared helpers, generated customer-facing documents, prompt changes, and scheduled jobs.
The five gates (Tier 3)
A design file: evidence, at least two options, files to change, tests, rollback, acceptance checks.
Told to find reasons the design is wrong. Not the author. Every must-fix is answered.
Tests first, shown failing. Builds exactly the approved design. Opens a draft PR.
Wrote neither design nor code. Reads the full diff, drives the real path, runs the mutations.
Only after G4. Migrations, env vars and flag flips are done by a human.
Role agents
| Agent | Job | Can write? |
|---|---|---|
designer | Writes the design file and opens a docs-only draft PR. | Docs only |
design-reviewer | Adversarial review of the design. Posts a verdict. | No |
builder | Implements the approved design, tests first. | Yes |
code-reviewer | Independent review of the diff against the design. | No |
migration-reviewer | Reviews any schema change or database function. Returns ship or hold. | No |
fix-round-builder | One consolidated fix round after review. | Yes |
retester | Checks the shipped fix on fresh data, read-only database access. | No |
The agent list shows these roles as designer-g1, reviewer-g2, builder-g3, reviewer-g4, reviewer-migration, builder-fix-round and tester-retest. Reviewers must not have written the thing they review. Say who you chose and why. If every independent reviewer is busy, wait or record an exception on the PR.
Pin models and effort in the files
We do not leave model choice to inheritance. We put the model and effort in each agent's frontmatter, and a script checks that they match one config file.
| Work | Suggested pin | Why |
|---|---|---|
| Design and every review | Your strongest model, high effort | These steps find the mistakes. A weak reviewer approves bad work. |
| Build and tests | A capable mid-tier model, high effort | The design already settled the approach. |
| Triage and routing | Your smallest model | Cheap sorting of noise into act, watch and ignore. |
--- name: code-reviewer description: Independent review of a diff against its approved design. model: claude-opus-5-5 effort: xhigh tools: Read, Grep, Glob, Bash ---
Check the current model IDs and which frontmatter keys your Claude Code version supports before copying. Reviewers can be made read-only with a tools allowlist or a disallowedTools list.
A drift guard
Keep one JSON file that lists the allowed models and the pin for each gate agent and command. A small script reads every agent and command file and fails CI when a file disagrees, a model is not on the list, or a reviewer gained a write tool. This has been the cheapest way for us to keep a large agent set consistent.
Guardrails in hooks, not in prompts
A prompt can be ignored, so we put the rules we cannot afford to break into PreToolUse hooks and permission deny lists.
What we always block, and always check
- Plain force pushes (allow
--force-with-lease) - Ending a turn while the fast checks fail (a Stop hook that runs them and sends the work back)
rm -rfon protected paths- Piping a download into a shell
- Edits to secrets, lock files and keys (exempt
*.example) - Closing keywords in commits and PRs, if you hand bugs to a tester
- A hook that crashes: make it stop the command, not let it through
Where we want a person to decide
- Merging and marking a PR ready (the owner, or a deployment-manager session the owner directs)
- Opening a non-draft PR
- Pushing to the main branch
- Applying production migrations and changing production env values
Parse commands properly. A substring match blocks harmless commands and misses wrapped ones (bash -c, subshells, global flags such as git -C . push). Test the hook with sample payloads, then confirm once in a live session that it fires: hooks load only for sessions started inside the repo.
Three long-running sessions
Besides the agents above, we keep three persistent sessions, each with one fixed job and its own brief. A person starts each one, states the authority once, and stays on the decisions that are theirs.
Delivery controller
Runs a delivery program. It writes little code itself. It assigns each change a risk tier, briefs the design, review, build and test agents, and checks each result against the code, the database and the logs before it believes it.
- Passes the model and effort to every agent, every time.
- Never lets the author of a design or a change review it.
- Keeps a handover document so a new session can resume from the repo alone.
- Leaves to the owner: migrations, production flags, anything paid or irreversible, and closing bug reports.
Deployment manager
Takes a list of pull requests and an order, and walks each one to merged: brings the branch up to date, resolves conflicts, runs the tests, fixes what only breaks because two changes now meet, turns on auto-merge, and waits for the checks.
- Merges one at a time, and prepares the next while the current one waits.
- Holds a change whose description names an unmet precondition, and says what would close it.
- Never weakens a test, rewrites history or force-pushes.
- Reports what it changed beyond the change, what it did not check, and what only a person can do.
Smoke tester
Uses the live product through a browser the way a customer would. It finds problems, proves them with evidence and files them as issues. It does not fix them.
- Waits until a deploy is live before testing, and uses fresh test data each round.
- Closes an issue only after it has seen the fix work on production.
- Probes AI features with injection, disguised injection, pressure to invent figures, off-topic requests, regulated advice and requests to name real people. It always sends a normal follow-up afterward.
- Leaves logins, sends and deletions to the person, and says what it did not test.
The common rule is that these sessions report faithfully: a failure is stated with its evidence, a skipped step is stated as skipped, and a check is never claimed that did not run.
A starter kit
We started with a handful of each and added more when we found ourselves repeating a task.
Agents
| Gate roles | designer, design reviewer, builder, code reviewer, migration reviewer, fix-round builder, retester |
| Specialist reviewers | security, database, privacy, accessibility, API design, silent-failure hunter |
| Operators | incident responder, ops health, triage scout, release planner |
| Lenses | product, growth, pricing, competitor, investor, plus a few buyer and user personas |
Commands
| Deliver | idea, plan, solve, hotfix, gate, pre-merge, post-merge, an issue-to-PR loop |
| Audit | security, privacy, accessibility, performance, SEO, UX, launch readiness |
| Set up | health check, error tracking, rate limiting, request timeouts |
| Daily | session start and end, morning brief, branch cleanup |
We keep each repo's agents to that repo. Persona agents written for one product mislead in another.
Working rules
- PRs open as drafts. The owner, or an agent they direct, marks them ready and merges after review and green CI.
- Refer to issues with
refs #N, never a closing keyword. Let the tester close after retest. - One fix round per review. Fix critical and high findings and clear bugs. Put nits in a follow-up note. A reviewer with nothing blocking says "ship" and stops.
- Tests first, shown failing on the base. State a rollback. Give source, time window and sample size for every telemetry claim.
- A builder that cannot build the design as written stops and reports. The fix is a design amendment, not a quiet deviation.
- Retest on fresh data. A defect on rows written before a fix is not proof the fix failed.
- Scale mutation checks with the tier: none at Tier 1, the important ones at Tier 2, all at Tier 3.
Type the name with a leading slash, for example /gate. Use the copy button to grab it.