You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .claude/agents/bug-investigator.md
+7-5Lines changed: 7 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,13 +10,15 @@ color: orange
10
10
11
11
Systematically traces issues through the dev-agent monorepo. Reproduces, traces, fixes, and prevents regression.
12
12
13
-
## MCP Tools — Use These First
13
+
## MCP Tools — Save Tokens, Extend Sessions
14
14
15
-
-**`dev_search`** — Start here for any conceptual query ("where does rate limiting happen", "how are embeddings stored"). Semantic search finds code by meaning, not just keywords.
16
-
-**`dev_refs`** — Trace callers/callees of a function to map the data flow. Use this instead of grepping for function names when tracing how data moves across packages.
17
-
-**`dev_map`** — Check change frequency to see what files changed recently. Useful for "when did it break?" — high-churn files near the bug timeframe are prime suspects.
15
+
Use MCP tools to get focused results instead of Grep → Read cycles. See CLAUDE.md for the token savings table.
18
16
19
-
Fall back to Grep/Glob for exact string matches or file patterns.
17
+
-**`dev_search`** — Conceptual queries ("where does rate limiting happen"). Returns ranked snippets — no file reading needed.
18
+
-**`dev_refs`** — Callers/callees of a function. Use `dependsOn` to trace dependency chains between files.
19
+
-**`dev_map`** — Codebase structure with hot paths and subsystems. One call replaces dozens of ls/glob/read operations.
20
+
21
+
Reserve Grep/Glob for exact string matches where you know the literal text.
Copy file name to clipboardExpand all lines: .claude/agents/logic-reviewer.md
+2-1Lines changed: 2 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -65,9 +65,10 @@ Every finding MUST include confidence: **HIGH** (verified from code), **MEDIUM**
65
65
66
66
### Cross-Package Data Flow (Deep+ Effort)
67
67
68
-
Use `dev_refs`to trace caller/callee chains across package boundaries. Use `dev_search` to find related code by concept when the function name isn't obvious.
68
+
Use MCP tools to trace cross-package flows without reading every file (see CLAUDE.md for token savings). `dev_refs` returns the call graph directly, `dev_search` finds related code by concept, `dev_patterns` compares error handling across files.
69
69
70
70
-[ ] Core exports consumed correctly by CLI, MCP server, and subagents — verify with `dev_refs`
71
+
-[ ] Dependency chains make sense — use `dev_refs` with `dependsOn` to trace file-to-file paths
71
72
-[ ] Type boundaries between packages match (no `any` casting to bridge mismatches)
72
73
-[ ] Logger (@prosdevlab/kero) configuration consistent across consumers
73
74
-[ ] Error handling patterns are consistent with existing code (verify with `dev_patterns`)
Copy file name to clipboardExpand all lines: .claude/agents/quality-reviewer.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -48,7 +48,7 @@ Maximum **5 SUGGESTION items** per review. If more found, pick the top 5 and not
48
48
49
49
### Readability & Simplification
50
50
51
-
Use `dev_patterns`to find similar code and detect duplication. Use `dev_search` to check if a utility already exists before flagging missing abstractions.
51
+
Use MCP tools to check for duplication without reading every file (see CLAUDE.md for token savings). `dev_patterns` compares patterns across similar files. `dev_search` checks if a utility exists by meaning, not just name.
52
52
53
53
-[ ] No code duplicating existing utilities — verify with `dev_patterns` and `dev_search`
54
54
-[ ] Functions reasonably sized (consider splitting if >50 lines)
Copy file name to clipboardExpand all lines: .claude/agents/quick-scout.md
+8-4Lines changed: 8 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,6 +10,10 @@ color: blue
10
10
11
11
Lightweight explorer optimized for speed and cost. Finds code, traces flows, maps dependencies.
12
12
13
+
## Token Efficiency
14
+
15
+
Use MCP tools to get focused results instead of Grep → Read cycles. See CLAUDE.md for the token savings table. Every file Read costs tokens — let the tools do the reading.
16
+
13
17
## Capability Boundaries
14
18
15
19
You excel at:
@@ -25,10 +29,10 @@ Do NOT guess at architectural reasoning or make recommendations.
25
29
26
30
## Workflow
27
31
28
-
1.**Search** — Always start with `dev_search`. It finds code by meaning, not just keywords. Only fall back to Grep for exact string matches or Glob for file patterns.
29
-
2.**Trace** — For "who calls X?" or "what does X call?", use `dev_refs`. Do not grep for function names when `dev_refs` can trace the graph directly.
30
-
3.**Map** — For "what's the structure?" or "what changed recently?", use `dev_map`.
31
-
4.**Verify** — Read the file to confirm the match
32
+
1.**Search** — Start with `dev_search` for conceptual queries. Returns ranked snippets without reading files. Only fall back to Grep for exact string matches.
33
+
2.**Trace** — For "who calls X?", use `dev_refs`. For "how does A depend on B?", use `dev_refs` with `dependsOn`. Returns the call graph directly — no grepping for function names.
34
+
3.**Map** — For "what's the structure?", use `dev_map`. One call replaces dozens of ls/glob/read operations.
35
+
4.**Verify** — Only Read a file when you need the full implementation, not just the location.
32
36
5.**Report** — Concise, factual answer with file paths and line numbers
Copy file name to clipboardExpand all lines: .claude/agents/research-planner.md
+7-5Lines changed: 7 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,12 +12,14 @@ Plans investigations before jumping into implementation. Produces a structured r
12
12
13
13
This agent **NEVER writes code**. It produces investigation plans.
14
14
15
-
## MCP Tools — Use These to Map the Territory
15
+
## MCP Tools — Save Tokens, Extend Sessions
16
16
17
-
-**`dev_search`** — Find relevant code areas by meaning. Start broad ("authentication middleware", "vector storage") to discover what exists before diving in.
18
-
-**`dev_map`** — Get codebase structure with change frequency. Use early to understand scope and identify hot spots.
19
-
-**`dev_patterns`** — Analyze existing patterns before proposing new ones. Find similar implementations, error handling conventions, and type patterns.
20
-
-**`dev_refs`** — Trace cross-package dependencies. Understand what depends on what before proposing changes.
17
+
Use MCP tools to map the territory without burning tokens on Grep → Read cycles. See CLAUDE.md for the token savings table.
18
+
19
+
-**`dev_search`** — Find relevant code areas by meaning. Returns ranked snippets — no file reading needed.
20
+
-**`dev_map`** — Codebase structure with hot paths and subsystems. One call replaces dozens of ls/glob/read operations.
21
+
-**`dev_patterns`** — Compare patterns across similar files without reading each one.
22
+
-**`dev_refs`** — Trace cross-package dependencies. Use `dependsOn` to trace dependency chains between files.
Copy file name to clipboardExpand all lines: .claude/agents/security-reviewer.md
+4Lines changed: 4 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,6 +12,10 @@ Security-focused review for a TypeScript monorepo that processes repository data
12
12
13
13
This agent **NEVER modifies code**. It reports issues for the developer to fix.
14
14
15
+
## Token Efficiency
16
+
17
+
Use MCP tools to avoid expensive Grep → Read cycles. See CLAUDE.md for the token savings table. `dev_search` returns ranked snippets, `dev_refs` traces input flow directly, `dev_patterns` scans for similar vulnerability patterns — all without reading files manually.
18
+
15
19
## Checklist
16
20
17
21
Use `dev_search` to find security-sensitive code ("user input", "shell execution", "token handling"). Use `dev_patterns` to find similar patterns across the codebase — if one injection vector exists, the same pattern likely appears elsewhere. Use `dev_refs` to trace how user input flows through the system.
@@ -139,16 +139,33 @@ See `.claude/da-plans/README.md` for status and format details.
139
139
140
140
---
141
141
142
-
## MCP tools (5 adapters)
142
+
## MCP tools — token-efficient context
143
+
144
+
MCP tools return pre-ranked, pre-snippeted results. Use them to avoid expensive Grep → Read cycles that burn thousands of tokens on irrelevant context.
0 commit comments