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
"""Get a full codebase briefing in a single call. Call this FIRST when starting work on a new or unfamiliar codebase. Covers tech stack, architecture (layers, clusters, entry points), health score, hotspots, conventions, and patterns. ~2-4K token output. Do NOT explore manually with Glob/Grep/Read -- use this instead. Follow with search_symbol or context to drill into specifics."""
169
+
"""Get a full codebase briefing in a single call.
170
+
171
+
Call this FIRST when starting work on a new or unfamiliar codebase.
health score, hotspots, conventions, and patterns. ~2-4K token output.
174
+
Do NOT explore manually with Glob/Grep/Read -- use this instead.
175
+
Follow with search_symbol or context to drill into specifics."""
170
176
return_run_roam(["understand"], root)
171
177
172
178
173
179
@_tool(name="roam_health")
174
180
defhealth(root: str=".") ->dict:
175
-
"""Codebase health score (0-100) with issue breakdown. Call this to assess overall code quality before deciding where to focus refactoring, or to check whether recent changes degraded health. Skip if you already called understand (includes health) or preflight (includes it per-symbol)."""
181
+
"""Codebase health score (0-100) with issue breakdown.
182
+
183
+
Call this to assess overall code quality before deciding where to
184
+
focus refactoring, or to check whether recent changes degraded health.
185
+
Skip if you already called understand (includes health) or preflight
"""Pre-change safety check. Call this BEFORE modifying any symbol or file. Combines blast radius, affected tests, complexity, coupling, and fitness violations in one call. Replaces 5-6 separate tool calls. Do NOT call context, impact, affected_tests, or complexity_report separately if preflight covers your need."""
192
+
"""Pre-change safety check. Call this BEFORE modifying any symbol or file.
193
+
194
+
Combines blast radius, affected tests, complexity, coupling, and
195
+
fitness violations in one call. Replaces 5-6 separate tool calls.
196
+
Do NOT call context, impact, affected_tests, or complexity_report
"""Find symbols by name (case-insensitive substring match). Call this when you know part of a symbol name and need the exact qualified name, file location, or kind. Use before context or impact to get the correct identifier. Do NOT use Grep for function definitions -- this is faster and returns structured data with PageRank importance."""
208
+
"""Find symbols by name (case-insensitive substring match).
209
+
210
+
Call this when you know part of a symbol name and need the exact
211
+
qualified name, file location, or kind. Use before context or impact
212
+
to get the correct identifier. Do NOT use Grep for function
213
+
definitions -- this is faster and returns structured data with
"""Get the minimal context needed to work with a specific symbol. Call this when you need to understand or modify a function, class, or method. Returns exact files and line ranges to read. More targeted than understand. For pre-change safety checks, prefer preflight instead (includes context plus blast radius and tests)."""
220
+
"""Get the minimal context needed to work with a specific symbol.
221
+
222
+
Call this when you need to understand or modify a function, class,
223
+
or method. Returns exact files and line ranges to read. More targeted
224
+
than understand. 'task' tailors output: "refactor", "debug", "extend",
225
+
"review", or "understand". For pre-change safety checks, prefer
226
+
preflight instead (includes context plus blast radius and tests)."""
"""Find the shortest dependency path between two symbols. Call this to understand HOW a change in one symbol could affect another. Shows path hops with symbol names, edge types, locations, and coupling strength."""
235
+
"""Find the shortest dependency path between two symbols.
236
+
237
+
Call this to understand HOW a change in one symbol could affect
238
+
another. Shows path hops with symbol names, edge types, locations,
239
+
and coupling strength."""
208
240
return_run_roam(["trace", source, target], root)
209
241
210
242
211
243
@_tool(name="roam_impact")
212
244
defimpact(symbol: str, root: str=".") ->dict:
213
-
"""Show the blast radius of changing a symbol -- everything that would break if its signature or behavior changed. Affected symbols by hop distance, affected files, severity. For pre-change checks, prefer preflight (includes impact plus tests and fitness)."""
245
+
"""Show the blast radius of changing a symbol.
246
+
247
+
Everything that would break if its signature or behavior changed.
248
+
Affected symbols by hop distance, affected files, severity. For
249
+
pre-change checks, prefer preflight (includes impact plus tests
250
+
and fitness)."""
214
251
return_run_roam(["impact", symbol], root)
215
252
216
253
217
254
@_tool(name="roam_file_info")
218
255
deffile_info(path: str, root: str=".") ->dict:
219
-
"""Show a file skeleton: every symbol definition with its signature. Call this to understand what a file contains without reading the full source. More useful than Read for getting a file overview."""
256
+
"""Show a file skeleton: every symbol definition with its signature.
257
+
258
+
Call this to understand what a file contains without reading the
259
+
full source. More useful than Read for getting a file overview."""
"""Compute a risk score (0-100) for pending changes. Call this before committing or creating a PR. Produces LOW/MODERATE/HIGH/CRITICAL rating with per-file breakdown, risk factors, and suggested reviewers."""
270
+
"""Compute a risk score (0-100) for pending changes.
271
+
272
+
Call this before committing or creating a PR. Produces LOW/MODERATE/
273
+
HIGH/CRITICAL rating with per-file breakdown, risk factors, and
"""Find test files that exercise changed code. Call this to know which tests to run after making changes. Walks reverse dependency edges from changed code to find test files. For a full pre-change check, prefer preflight (includes affected tests plus blast radius and fitness)."""
303
+
"""Find test files that exercise changed code.
304
+
305
+
Call this to know which tests to run after making changes. Walks
306
+
reverse dependency edges from changed code to find test files. For
307
+
a full pre-change check, prefer preflight (includes affected tests
"""List unreferenced exported symbols (dead code candidates). Call this to find code that can be safely removed. Finds symbols with zero incoming edges, filtering out known entry points and framework lifecycle hooks. Includes safety verdict per symbol."""
"""Rank functions by cognitive complexity. Call this to find the most complex functions that should be refactored. For checking a single symbol, prefer context or preflight which include complexity data."""
383
+
"""Rank functions by cognitive complexity.
384
+
385
+
Call this to find the most complex functions that should be
386
+
refactored. For checking a single symbol, prefer context or
"""Root cause analysis for a failing symbol or test. Call this when debugging a bug or test failure to find the likely root cause. Ranks upstream/downstream suspects by risk (git churn, complexity, health, co-change entropy). Faster than manually tracing call chains. Returns verdict naming top suspect."""
485
+
"""Root cause analysis for a failing symbol or test.
486
+
487
+
Call this when debugging a bug or test failure to find the likely
488
+
root cause. Ranks upstream/downstream suspects by risk (git churn,
489
+
complexity, health, co-change entropy). Faster than manually tracing
490
+
call chains. Returns verdict naming top suspect."""
"""Blast radius of uncommitted or committed changes. Call this after making code changes to see what's affected BEFORE committing. Shows affected symbols, files, tests, coupling warnings, and fitness violations. For pre-PR analysis, use pr_risk instead."""
1497
+
"""Blast radius of uncommitted or committed changes.
1498
+
1499
+
Call this after making code changes to see what's affected BEFORE
"""File-level import/imported-by relationships. Call this to understand a file's dependencies -- what it imports and what imports it. Use for module boundary analysis and refactoring impact."""
1538
+
"""File-level import/imported-by relationships.
1539
+
1540
+
Call this to understand a file's dependencies -- what it imports
1541
+
and what imports it. Use for module boundary analysis and
"""All consumers of a symbol: callers, importers, inheritors grouped by edge type (calls, imports, inheritance, trait usage). Broader than impact. Use for planning API changes."""
1551
+
"""All consumers of a symbol: callers, importers, inheritors.
1552
+
1553
+
Grouped by edge type (calls, imports, inheritance, trait usage).
1554
+
Broader than impact. Use for planning API changes."""
0 commit comments