lovranran avatar

MCP AST Explorer

lovranran/mcp-ast-explorer

Parses Python codebases with LibCST and exposes symbol-level tools for agents that need to navigate unfamiliar repositories without hallucinating. You get definition lookup, function signatures, same-file reference tracking, direct call chains, and basic class hierarchy queries. Built as the middle layer in a three-server onboarding stack alongside repo-mapper for structure and test-runner for verification. No LLM inference, so missing symbols return structured not-found responses instead of invented answers. Stays strictly within single-file scope in v1: no cross-file imports, no alias resolution, no dynamic lookups. Reach for this when you're building codebase exploration agents that need deterministic symbol grounding and can't afford to make up functions that don't exist.

tools
6
transport
STDIO
last updated
May 25, 2026

Tools

6 tools

Public tool metadata for what this MCP can expose to an agent.

healthReturns ok for smoke checks.

Returns ok for smoke checks.

No parameter schema in public metadata yet.

find_definitionFinds a module, class, function, or method definition.

Finds a module, class, function, or method definition.

No parameter schema in public metadata yet.

function_signatureReturns the signature for a function or method symbol.

Returns the signature for a function or method symbol.

No parameter schema in public metadata yet.

find_referencesReturns same-module CST name references for an existing symbol.

Returns same-module CST name references for an existing symbol.

No parameter schema in public metadata yet.

call_chainReturns direct callers detected from local references.

Returns direct callers detected from local references.

No parameter schema in public metadata yet.

class_hierarchyReturns direct subclasses detected from simple base-class names.

Returns direct subclasses detected from simple base-class names.

No parameter schema in public metadata yet.

Sponsors

Readme

mcp-ast-explorer

MCP server for deterministic Python codebase symbol exploration.

mcp-ast-explorer indexes Python source files with LibCST and exposes focused MCP tools for codebase onboarding: definition lookup, function signatures, local references, direct call chains, and simple class hierarchy queries.

Codebase Onboarding Stack

mcp-ast-explorer is the semantic symbol layer in a three-server MCP tool stack for Project 6 wayfinder, a codebase onboarding agent.

  • mcp-repo-mapper maps repository structure, languages, entry points, framework evidence, and Python dependency edges.
  • mcp-ast-explorer provides symbol-grounded Python definition, signature, reference, call-chain, and class-hierarchy lookups.
  • mcp-test-runner runs local pytest/Jest checks and coverage summaries so agent claims can be verified against execution.

In wayfinder, this server feeds entry-point and symbol explanation while refusing to invent missing symbols.

Status


View the full README on GitHub

Details

Repository
github.com/lovranran/mcp-ast-explorer
Package
mcp-ast-explorer
Transport
STDIO
Registry
MCP registry, active

More from lovranran