yailPeralta/ast-mcp-server
Gives coding agents compact, type-aware access to TypeScript and JavaScript projects through the real compiler project model via ts-morph, so declarations, references, rename locations and diagnostics come from the AST instead of text-search guesses. Reads are bounded and structured (ast_get_file, ast_get_outline, ast_explore, ast_find_references) and writes follow an explicit prepare-review-apply protocol with immutable hashes, freshness checks and diagnostic guards. Works as an MCP server for Codex/Cursor and as a native DeepSeek Harness plugin.
ast-mcp-server gives coding agents compact, type-aware access to TypeScript and JavaScript projects so they stop falling back to plain-text reads and text patches. Reads are bounded and structured: ast_get_file returns exact selected lines with a SHA-256 hash and freshness metadata, ast_get_outline returns body-free signatures, ast_explore returns ranked selectors, and ast_get_symbol_source, ast_find_references, ast_get_impact, ast_find_test_candidates and ast_rename_symbol answer declaration, reference, impact and rename questions from the compiler rather than text search. Writes (ast_replace_symbol_body and the rename plan) follow an explicit prepare -> review -> apply protocol with immutable hashes, workspace freshness checks, diagnostic guards and idempotent receipts, so a plausible-looking edit cannot silently target the wrong construct or introduce a new compiler error.
Install
dsh plugin --profile web add ast-mcp-server@0.13.0Copied verbatim from the README's DeepSeek Harness install line (npm form, pinned). The README also documents a local tarball form (dsh plugin --profile web add ./ast-mcp-server-0.13.1.tgz) and a global CLI/MCP install (npm install --global ast-mcp-server --ignore-scripts).
Compatibility
Requires Node.js 22.13+. It uses ts-morph, i.e. the real TypeScript compiler project model, so it needs a TypeScript/JavaScript project (JavaScript projects get type-aware where the compiler model resolves). It works as an MCP server for Codex, Cursor and any MCP-aware host, and as a native DeepSeek Harness plugin. Mutations are prepared in memory, compared against baseline diagnostics and returned as immutable, hash-bound plans that are not written until the caller reviews and applies them.
Details
- Repo: yailPeralta/ast-mcp-server
- Category: Coding & Development
- Stars: 4
- Version: GitHub repo yailPeralta/ast-mcp-server (4★, ISC); npm package ast-mcp-server at 0.13.1 (registry check 2026-10-12; registry repository field resolves back to this repo). The README's DSH install line pins 0.13.0.
Alternatives
030611/dsh-context-provenance · 030611/qiushi-dsh-evidence-audit · 0x3fffff/dsh-desktop-launcher