debug-that
CLAUDE.md158 starsChanged 9 months agoMITView on GitHub
In this repository4 other files it gives its agents.
- demo/CLAUDE.mdCLAUDE.md
- .cursor/rules/use-bun-instead-of-node-vite-npm-pnpm.mdcCursor rule
- frontend-designSkill
- dbgSkill
The file
We split this CLAUDE.md into the rules it gives an agent
10 rules. About 0 are common, 4 are distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 57
Use Bun APIs over Node.js equivalents (WebSocket, Bun.serve, Bun.$, etc.)
- Distinctive: line 58
No ANSI colors by default (token efficiency for AI agents)
- Distinctive: line 59
Every error should suggest the next valid command
- Distinctive: line 60
Keep output compact — one entity per line where possible
- Distinctive: line 61
Use @refs for all inspectable entities in output
- Very specific: line 62
Use parseIntFlag() from src/cli/parse-flag.ts for integer CLI flags (NaN-safe)
- Very specific: line 63
Use parseFileLine() / parseFileLineColumn() from src/cli/parse-target.ts for file:line:column parsing
- Very specific: line 64
Use escapeRegex() from src/util/escape-regex.ts for CDP urlRegex patterns
- Very specific: line 65
Use formatTimestamp() from src/formatter/timestamp.ts for time display
- Very specific: line 66
Import timeout/limit values from src/constants.ts — do not hardcode magic numbers
≈ “Common” is an estimate: at least 1 in 5 of the 29,248 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
debug-that — Debugger CLI for AI Agents
Project Overview
CLI debugger built with Bun, optimized for AI agent consumption. Supports Node.js (CDP), Bun (JSC/WebKit), and native code via LLDB (DAP).
Tech Stack
- Runtime: Bun
- Language: TypeScript
- Linting/Formatting: Biome
- Testing: bun:test
- Validation: Zod v4 (mini)
- Dependencies: Minimal — leverage Bun built-ins (WebSocket, test runner, file I/O)
Project Structure
src/
cli/ # CLI argument parsing, command routing, flag utilities
session/ # Shared session abstractions
session.ts # Session interface + SessionCapabilities
base-session.ts # BaseSession abstract class (shared state, refs, console)
types.ts # Shared types (PauseInfo, StateSnapshot, ConsoleMessage, etc.)
factory.ts # createSession() + isDapRuntime()
daemon/ # Background daemon process, Unix socket server
cdp/ # Chrome DevTools Protocol (Node.js / Bun)
session.ts # CdpSession (extends BaseSession)
session-*.ts # CDP method modules (breakpoints, execution, inspection, etc.)
dialect.ts # InspectorDialect interface (what differs between V8 and JSC)
dialects/ # NodeDialect, BunDialect + openInspector() (socket + runtime probing)
client.ts # CdpClient WebSocket wrapper
dap/ # Debug Adapter Protocol (LLDB, Python, etc.)
session.ts # DapSession (extends BaseSession)
client.ts # DapClient stdin/stdout wrapper
refs/ # @ref system (mapping short refs to V8 IDs)
formatter/ # Output formatting (variables, source, stack traces)
commands/ # Command implementations (break, step, eval, etc.)
protocol/ # CLI-to-daemon JSON protocol types
sourcemap/ # Source map resolution
util/ # Shared utilities (escapeRegex, etc.)
constants.ts # Centralized timeout/limit constants
tests/
unit/ # Unit tests
integration/ # Integration tests (node/, bun/, lldb/, shared/)
fixtures/ # Test fixture scriptsCommands
bun run dev— run in developmentbun test— run all testsbun run test:stress— rerun the CDP suites on a CPU-starved machine (--burners N,--background,--runs N) to catch code that waits on time instead of protocol eventsbun run build— compile standalone binarybun run lint— lint with biomebun run format— format with biomebun run typecheck— type check source files
Guidelines
- Use Bun APIs over Node.js equivalents (WebSocket, Bun.serve, Bun.$, etc.)
- No ANSI colors by default (token efficiency for AI agents)
- Every error should suggest the next valid command
- Keep output compact — one entity per line where possible
- Use @refs for all inspectable entities in output
- Use
parseIntFlag()fromsrc/cli/parse-flag.tsfor integer CLI flags (NaN-safe) - Use
parseFileLine()/parseFileLineColumn()fromsrc/cli/parse-target.tsfor file:line:column parsing - Use
escapeRegex()fromsrc/util/escape-regex.tsfor CDP urlRegex patterns - Use
formatTimestamp()fromsrc/formatter/timestamp.tsfor time display - Import timeout/limit values from
src/constants.ts— do not hardcode magic numbers - Adding a command: create
src/commands/<name>.ts, register insrc/main.ts, handle insrc/daemon/entry.ts, add to help insrc/cli/parser.ts
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

