Claude Code multi-agent

Mini Claude Code

mini-claude-code: a simplified Java Claude Code agent distilling core Agent Harness mechanisms. Features: Agent Loop, tools, permission control, Hooks, Todo, Subagent, Skill Loading, context compression, memory, tasks, background tasks, scheduling, multi-agent collaboration, team protocol, autonomous claiming, MCP Plugin.

Install

From source
git clone https://github.com/DerekYRC/mini-claude-code.git

From the README

mini-claude-code

English | 简体中文

姊妹版:
- mini-spring (简化版的spring框架)
- mini-spring-cloud (简化版的spring cloud框架)
- mini-netty (简化版的netty框架)

关于

mini-claude-code 是一个简化版的Java版 Claude Code 编程 Agent 项目,能帮助你快速理解编码 Agent 的核心原理。项目抽取了 Agent Harness 的关键机制,代码尽量精简,保留核心功能,如 Agent Loop、工具调用、权限控制、Hooks、Todo、Subagent、Skill Loading、上下文压缩、记忆系统、任务系统、后台任务、定时调度、多 Agent 协作、团队协议、自主认领任务和 MCP Plugin 等功能。

项目按章节拆解一个编码 Agent 的核心机制,每章对应一个独立分支,并尽量保留理解当前机制所需的最小代码。

如果本项目能帮助到你,请给个 STAR,谢谢!

功能

* s01 Agent Loop — ReAct:思考-行动-观察,LLM ⇄ Tool 闭环
* s02 Tool Dispatch — Tool Use:注册即用,不改主循环
* s03 Permission — Guardrails:三层校验,先审后执行
* s04 Hooks — Lifecycle:四个事件点,横切逻辑不侵入循环
* s05 Todo — Planning:先规划再执行,状态可追踪
* s06 Subagent — Delegation:委托子代理,上下文干净隔离
* s07 Skill Loading — Lazy Skill Loading:索引在 Prompt,正文按需加载
* s08 Context Compact — Context Compression:四层压缩管线,满了就腾空间
* s09 Memory — Long-term Memory:记什么、忘什么、何时合并
* s10 Task System — Task Orchestration:任务图 + 状态机 + 依赖检查
* s11 Background Tasks — Async:慢操作丢后台,Agent 继续思考
* s12 Cron Scheduler — Scheduled Trigger:cron 表达式,无人值守触发
* s13 Agent Teams — Multi-Agent:Lead 派活,队友并行干活
* s14 Team Protocols — Structured Communication:request_id + 状态机,队友间结构化通信
* s15 Autonomous Agents — Self-Organization:队友扫看板,有活自己认领
* s16 MCP Plugin — MCP:动态工具池,能力不够插上就用

使用方法

1. 准备环境

本项目需要 Java 17 和 Maven。

运行真实模型 demo 前,先在 shell 中设置:

2. 切换章节分支

每章对应一个教学分支。比如学习 s01:

3. 启动 Demo

使用 Maven 启动指定 demo:

4. 阅读源码说明

阅读 changelog.md

提问

点此提问

贡献

欢迎 Pull Request。

参考项目

- learn-claude-code(强烈推荐)
Read the full README on GitHub

Details

Language
Java
Last updated
7 July 2026

FAQ

What is Mini Claude Code?

mini-claude-code: a simplified Java Claude Code agent distilling core Agent Harness mechanisms. Features: Agent Loop, tools, permission control, Hooks, Todo, Subagent, Skill Loading, context compression, memory, tasks, background tasks, scheduling, multi-agent collaboration, team protocol, autonomous claiming, MCP Plugin. It is a multi-agent for Claude Code, from DerekYRC/mini-claude-code on GitHub.

How do I install Mini Claude Code?

Clone DerekYRC/mini-claude-code from GitHub and follow the setup steps in its README.

Is Mini Claude Code popular?

DerekYRC/mini-claude-code has 174 GitHub stars and 30 forks. It was last updated on 7 July 2026.

More multi-agent & worktrees

Browse the most popular Claude Code mods, all multi-agent & worktrees, or the skills and MCP server directories.