NT

nendotools/tree-sitter-mcp

Developer tools

이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요. 원문 보기

33 stars 6 forks 품질 68 트렌드 11GPL-3.0

이 저장소는 트리 시터에 의해 생성 된 코드 구조적 데이터를 노출하여 AI 시스템에 의해 더 많은 정보를 알리는 코드 분석 및 개선.

개요

일반적인 프로그래밍 언어에 대한 빠른 semantic 코드 검색 및 분석. 기능 및 클래스 검색, 추적 코드 사용 및 전체 프로젝트의 코드 품질을 분석. Claude Code와 같은 AI 도구에 대한 독립 CLI 도구와 MCP 서버 모두 작동합니다. - - 15 + 언어의 이름에 의해 기능, 클래스 및 변수를 찾기 - 변경하기 전에 코드가 사용되는 곳을 참조하십시오 - 복잡한 기능, 죽은 코드 및 건축 문제를 감지 - - 코드를 파싱하여 Sub-100ms 검색, 텍스트를 스캔하지 - - 프로젝트에서 즉시 작동 JavaScript, TypeScript, Python, Go, Rust, Java, C/C++, Ruby, C#, PHP, Kotlin, Scala, Elixir MCP 서버로 사용될 때, AI 조수에 대한 이러한 도구를 제공합니다: - search code - 함수, 클래스, 변수에 대한 검색 - find usage - 프로젝트 전반에 걸쳐 식별자의 모든 사용 찾기 - analysis code - 포괄적인 코드 품질 및 구조 분석 - check errors - 상세한 상황에 맞는 오류 찾기 전체보기.

개요(AI 번역)

일반적인 프로그래밍 언어에 대한 빠른 semantic 코드 검색 및 분석. 기능 및 클래스 검색, 추적 코드 사용 및 전체 프로젝트의 코드 품질을 분석.

Claude Code와 같은 AI 도구에 대한 독립 CLI 도구와 MCP 서버 모두 작동합니다.

시작하기

설치:

코드 검색:

Analyze 코드 품질:

Find 문법 오류:

** Claude Desktop 설정:**

**[T0]]:**을 추가하여 수동으로 구성

특징

  • Semantic search - 15개 이상의 언어로 기능, 클래스 및 변수 찾기 -Usage tracing - 변경하기 전에 코드가 사용되는 곳
  • Quality Analysis - 복잡한 기능, 죽은 코드 및 건축 문제 감지
  • **빠른 결과 ** - 텍스트를 스캔하지 않은 코드 구조를 파싱하여 Sub-100ms 검색
  • ** 구성 없음 ** - 프로젝트에서 즉시 작동

지원 언어

JavaScript, TypeScript, Python, Go, Rust, Java, C/C++, Ruby, C#, PHP, Kotlin, Scala, Elixir

구성 파일: JSON, YAML, TOML, .env

CLI 사용

코드 요소 검색:

** 식별자의 사용:**

Analyze 코드 품질:

Find 문법 오류:

이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요.

README

원문 README의 일부입니다. 원문 보기.

Tree-Sitter MCP

Fast semantic code search and analysis for common programming languages. Search for functions and classes, trace code usage, and analyze code quality across your entire project.

Works as both a standalone CLI tool and an MCP server for AI tools like Claude Code.

Getting Started

Install:

npm install -g @nendo/tree-sitter-mcp

Search for code:

tree-sitter-mcp search "handleRequest" --type function

Analyze code quality:

tree-sitter-mcp analyze --analysis-types quality deadcode structure

Find syntax errors:

tree-sitter-mcp errors --output text

Setup with Claude Desktop:

tree-sitter-mcp setup --auto

Or configure manually by adding to ~/.config/claude-desktop/claude_desktop_config.json:

{
  "mcpServers": {
    "tree-sitter-mcp": {
      "command": "npx",
      "args": ["@nendo/tree-sitter-mcp", "--mcp"],
      "cwd": "/path/to/your/project"
    }
  }
}

Features

  • Semantic search - Find functions, classes, and variables by name across 15+ languages
  • Usage tracing - See where code is used before making changes
  • Quality analysis - Detect complex functions, dead code, and architectural issues
  • Fast results - Sub-100ms searches by parsing code structure, not scanning text
  • No configuration - Works immediately on any project

Supported Languages

JavaScript, TypeScript, Python, Go, Rust, Java, C/C++, Ruby, C#, PHP, Kotlin, Scala, Elixir

Config files: JSON, YAML, TOML, .env

CLI Usage

Search for code elements:

tree-sitter-mcp search "DatabaseManager" --exact
tree-sitter-mcp search "handle.*Request" --type function method

Find usage of identifiers:

tree-sitter-mcp find-usage "UserService" --exact
tree-sitter-mcp find-usage "API_KEY" --case-sensitive

Analyze code quality:

tree-sitter-mcp analyze --analysis-types quality structure deadcode
tree-sitter-mcp analyze src/components --analysis-types quality

Find syntax errors:

tree-sitter-mcp errors --output text
tree-sitter-mcp errors src/components --max-results 10

Setup MCP integration:

tree-sitter-mcp setup --auto
tree-sitter-mcp setup  # Manual setup instructions

MCP Tools

When used as an MCP server, provides these tools for AI assistants:

  • search_code - Search for functions, classes, variables by name
GitHub에서 전체 README 보기

설치

npx @nendo/tree-sitter-mcp --mcp
MCP 초보자라면? mcpskill.org 가이드부터 시작하세요 →

설정

{ "mcpServers": { "tree-sitter-mcp": { "command": "npx", "args": ["@nendo/tree-sitter-mcp", "--mcp"], "cwd": "/path/to/your/project" } } }