Content
# Tool List
A fully functional AI Coding Agent framework, featuring tool distribution, permission boundaries, hooks extension points, task system, skill loading, memory management, context compression, error recovery, background tasks, cron scheduling, team collaboration, worktree isolation, and MCP external tool access.
## ✨ Features
- **Tool Distribution and Permissions**: Built-in 27+ tools, supporting permission interception and security boundaries
- **Hooks Extension System**: UserPromptSubmit, PreToolUse, PostToolUse, Stop, and other extension points
- **Task and Planning**: todo plan + cross-session task graph
- **Sub Agent and Team**: one-time subagent + persistent teammate threads
- **Memory and Skills**: `.memory/MEMORY.md` + skill directory on-demand loading
- **Context Compression**: intelligent compression pipeline, supporting reactive compact
- **Error Recovery**: 429/529 retries, max_tokens upgrade, prompt too long recovery
- **Background Tasks**: slow operations automatically executed in the background, without blocking the main loop
- **Cron Scheduling**: scheduled task scheduler
- **Worktree Isolation**: independent branch and directory isolation
- **MCP Plugin**: supports official MCP SDK connection to external tools
## 🚀 Quick Start
### Environment Requirements
- Python 3.10+
### Install Dependencies
```bash
pip install -r requirements.txt
```
### Configuration
Create a `.env` file:
```env
ANTHROPIC_API_KEY=your-api-key
```
### Run
```bash
python main.py
```
## 📁 Project Structure
```
.
├── main.py # Entry file
├── requirements.txt # Dependency list
├── mcp_config.json # MCP server configuration
├── src/ # Core modules
│ ├── agent_loop.py # Main loop
│ ├── tool_defs.py # Tool definitions
│ ├── hooks.py # Hooks system
│ ├── task_system.py # Task system
│ ├── subagent.py # Sub Agent
│ ├── teammate.py # Teammate system
│ ├── skills.py # Skill loading
│ ├── compaction.py # Context compression
│ ├── error_recovery.py# Error recovery
│ ├── background.py # Background tasks
│ ├── cron_scheduler.py# Cron scheduling
│ ├── worktree.py # Worktree isolation
│ ├── mcp.py # MCP plugin
│ └── tools/ # Built-in tools
└── skills/ # Skill directory
├── agent-builder/ # Agent building skill
├── code-review/ # Code review skill
├── mcp-builder/ # MCP building skill
└── pdf/ # PDF processing skill
```
## 📝 Example
```bash
# Try after starting:
python main.py
# Input example:
# Create a todo list for inspecting this repo, then list Python files
# Connect to the docs MCP server and search for agent loop
# Create two tasks, create worktrees for them, then spawn alice and bob
```
## 📄 License
MIT License