Multi-agent intelligence powered by Grok 4.20 via OpenRouter. Use for codebase analysis, refactoring, code generation, and complex reasoning.
Analyze code with Grok's multi-agent swarm. Security audit, bug detection, architecture review.
Generate production-ready code with Grok's multi-agent swarm.
Multi-perspective reasoning with Grok's swarm. Compare approaches, evaluate trade-offs, get architectural guidance.
Refactor code with Grok's multi-agent swarm. Improves quality while preserving behavior.
Manually save an OpenRouter API key to config. Last-resort fallback when OAuth fails. WARNING - key will be visible in conversation context.
Spawn an autonomous Grok agent to accomplish tasks. Use when asked to "use grok agent to refactor X", "let grok agent handle this", "grok agent mode", "autonomous grok". Triggers: "grok agent", "agent mode", "autonomous grok", "grok-swarm-agent"
Multi-agent intelligence powered by Grok 4.20 via OpenRouter. Use for codebase analysis, refactoring, code generation, and complex reasoning. Triggers: "use grok swarm", "grok 4.20", "multi-agent analysis", "codebase audit", "grok refactor", "16 agent mode"
Own this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimOwn this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimBased on adoption, maintenance, documentation, and repository signals. Not a security audit or endorsement.
Dual-Platform: OpenClaw + Claude Code
Give any AI coding agent access to Grok 4.20's 4-agent swarm with ~2M token context.
You've been building with AI coding agents for a while now. They're great — they can write features, refactor modules, analyze codebases. But there's always been this ceiling. The models they run on are designed for single-turn conversations.
Enter Grok 4.20 Multi-Agent Beta.
It's different. Instead of one model responding, it's four agents coordinating in real-time. An orchestrator, specialists, critics — all working together to break down your request and reason through it from multiple angles. It can hold ~2M tokens of context — that's entire codebases in a single request.
The Problem:
Grok 4.20 is groundbreaking, but it doesn't play nicely with current coding tools. Claude Code doesn't have a Grok integration. OpenClaw's tooling system doesn't support multi-agent swarms. If you wanted to use Grok, you'd have to hack together custom scripts or modify your platform's core components. Not ideal.
The Solution:
This plugin bridges that gap. It makes Grok 4.20 available as a tool that any agent in Claude Code or OpenClaw can call. No core modifications, no hacking — just install and go.
Now when your agent needs deep codebase analysis, large-scale refactoring, or complex reasoning, it can delegate to Grok's swarm and get back the kind of coordinated, multi-perspective thinking that single models can't deliver.
When write_files=true, Grok parses code blocks for filename annotations and writes them directly to disk, returning only a compact summary instead of the full response.
Fenced code blocks with path in the language tag:
```typescript:src/auth/login.ts
export function login() { ... }
```
Fenced code blocks with // FILE: marker:
```typescript
// FILE: src/auth/login.ts
export function login() { ... }
```
const result = await tools.grok_swarm({
prompt: "Write a FastAPI auth module with JWT",
mode: "code",
write_files: true,
output_dir: "./src"
});
// Returns: "Wrote 3 files to ./src
// src/auth.py (1,234 bytes)
// src/jwt_utils.py (567 bytes)
// src/middleware.py (890 bytes)"
Grok can generate ~350K token responses. Without file writing, that floods your orchestrator's context window. With file writing, you get a brief summary and the files on disk.
Choose the method that fits your platform:
npm install -g @openclaw/grok-swarm
# Set up API key
./scripts/setup.sh
# Add the marketplace
/plugin marketplace add https://github.com/KHAEntertainment/grok-multiagent-plugin
# Install the plugin
/plugin install grok-swarm@khaentertainment
Then run /grok-swarm:setup inside Claude Code — an OAuth browser flow will
authorize your OpenRouter account without exposing your API key in-context.
clawhub install grok-swarm
git clone https://github.com/KHAEntertainment/grok-multiagent-plugin.git
cd grok-multiagent-plugin
# Auto-detect and install
./install.sh
# Or install for specific platform
./install.sh claude # Claude Code only
./install.sh openclaw # OpenClaw only
./install.sh both # Both platforms
For detailed instructions for each method, see INSTALL.md.
/grok-swarm:analyze Review the security of my auth module
/grok-swarm:refactor Convert these callbacks to async/await
/grok-swarm:code Write a FastAPI endpoint for user registration
/grok-swarm:reason Compare microservices vs monolith for this project
# After ClawHub or git install, add to openclaw.json:
openclaw gateway restart
Then use in your agent:
npx claudepluginhub khaentertainment/grok-multiagent-plugin --plugin grok-swarmPersonal Claude Code + Codex dev stack: security hooks, AI-first code conventions, /security-review, /repo-map, /stack-check, portable statusline. Designed to complement other skills-based plugins, not replace them.
OpenAgentsControl — multi-agent orchestration for Claude Code. Context-aware development with skills, subagents, parallel execution, and automated code review.
Hub plugin for cc-multi-cli-plugin: contains the companion runtime, subagents, setup wizard, and customization skills.
Thoughtbox observability, protocol enforcement, and CLI for Claude Code
Coordinate multiple AI agents working on the same codebase. Prevents merge conflicts before code is written.
Sub-agent runner — runs agent definitions on Codex, Claude Code, Cursor CLI, or Gemini CLI from any host AI tool.