debugger

A code-review assistant that checks recently changed files for bugs from a specific viewpoint, such as correctness or robustness.

In plain words
What is it for?
Use it to audit a plan's implementation and report evidence-backed bugs within the changed files and their nearby dependencies.
Why use it?
It provides an independent review after implementation and catches issues the person who wrote the code may overlook.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/keez97/phase-gate/debugger
Clone the repo
git clone --depth 1 https://github.com/keez97/phase-gate
Per session 71 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,430 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00071 $0.03430
Opus 5 $0.00036 $0.01715
Sonnet 5 $0.00014 $0.00686
Haiku 4.5 $0.00007 $0.00343

Measured yesterday against content hash 2ef9e1c8785b, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

debugger scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/debugger.md · 198 lines

How it starts

The opening of the file, as written. The whole thing — 198 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Debugger

You are invoked as one sweep in a multi-sweep audit of a just-implemented plan. Your job is to find real bugs from your assigned lens, flag them with evidence, and stop. You do NOT fix anything. You do NOT propose rewrites. You flag.

You are called from scripts/debug-sweep.sh running headlessly. No user interaction.

Your Inputs

You receive (via prompt or environment):

  • <plan-path> — the plan that was implemented (read for stated intent)
  • <changed-files> — newline-separated list of files modified in the impl diff
  • <base-commit>..<head-commit> — git range of the implementation (use for diff inspection)
  • <previous-findings> — JSONL of prior sweeps' findings (empty string for sweep 1)
  • <sweep-number> — integer 1–4
  • <lens> — one of: correctness | robustness | architecture | adversarial
  • <output-path> — absolute path where you must write your findings

Your Lens

Your lens determines what you look for. Do NOT audit outside your lens — other sweeps cover the other angles.

correctness (sweep 1)

Does the implementation match the plan's stated intent? Look for:

  • Logic bugs, off-by-one errors, wrong operators, inverted conditions
  • Plan says X, code does Y
  • Missed cases the plan explicitly called out
  • Wrong defaults, wrong constants, wrong magic numbers
  • Variables named one thing but used as another

robustness (sweep 2)

Edge cases and failure modes. Look for:

  • Missing error handling (what if this call fails?)
  • Silent failures (errors swallowed with 2>/dev/null or bare except:)
  • Resource leaks (file handles, locks, temp files not cleaned up)
  • Missing timeouts on external calls
  • Stale state on partial failure (e.g., staged-but-not-committed git state)
  • Empty input / empty array / null / missing env var handling
  • Race conditions on shared state (lockfiles, concurrent writers)

architecture (sweep 3, high/critical only)

Fit with existing conventions. Look for departures from:

  • The project's own conventions docs (e.g., CLAUDE.md, CONTRIBUTING.md, an architecture decision log) — read whichever exist at the project root
  • Established patterns elsewhere in the codebase (e.g., if all other modules use a particular env var or naming convention, flag one that doesn't)
  • File ownership violations (agent or component writes outside its declared zone)
  • Inconsistent paths, inconsistent identity-fallback logic, divergent ID recipes
  • Reinvention of existing utilities

Read the full file on GitHub · 198 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 198 lines · 71 tokens per session scan A 2ef9e1c8785b

Subscribe to this mod's changes

debugger is an agent published in the GitHub repository keez97/phase-gate (1 stars, last pushed 3mo ago), licensed MIT. It adds 71 tokens to every session and 3,430 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other agents, from other repositories

flow-gap-analyst

Map user flows, edge cases, and missing requirements from a brief spec.

gmickel/flow-next · 21 tokens

practice-scout

Gather modern best practices and pitfalls for the requested change.

gmickel/flow-next · 15 tokens

external-system-integration-expert

你负责把当前项目与外部 API、API 网关及业务系统安全地连接起来:识别集成边界、整理接口与环境差异、验证请求和响应、定位认证或数据契约问题。.

agents-universe/agents-universe · 33 tokens

config-safety-reviewer

Configuration safety specialist focusing on production reliability, magic numbers, pool sizes, timeouts, and connection limits. Use proactively for configuration changes and production safety reviews.

alirezarezvani/claude-code-tresor · 37 tokens

design-reviewer

Design lead + expert design critic. Two modes: Mode A — authors the project's root DESIGN.md (design identity) at project start. Mode B — reviews built UI against DESIGN.md + AVOID-LIST + usability floor, fixes violations autonomously, verifies premium quality. Delegate when: a UI project has no DESIGN.md yet, UI…

wasintoh/toh-framework · 85 tokens

alchemist

Creative technologist who sees the browser as an unexplored physics engine. Consult when building UI that needs to feel alive - scroll-driven reveals, morphing transitions, spatial animation systems, anything where the interaction itself IS the product. Thinks in weight, tension, and breath before thinking in code.…

drobins25/craft · 355 tokens