ClawTeam: AI Agents Form Swarms, Think & Work Together
ClawTeam: Agent Swarm Intelligence – A Revolutionary Approach to AI Collaboration
Introduction: The Evolution of AI Agents from Isolation to Collective Intelligence
The landscape of artificial intelligence has undergone a transformative shift, moving beyond the limitations of solitary agents toward Agent Swarm Intelligence. ClawTeam introduces a groundbreaking framework that enables AI agents to self-organize into dynamic teams, collaboratively tackle complex tasks, and autonomously optimize workflows. Unlike traditional AI systems that operate in silos, ClawTeam empowers agents to spawn specialized sub-agents, allocate tasks intelligently, coordinate seamlessly, and adapt dynamically—all under a single command line interface.
This description explores the core principles, key features, use cases, and technical architecture of ClawTeam, highlighting how it redefines automation in AI-driven development, research, finance, and beyond.
Core Philosophy: From Solo Agents to Swarm Intelligence
The Problem with Isolated AI Agents
Current AI agents, while powerful individually, struggle when faced with complex tasks. Users often find themselves manually coordinating multiple agents, juggling context, and stitching together fragmented results—a process that is inefficient and error-prone. ClawTeam addresses this by introducing Agent Swarm Intelligence, where AI agents form collaborative teams to:
- Spawn specialized sub-agents (each with dedicated environments).
- Design intelligent task allocation with dependency management.
- Facilitate real-time coordination through seamless inter-agent communication.
- Monitor team performance and dynamically reallocate resources.
The result? A system where the user sets a vision, while the swarm executes autonomously—achieving breakthrough solutions without human intervention.
Illustration depicting how ClawTeam orchestrates agents into a collaborative swarm.
Key Features of ClawTeam
1. AI Research Automation
ClawTeam excels in large-scale automated machine learning (ML) experimentation, leveraging principles from Karpathy’s autoresearch. It enables:
- Large-Scale Automated ML Experimentation: Spawns specialized agents across multiple GPUs to run thousands of experiments autonomously.
- AI Model Training & Optimization: Dynamically reallocates resources based on real-time performance metrics, optimizing hyperparameters in real time.
- Self-Improving Model Architectures: Agents generate and validate hypotheses independently, leading to iterative improvements.
Example: Autonomous ML Research with 8 H100 GPUs A user prompts ClawTeam to optimize an LLM training setup using eight GPUs. The system:
- Spawns 8 specialized research agents across the GPUs.
- Designs over 2,000 autonomous experiments (e.g., varying model depth, learning rates, batch sizes).
- Dynamically reallocates resources based on performance feedback.
- Achieves a 6.4% improvement in validation loss (val_bpb: 1.044 → 0.977) after 2430 experiments.
Visualization of autonomous ML experimentation across multiple GPUs.
2. Agentic Engineering
ClawTeam enables autonomous full-stack development, where AI agents self-organize to build, test, and deploy software systems:
- Autonomous Full-Stack Development: Agents design, implement, and integrate modules (e.g., APIs, databases, frontends) without manual oversight.
- Self-Evolving Software: Tasks are dynamically reassigned based on progress, ensuring continuous improvement.
- Collaborative Open Source Development: Multiple agents work in parallel branches, reducing merge conflicts and accelerating contributions.
Example: Building a Full-Stack Todo App A user prompts ClawTeam to build a full-stack todo application. The system:
- Spawns a team of 5 sub-agents (architect, backend1, backend2, frontend, tester).
- Assigns tasks with dependency chains (e.g., "Design API schema" → "Implement JWT auth").
- Auto-unblocks agents when dependencies are met.
- Integrates results into a single branch for deployment.
3. AI Hedge Fund Automation
ClawTeam provides pre-built templates for AI-driven investment analysis, where agents analyze market data, optimize portfolios, and execute trades autonomously:
- Automated Market Research & Data Mining: Agents scrape financial data, identify trends, and generate signals.
- Multi-Strategy Portfolio Optimization: Combines value investing, growth analysis, technical indicators, and sentiment analysis.
- Real-Time Risk Assessment: Dynamically adjusts positions based on market volatility.
Example: Launching a 7-Agent Hedge Fund Team A user commands:
clawteam launch hedge-fund --team fund1 --goal "Analyze AAPL, MSFT, NVDA for Q2 2026"
The system automatically spawns:
- Portfolio Manager (leader agent).
- 5 Analyst Agents (value investing, growth analysis, technical indicators, fundamentals, sentiment analysis).
- Risk Manager, who consolidates signals and makes buy/sell decisions.
4. Custom Swarm Templates
ClawTeam supports TOML-based team templates, allowing users to define specialized roles for any domain:
- Custom Scientific Research Teams: Agents specialize in different aspects of a project (e.g., data collection, model training, validation).
- Personalized Investment Committees: Tailored to individual investment strategies.
- Business Operations Teams: Automating workflows like customer support, supply chain management, or marketing campaigns.
Example: Creating a Content Production Studio A user defines a TOML template for a content team:
team = "content-studio"
agents = [
{ name = "researcher", task = "analyze audience trends" },
{ name = "writer", task = "draft blog posts" },
{ name = "editor", task = "edit and polish content" }
]
The system spawns agents with predefined roles, ensuring seamless collaboration.
Technical Architecture: How ClawTeam Works
1. Agent Self-Organization
ClawTeam’s core mechanism involves:
- Leader Agents: Spawn and manage worker agents.
- Auto-Injected Coordination Prompts: Each spawned agent receives a prompt to:
- Check tasks (
clawteam task list). - Update status (
clawteam task update --status completed). - Message teammates (
clawteam inbox send). - Report idle state (
clawteam lifecycle idle).
Example Workflow:
# Leader agent spawns a worker:
clawteam spawn --team my-team --agent-name alice --task "Implement OAuth2"
# Worker updates status:
clawteam task update my-team --status completed
# Leader receives feedback via inbox:
clawteam inbox receive my-team leader
2. Workspace Isolation
Each agent operates in its own isolated environment:
- Git Worktrees: Agents work on separate branches, preventing merge conflicts.
- Tmux Windows: Interactive UIs for real-time monitoring.
- Atomic File Writes: Ensures crash safety with temporary files.
Example:
clawteam workspace list # Lists all active workspaces
clawteam workspace cleanup --force # Cleans up unused worktrees
3. Task Tracking & Dependencies
ClawTeam uses a kanban-style task board to manage dependencies:
- Tasks progress from
pending→in_progress→completed/blocked. --blocked-bychains ensure agents auto-unblock when dependencies are met.task wait --timeout 300blocks until all tasks complete.
4. Inter-Agent Messaging
Agents communicate via:
- Inboxes: Point-to-point messaging (
clawteam inbox send,receive). - Broadcasts: Messages sent to all team members.
- ZeroMQ P2P Transport (optional): Low-latency fallback for distributed teams.
5. Monitoring & Dashboards
Users can monitor the swarm via:
- Terminal Kanban Board:
clawteam board show. - Live Dashboard: Auto-refreshing UI:
clawteam board live --interval 3. - Tiled Tmux View:
clawteam board attach. - Web UI:
clawteam board serve --port 8080.
Use Cases & Real-World Applications
1. Autonomous ML Research
ClawTeam automates hyperparameter tuning, model selection, and validation across thousands of experiments:
- Input: "Optimize this LLM training setup using 8 GPUs."
- Output: A swarm of agents runs 2430+ experiments, achieving a 6.4% improvement in validation loss.
Progress visualization of autonomous ML experimentation.
2. Agentic Software Engineering
Users can delegate entire software projects to AI agents:
- Input: "Build a full-stack todo app with auth, database, and React frontend."
- Output: A team of 5 agents (architect, backend1, backend2, frontend, tester) collaborates autonomously.
3. AI Hedge Fund Automation
ClawTeam provides pre-built templates for financial analysis:
- Input: "Analyze AAPL, MSFT, NVDA for Q2 2026."
- Output: A 7-agent team (portfolio manager + analysts) generates buy/sell signals.
4. Custom Swarm Templates
Users can define their own templates for any domain:
- Example: A content production studio with researchers, writers, and editors.
- Example: A business operations team automating customer support workflows.
Installation & Quick Start
Prerequisites
- Python 3.10+.
- Tmux (for interactive monitoring).
- A CLI coding agent (e.g., Claude Code, Codex).
Installation
pip install clawteam
# Or from source:
git clone https://github.com/HKUDS/ClawTeam.git
cd ClawTeam
pip install -e .
Quick Start Options
Option 1: Let the Agent Drive (Recommended)
ClawTeam ships with a Claude Code skill that auto-activates:
"Build a web app. Use clawteam to split the work across multiple agents."
The agent automatically creates a team, spawns workers, and coordinates tasks.
Option 2: Manual Driving
- Create a team (leader):
clawteam team spawn-team my-team -d "Build auth module" -n leader
- Spawn worker agents:
clawteam spawn --team my-team --agent-name alice --task "Implement OAuth2"
clawteam spawn --team my-team --agent-name bob --task "Write unit tests"
- Monitor the swarm:
clawteam board attach my-team # Tiled tmux view
clawteam board serve --port 8080 # Web UI
Supported Agents
ClawTeam works with any CLI agent, including:
- Claude Code (
clawteam spawn tmux claude). - Codex (
clawteam spawn tmux codex). - OpenClaw (
clawteam spawn tmux openclaw). - nanobot (
clawteam spawn tmux nanobot). - Custom scripts (via
subprocess).
Command Reference
Core Commands
| Command | Description |
|---------|-------------|
| clawteam team spawn-team -d "desc" -n name | Create a new team. |
| clawteam spawn --team <name> --agent-name <name> --task "<task>" | Spawn an agent. |
| clawteam task list --status blocked | List blocked tasks. |
| clawteam inbox send "message" | Send a message to the leader. |
| clawteam board show | View terminal kanban board. |
Workspace & Plan Management
| Command | Description |
|---------|-------------|
| clawteam workspace list | List active workspaces. |
| clawteam plan submit "plan" --summary "TL;DR" | Submit a task plan for approval. |
| clawteam lifecycle idle | Report idle state. |
Templates & Config
| Command | Description |
|---------|-------------|
| clawteam launch hedge-fund --goal "<task>" | Launch a pre-built template. |
| clawteam config set transport p2p | Enable ZeroMQ P2P transport. |
Architecture Overview
ClawTeam’s architecture is designed for scalability and crash safety:
- State Storage: JSON files in
~/.clawteam/(no database, no cloud). - Atomic Writes: Temporary files ensure data integrity.
- Multi-Machine Support: Via ZeroMQ P2P or shared filesystem.
Diagram illustrating ClawTeam’s architecture.
Roadmap & Future Enhancements
| Phase | Version | Feature | Status | |-------|---------|---------|--------| | Current | v0.3 | File + P2P transport, Web UI, multi-user templates | ✅ Shipped | | Phase 1 | v0.4 | Redis Transport (cross-machine messaging) | 🔜 Planned | | Phase 2 | v0.5 | Shared State Layer (team config across machines) | 🔜 Planned | | Phase 3 | v0.6 | Agent Marketplace (community templates) | 💡 Exploring | | Phase 4 | v0.7 | Adaptive Scheduling (dynamic task reallocation) | 💡 Exploring |
Contributing & Community
ClawTeam is designed to be extensible:
- New Agent Integrations: Add support for more AI coding agents.
- Custom Templates: Define TOML templates for new domains (e.g., DevOps, data science).
- Transport Backends: Implement Redis, NATS, or other message transports.
Conclusion: The Future of AI Collaboration
ClawTeam represents a paradigm shift in AI automation—where agents think as a team, work autonomously, and deliver results faster than ever. By eliminating the need for manual coordination, ClawTeam unlocks new possibilities in research, development, finance, and beyond.
Whether you’re optimizing ML models, building software systems, or automating financial strategies, ClawTeam provides the tools to turn complex tasks into seamless swarms of intelligence. The future of AI is collaborative—and ClawTeam leads the way.
Thank you for exploring ClawTeam! 🦞✨ One CLI. Infinite possibilities.
Enjoying this project?
Discover more amazing open-source projects on TechLogHub. We curate the best developer tools and projects.
Repository:https://github.com/HKUDS/ClawTeam
GitHub - HKUDS/ClawTeam: ClawTeam: AI Agents Form Swarms, Think & Work Together
<p><strong>ClawTeam: Agent Swarm Intelligence – A Revolutionary Approach to AI Collaboration</strong></p> <h2 id="introductiontheevolutionofaiagentsfromisolatio...
github - hkuds/clawteam