> For the complete documentation index, see [llms.txt](https://pharaoh.so/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://pharaoh.so/docs/tools-reference/investigate.md).

# Investigate Tools

Trace impact and verify assumptions before committing. Blast Radius and Query Dependencies are free. Check Reachability and Vision Docs are Pro (with free-tier preview).

## get\_blast\_radius

**Question it answers:** "What breaks if I change this?"

Traces all downstream callers of a function, file, or module up to 5 hops deep. Returns a risk assessment (LOW/MEDIUM/HIGH), affected callers grouped by module, impacted HTTP endpoints, impacted cron jobs, and affected DB operations.

**When to use:** Before refactoring, renaming, or deleting anything. Especially before touching shared utilities.

**Parameters:**

* `repo` (required): Repository name
* `entity` (required): Function name, file path, or module name
* `entity_type` (required): `"function"`, `"file"`, or `"module"`
* `depth` (optional): How many hops to trace (default: 3, max: 5)

**Example:** "What breaks if I change the `formatMessage` function?" → Returns 14 callers across 4 modules, 3 affected endpoints.

## query\_dependencies

**Question it answers:** "How are these two modules connected?"

Traces forward and reverse dependency paths between two modules. Detects circular dependencies with warnings. Lists all shared dependencies (modules both depend on).

**When to use:** Before splitting, merging, or decoupling modules. When you suspect a circular dependency.

**Parameters:**

* `repo` (required): Repository name
* `from` (required): Source module name
* `to` (required): Target module name

## check\_reachability (Pro)

**Question it answers:** "Is this function actually wired into the app?"

Verifies whether exported functions are reachable from production entry points — API endpoints, CLI commands, cron handlers, event handlers, MCP tools. Returns classification: entry\_point / reachable / unreachable.

**When to use:** After implementing a feature, to verify new code is wired. Before opening a PR, as a pre-flight check. When cleaning up dead code.

Free tier receives a preview — one specific detail plus aggregate counts.

**Parameters:**

* `repo` (required): Repository name
* `module` (optional): Filter to a specific module
* `functions` (optional): Specific function names to check
* `include_paths` (optional): Include full reachability paths

## get\_vision\_docs (Pro)

**Question it answers:** "Is there a spec for this, and does the code match?"

Compares CLAUDE.md files, PRDs, and vision documents against the actual implementation. Finds where specs exist but code doesn't match, or where code exists without any spec.

**When to use:** Before implementing a spec — verify what the spec says. After implementation — verify the code matches.

Free tier receives a preview with partial results.

**Parameters:**

* `repo` (required): Repository name
* `module` (optional): Filter to a specific module


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://pharaoh.so/docs/tools-reference/investigate.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
