ast-mcp-server

ast-mcp-server

3.4

If you are the rightful owner of ast-mcp-server and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.

An MCP (Model Context Protocol) server that provides code structure and semantic analysis capabilities through Abstract Syntax Trees (AST) and Abstract Semantic Graphs (ASG).

The AST MCP Server is a powerful tool designed to parse and analyze code using Abstract Syntax Trees (AST) and Abstract Semantic Graphs (ASG). It supports multiple programming languages, including Python and JavaScript, and offers features such as code structure analysis, complexity metrics, and incremental parsing for efficient processing of large files. The server is compatible with Claude Desktop and other MCP clients, providing enhanced scope handling and semantic analysis. It also includes AST diffing capabilities to identify changes between code versions. The server is fully operational and integrates seamlessly with Claude Desktop, offering robust code analysis tools.

Features

  • Parse code into Abstract Syntax Trees (AST)
  • Generate Abstract Semantic Graphs (ASG) from code
  • Analyze code structure and complexity
  • Support for multiple programming languages (Python, JavaScript)
  • Incremental parsing for faster processing of large files

Tools

  1. parse_to_ast

    Parse code into an Abstract Syntax Tree

  2. generate_asg

    Generate an Abstract Semantic Graph from code

  3. analyze_code

    Analyze code structure and complexity

  4. supported_languages

    Get the list of supported programming languages

  5. parse_and_cache

    Parse code into an AST and cache it for resource access