Clawe

A multi-agent coordination system powered by OpenClaw.

Deploy a team of AI agents that work together, each with their own identity, workspace, and scheduled heartbeats. Coordinate tasks, share context, and deliver notifications in near real-time.

## Features - Run multiple AI agents with distinct roles and personalities - Agents wake on cron schedules to check for work - Kanban-style task management with assignments and subtasks - Instant delivery of @mentions and task updates - Agents collaborate through shared files and Convex backend - Monitor squad status, tasks, and chat with agents from a web dashboard ## Quick Start ### Prerequisites - Docker & Docker Compose - [Convex](https://convex.dev) account (free tier works) - Anthropic API key ### 1. Clone and Setup ```bash git clone https://github.com/getclawe/clawe.git cd clawe cp .env.example .env ``` ### 2. Configure Environment Edit `.env`: ```bash # Required SQUADHUB_TOKEN=your-secure-token CONVEX_URL=https://your-deployment.convex.cloud # API keys (Anthropic, OpenAI) are configured via the UI during onboarding ``` ### 3. Deploy Convex Backend ```bash pnpm install cd packages/backend npx convex deploy ``` ### 4. Start the System **Production (recommended):** ```bash ./scripts/start.sh ``` This script will: - Create `.env` from `.env.example` if missing - Auto-generate a secure `SQUADHUB_TOKEN` - Validate all required environment variables - Build necessary packages - Start the Docker containers **Development:** ```bash # Start squadhub gateway only (use local web dev server) pnpm dev:docker # In another terminal, start web + Convex pnpm dev ``` The production stack starts: - **squadhub**: Gateway running all agents - **watcher**: Notification delivery + cron setup - **clawe**: Web dashboard at http://localhost:3000 ## The Squad Clawe comes with 4 pre-configured agents: | Agent | Role | Heartbeat | | -------- | -------------- | ------------ | | 🦞 Clawe | Squad Lead | Every 15 min | | ✍️ Inky | Content Editor | Every 15 min | | 🎨 Pixel | Designer | Every 15 min | | πŸ” Scout | SEO | Every 15 min | Heartbeats are staggered to avoid rate limits. ## Routines Schedule recurring tasks that automatically create inbox items: - Configure day/time schedules per routine - 1-hour trigger window for crash tolerance - Tasks created with Clawe as the creator - Manage via Settings β†’ General in the dashboard ## Architecture ``` β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ DOCKER COMPOSE β”‚ β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€ β”‚ squadhub β”‚ watcher β”‚ clawe β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ Agent Gateway β”‚ β€’ Register agents β”‚ Web Dashboard β”‚ β”‚ with 4 agents β”‚ β€’ Setup crons β”‚ β€’ Squad status β”‚ β”‚ β”‚ β€’ Deliver notifs β”‚ β€’ Task board β”‚ β”‚ β”‚ β”‚ β€’ Agent chat β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”‚ β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ CONVEX β”‚ β”‚ (Backend) β”‚ β”‚ β”‚ β”‚ β€’ Agents β”‚ β”‚ β€’ Tasks β”‚ β”‚ β€’ Notificationsβ”‚ β”‚ β€’ Activities β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ ``` ## Project Structure ``` clawe/ β”œβ”€β”€ apps/ β”‚ β”œβ”€β”€ web/ # Next.js dashboard β”‚ └── watcher/ # Notification watcher service β”œβ”€β”€ packages/ β”‚ β”œβ”€β”€ backend/ # Convex schema & functions β”‚ β”œβ”€β”€ cli/ # `clawe` CLI for agents β”‚ β”œβ”€β”€ shared/ # Shared squadhub client β”‚ └── ui/ # UI components └── docker/ └── squadhub/ β”œβ”€β”€ Dockerfile β”œβ”€β”€ entrypoint.sh β”œβ”€β”€ scripts/ # init-agents.sh └── templates/ # Agent workspace templates ``` ## CLI Commands Agents use the `clawe` CLI to interact with the coordination system: ```bash # Check for notifications clawe check # List tasks clawe tasks clawe tasks --status in_progress # View task details clawe task:view # Update task status clawe task:status in_progress clawe task:status review # Add comments clawe task:comment "Working on this now" # Manage subtasks clawe subtask:add "Research competitors" clawe subtask:check 0 # Register deliverables clawe deliver "Final Report" --path ./report.md # Send notifications clawe notify "Need your review on this" # View squad status clawe squad # Activity feed clawe feed ``` ## Agent Workspaces Each agent has an isolated workspace with: ``` /data/workspace-{agent}/ β”œβ”€β”€ AGENTS.md # Instructions and conventions β”œβ”€β”€ SOUL.md # Agent identity and personality β”œβ”€β”€ USER.md # Info about the human they serve β”œβ”€β”€ HEARTBEAT.md # What to do on each wake β”œβ”€β”€ MEMORY.md # Long-term memory β”œβ”€β”€ TOOLS.md # Local tool notes └── shared/ # Symlink to shared state β”œβ”€β”€ WORKING.md # Current team status └── WORKFLOW.md # Standard operating procedures ``` ## Customization ### Adding New Agents 1. Create workspace template in `docker/squadhub/templates/workspaces/{name}/` 2. Add agent to `docker/squadhub/templates/config.template.json` 3. Add agent to watcher's `AGENTS` array in `apps/watcher/src/index.ts` 4. Rebuild: `docker compose build && docker compose up -d` ### Changing Heartbeat Schedules Edit the `AGENTS` array in `apps/watcher/src/index.ts`: ```typescript const AGENTS = [ { id: "main", name: "Clawe", emoji: "🦞", role: "Squad Lead", cron: "0 * * * *", }, // Add or modify agents here ]; ``` ## Development ```bash # Install dependencies pnpm install # Terminal 1: Start Convex dev server pnpm convex:dev # Terminal 2: Start squadhub gateway in Docker pnpm dev:docker # Terminal 3: Start web dashboard pnpm dev:web # Or run everything together (Convex + web, but not squadhub) pnpm dev ``` ### Useful Commands ```bash # Build everything pnpm build # Type check pnpm check-types # Lint and format pnpm check # Check only pnpm fix # Auto-fix # Deploy Convex to production pnpm convex:deploy ``` ## Environment Variables | Variable | Required | Description | | ---------------- | -------- | ------------------------------- | | `SQUADHUB_TOKEN` | Yes | Auth token for squadhub gateway | | `CONVEX_URL` | Yes | Convex deployment URL | API keys (Anthropic, OpenAI) are managed via the UI during onboarding and in Settings > General > API Keys.