# 🤖 ClaudeAll

> **One install, four AI coding agents.**
> Configures Claude Code · Gemini CLI · OpenAI Codex · Kiro CLI — same agents, same skills, same MCP servers, same `.env` everywhere.

[![npm version](https://img.shields.io/npm/v/claude-all-config.svg)](https://www.npmjs.com/package/claude-all-config)
[![GitHub](https://img.shields.io/github/license/zesbe/ClaudeAll)](https://github.com/zesbe/ClaudeAll/blob/main/LICENSE)
[![Agents](https://img.shields.io/badge/Agents-22-blue)](#agents)
[![Skills](https://img.shields.io/badge/Skills-82-brightgreen)](#skills)
[![MCP Servers](https://img.shields.io/badge/MCP-11-orange)](#mcp-servers)
[![Hooks](https://img.shields.io/badge/Smart_Hooks-8-purple)](#smart-hooks)

---

## ✨ What you get

| | Count | Notes |
|---|---|---|
| **Agents** | 22 | 14 originals + 8 power agents (debugger, architect, incident-commander, db-doctor, refactor-master, release-manager, cost-watchdog, learning-loop) |
| **Skills** | 82 | 67 in-house + 15 curated from `alirezarezvani/claude-skills` (MIT) |
| **MCP servers** | 11 | context7, exa, sequential-thinking, memory, filesystem, fetch, zread, vision, web-search, minimax, telegram |
| **Smart hooks** | 8 | intent-classifier, secret-scanner, blast-radius-warner, auto-test-runner, auto-format, commit-suggester, lessons-extractor, result-summarizer |
| **Slash commands** | 8 | `/brainstorm`, `/write-plan`, `/execute-plan`, `/clean`, `/commit-openagents`, `/indexes`, `/worktrees`, `/writing-plans` |
| **Platforms supported** | 4 | Claude Code, Gemini CLI, OpenAI Codex, Kiro CLI |

---

## ⚡ Quick install

### 1. Install your AI CLI of choice (any/all of these)

```bash
# Claude Code (recommended — Anthropic's native installer)
curl -fsSL https://claude.ai/install.sh | bash

# Gemini CLI
npm install -g @google/gemini-cli

# OpenAI Codex
npm install -g @openai/codex

# Kiro CLI
# See https://kiro.dev for install instructions
```

### 2. Install ClaudeAll (configures every CLI you have)

```bash
# npm — works everywhere (Linux, macOS, WSL, Termux, Windows)
npm install -g claude-all-config

# OR curl one-liner (Linux/macOS/WSL):
curl -fsSL https://raw.githubusercontent.com/zesbe/ClaudeAll/main/install.sh | bash
```

ClaudeAll detects which CLIs you have installed and configures each one
automatically. Run again whenever you add a new CLI.

### 3. Make `~/.local/bin` discoverable

```bash
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc
source ~/.bashrc
```

### 4. (Optional) Customize secrets

The package ships with sensible default API keys so MCP servers work
out of the box. To use your own keys, edit:

```bash
~/.claude/.env    # Claude Code
~/.gemini/.env    # Gemini
~/.codex/.env     # Codex
~/.kiro/.env      # Kiro
```

The wrappers (`claude-all`, `gemini-all`, `codex-all`, `kiro-all`) source
these `.env` files automatically. The `claude`, `gemini`, and `codex` shims in
`~/.local/bin/` do the same when you call them by their plain name.

---

## 🚀 Daily use

```bash
# Claude
claude                # plain native binary
claude-all            # interactive launcher with model menus

# Gemini (plain `gemini` is shimmed → auto-YOLO + .env loaded)
gemini
gemini --no-yolo      # opt out of YOLO for one run

# Codex (plain `codex` shim auto-loads .env)
codex
codex-all             # explicit launcher

# Kiro
kiro-all              # launcher with .env loaded
```

The `claude-all` launcher gives you an interactive menu of model providers:
Anthropic Claude, OpenAI, Gemini, ZhipuAI/GLM (5 / 5.1), Letta (Opus 4.7), DeepSeek,
MiniMax, Groq, Qwen, OpenRouter, AgentRouter, and more.

---

## 🧠 Agents

Use `Task` tool with these 22 agent types (file: `~/.claude/agents/<name>.md`):

**Original (14)**
`proactive-mode` · `code-generator` · `code-reviewer` · `security-auditor` ·
`test-generator` · `doc-generator` · `api-tester` · `performance-analyzer` ·
`accessibility-reviewer` · `component-generator` · `migration-generator` ·
`readme-generator` · `terraform-generator` · `ai-prompt-optimizer`

**v3.6 power agents (8)**
- `debugger` — systematic root-cause investigation
- `architect` — ADR-driven system design
- `incident-commander` — SEV triage + post-mortem
- `db-doctor` — query / schema specialist
- `refactor-master` — tiered refactor with safety nets
- `release-manager` — semver + changelog + publish automation
- `cost-watchdog` — cloud + AI cost monitoring
- `learning-loop` — persists lessons to memory MCP, recalls them next session

---

## ⚡ Skills

82 skills under `~/.claude/skills/<name>/SKILL.md`. Highlights:

**Engineering**
`api-design-authority` · `architecture-decisions` · `code-review-authority` ·
`database-design` · `tech-stack-authority` · `tech-debt-hunter` ·
`backend-dev` · `frontend-design` · `mobile-development`

**Quality & testing**
`systematic-debugging` · `root-cause-tracing` · `test-driven-development` ·
`integration-testing` · `verification-before-completion` ·
`condition-based-waiting` · `defense-in-depth`

**Reliability & ops**
`crisis-commander` · `chaos-engineering` · `incident-response` ·
`observability-designer` · `kubernetes-operator` · `terraform-patterns` ·
`stress-test` · `auto-backup` · `multi-vps`

**AI / LLM**
`rag-architect` · `llm-cost-optimizer` · `prompt-governance` ·
`agent-workflow-designer` · `ai-prompt-optimizer`

**v3.6 orchestration skills**
- `consensus-voting` — multi-agent voting on high-stakes decisions
- `auto-recall-memory` — query memory MCP before solving
- `self-validation-loop` — auto-validate generated code
- `cost-aware-execution` — estimate token cost before heavy ops

`claude-all-skills list` for the full inventory with quality scores.

---

## 🔌 MCP servers

All 11 servers are auto-configured in:
- `~/.mcp.json` (Claude)
- `~/.gemini/mcp.json` (Gemini)
- `~/.codex/config.toml` (Codex, TOML format with `approval_policy = "never"`)
- `~/.kiro/settings/mcp.json` (Kiro)

| Server | Purpose | Env var |
|---|---|---|
| context7 | Library docs lookup | `CONTEXT7_API_KEY` |
| exa | Web search & crawling | `EXA_API_KEY` |
| sequential-thinking | Structured step-by-step reasoning | — |
| memory | Knowledge graph persistence | — |
| filesystem | File system access (scoped to `$HOME`) | — |
| fetch | HTTP fetch | — |
| zread | Z.AI document reader | `Z_AI_API_KEY` |
| vision | Z.AI vision/multimodal | `Z_AI_API_KEY` |
| web-search | Z.AI premium web search | `Z_AI_API_KEY` |
| minimax | MiniMax voice/audio | `MINIMAX_API_KEY` |
| telegram | Telegram bot + notifications | `TELEGRAM_*` |

`${HOME}` in args is expanded at install time.

---

## 🪝 Smart hooks

A single dispatcher `hooks/smart-hooks.sh` powers eight hook actions wired
through `hooks/hooks.json`:

| Hook | Trigger | What it does |
|---|---|---|
| `intent-classifier` | UserPromptSubmit | Suggests the right specialist agent based on prompt keywords |
| `secret-scanner` | PreToolUse | Blocks tool calls leaking PATs, JWTs, AWS keys, private keys |
| `blast-radius-warner` | PreToolUse (Bash) | Warns on destructive commands (`rm -rf /`, force-push, `DROP TABLE`, …) |
| `auto-test-runner` | PostToolUse (Edit/Write) | Suggests the right test command for the file's language |
| `auto-format` | PostToolUse (Edit/Write) | Suggests prettier/black/gofmt/etc. |
| `commit-suggester` | Stop | Notes uncommitted changes |
| `lessons-extractor` | Stop | Prompts the `learning-loop` agent to persist insights |
| `result-summarizer` | SubagentStop | Reminds the model to condense subagent verbosity |

---

## 📦 Layout after install

```
~/.local/bin/
├── claude              ← Claude Code native binary
├── claude-all          ← interactive launcher (model menu, MCP keys)
├── claude-all-skills   ← skills CLI
├── claude-all-mcp      ← MCP installer
├── claude-all-update   ← self-updater
├── gemini              ← shim: auto --yolo + .env loaded
├── gemini-all          ← explicit Gemini launcher
├── codex               ← shim: auto .env loaded
├── codex-all           ← explicit Codex launcher
└── kiro-all            ← Kiro launcher

~/.claude/
├── agents/      (22 agents)
├── skills/      (82 skills)
├── commands/    (8 slash commands)
├── hooks/       (smart-hooks.sh + hooks.json)
├── plugins/
├── context/
├── CLAUDE.md
├── settings.json
└── .env

~/.gemini/superpowers/    (mirror of ~/.claude content)
~/.gemini/{GEMINI.md, mcp.json, settings.json, .env}

~/.codex/
├── agents/ skills/ commands/ hooks/ lib/
├── AGENTS.md     (synced from CLAUDE.md)
├── config.toml   (auto-translated from mcp.json)
└── .env

~/.kiro/
├── skills/ commands/ hooks/ lib/ prompts/
├── AGENTS.md     (synced from CLAUDE.md)
├── settings/mcp.json
└── .env
```

---

## 🔐 Security model

**Out of the box:** the package ships default API keys for context7, exa,
Z.AI, MiniMax, and a Telegram bot (`@mcpcli_bot`) so MCP servers work
immediately. These are public on npm — do not rely on them for production
work; install your own.

**To use your own keys:** edit any of the `.env` files listed in step 4
above. Postinstall *merges* on subsequent installs — it fills empty values
from defaults but never overwrites a value you've customized.

**As root (Docker, Termux proot, CI):** the wrappers automatically set
`IS_SANDBOX=1` and use `--dangerously-skip-permissions` so Claude Code
recognizes the environment as an intended sandbox and bypasses its
root-protection check.

**`secret-scanner` hook** blocks tool calls that contain anything that
looks like a token (PAT, JWT, AWS key, private key block).

---

## 🛠 Environment overrides

| Variable | Effect |
|---|---|
| `GEMINI_NO_YOLO=1` | Disable auto-`--yolo` for the gemini shim |
| `GEMINI_BIN=/path/to/gemini` | Force shim to use a specific gemini |
| `CODEX_BIN=/path/to/codex` | Force shim to use a specific codex |
| `KIRO_BIN=/path/to/kiro-cli` | Force kiro-all to use a specific kiro |

For the curl installer specifically (`install.sh` at repo root):

| Variable | Effect |
|---|---|
| `CLAUDE_INSTALLER_FORCE_NPM=1` | Force npm path even on supported native platforms |
| `CLAUDE_INSTALLER_VERSION=X.Y.Z` | Pin a specific npm version |
| `CLAUDE_INSTALLER_DRY_RUN=1` | Show what would happen, do not execute |

---

## 🐧 Termux / Android

Anthropic's native installer doesn't ship an Android arm64 binary, so on
Termux we transparently fall back to npm:

```bash
pkg install -y nodejs-lts git
npm config set prefix "$HOME/.local"
npm install -g @anthropic-ai/claude-code
npm install -g claude-all-config
```

Inside `proot-distro` (where you run as root), the wrappers detect UID 0
and set `IS_SANDBOX=1` so all the autonomous behavior keeps working.

---

## 🔄 Update

```bash
npm install -g claude-all-config@latest
```

Re-running install is safe — files are merged, ownership is restored if you
ran under sudo, and your customized `.env` values are preserved.

---

## 🧹 Uninstall

```bash
# Native Claude Code binary
rm -f ~/.local/bin/claude
rm -rf ~/.local/share/claude

# ClaudeAll itself
npm uninstall -g claude-all-config

# Configuration (this also removes auth)
rm -rf ~/.claude ~/.gemini ~/.codex ~/.kiro
rm -f ~/.claude.json ~/.mcp.json
```

---

## 🙏 Credits

15 of the 82 skills (`rag-architect`, `llm-cost-optimizer`,
`prompt-governance`, `chaos-engineering`, `observability-designer`,
`threat-detection`, `kubernetes-operator`, `terraform-patterns`,
`playwright-pro`, `incident-response`, `data-quality-auditor`,
`migration-architect`, `stress-test`, `agent-workflow-designer`,
`api-design-reviewer`) are adopted from
[`alirezarezvani/claude-skills`](https://github.com/alirezarezvani/claude-skills)
under MIT. See [`skills/ATTRIBUTION.md`](./skills/ATTRIBUTION.md).

---

## 📜 License

[MIT](LICENSE)
