ast-grep-api

Community

Programmable AST tooling for code search

Authorhafley66
Version1.0.0
Installs0

System Documentation

What problem does it solve?

Provides programmatic access to AST-based tooling across Rust crates, Node.js NAPI, and Python bindings for parsing, searching, and rewriting code.

Core Features & Use Cases

  • Parse source into AST using Rust crates, Node.js NAPI, or Python bindings
  • Search for structural patterns with metavariable capture
  • Extract matched node text and byte offsets
  • Apply code rewrites
  • Load and run YAML rule configs programmatically

Quick Start

Invoke the AST API to parse code, search for patterns with metavariables, and apply a rewrite using YAML rule configs.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: ast-grep-api
Download link: https://github.com/hafley66/claude-research/archive/main.zip#ast-grep-api

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.