Metadata-Version: 2.4
Name: angr-api-mcp
Version: 0.1.0
Summary: MCP server for angr binary analysis API workflow retrieval
Project-URL: Homepage, https://github.com/Taardisaa/angr-api-mcp
Project-URL: Repository, https://github.com/Taardisaa/angr-api-mcp
Author-email: Hao Ren <136665562@qq.com>
License-Expression: MIT
License-File: LICENSE
Keywords: angr,api,binary-analysis,mcp,reverse-engineering,workflow
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Software Development :: Debuggers
Requires-Python: >=3.10
Requires-Dist: chromadb>=0.5.0
Requires-Dist: click>=8.0
Requires-Dist: mcp[cli]>=1.2.0
Requires-Dist: tree-sitter-languages>=1.10.0
Requires-Dist: tree-sitter==0.21.3
Provides-Extra: dev
Requires-Dist: build>=1.0; extra == 'dev'
Requires-Dist: pytest-asyncio>=0.21; extra == 'dev'
Requires-Dist: pytest>=7.0; extra == 'dev'
Requires-Dist: ruff>=0.1.0; extra == 'dev'
Requires-Dist: twine>=5.0; extra == 'dev'
Description-Content-Type: text/markdown

# angr-api-mcp

MCP server for [angr](https://github.com/angr/angr) binary analysis API workflow retrieval.

Extracts real API usage patterns from angr's source code and angr-doc examples, then indexes them with semantic search so LLMs can query correct API call sequences.

## Installation

### Via Claude Code (recommended)

```bash
claude mcp add angr-api-mcp -- uvx angr-api-mcp
```

### Via Claude Desktop

```json
{
  "mcpServers": {
    "angr": {
      "command": "uvx",
      "args": ["angr-api-mcp"]
    }
  }
}
```

### Via pip

```bash
pip install angr-api-mcp
```

## First-time setup

After adding the server, build the index by calling the `initialize_index` tool from Claude:

```
initialize_index()
```

This clones angr and angr-doc from GitHub and builds the semantic index
(~5–10 minutes). The index is stored at `~/.local/share/angr-api-mcp/chroma_db`
and persists across restarts.

Or run from the command line:

```bash
angr-api-mcp-admin build-index

# Point at local repos to skip cloning
angr-api-mcp-admin build-index --angr-path /path/to/angr --angr-doc-path /path/to/angr-doc
```

## MCP Tools

| Tool | Description |
|---|---|
| `initialize_index` | Build the workflow index |
| `get_workflows` | Search API call sequences by task description |
| `get_api_doc` | Look up a class or method |
| `list_related_apis` | Find co-occurring APIs |
| `get_index_info` | Show index metadata |
| `clear_index` | Wipe the index |

## CLI (admin / inspection)

```bash
# Search for workflows by task
angr-api-mcp-admin inspect workflows "run CFG analysis on a binary"
angr-api-mcp-admin inspect workflows "symbolic execution to find target address"

# Look up a class or method
angr-api-mcp-admin inspect api-doc SimulationManager
angr-api-mcp-admin inspect api-doc CFGFast

# Find co-occurring APIs
angr-api-mcp-admin inspect related Project

# Index info
angr-api-mcp-admin inspect info
```
