Everything Merlin does.
Every agent, command, hook, and tool — what it does, why it matters, and how to use it.
Specialist Agents
34 agents. Every task, a specialist.
Core Pipeline
Your ideas become buildable specs with requirements, user flows, and edge cases — in minutes, not days.
/merlin:route product-spec "task"Designs clean architecture that prevents the spaghetti code AI usually creates. Checks for conflicts before building.
/merlin:route system-architect "task"Writes production code that matches YOUR patterns, not generic boilerplate. Reuses existing utilities instead of creating duplicates.
/merlin:route implementation-dev "task"Finds the code duplication you missed. Consolidates utilities. Enforces the 400-line file limit that keeps code maintainable.
/merlin:route dry-refactor "task"The layer between "it works" and "it's production-ready." Adds validation, error handling, auth checks, and input sanitization.
/merlin:route hardening-guard "task"Writes tests that actually matter — critical paths, edge cases, regression prevention. Not just coverage for coverage's sake.
/merlin:route tests-qa "task"Handles deployment configs, environment variables, and build pipelines so you never debug a deploy again.
/merlin:route ops-railway "task"Documentation that stays current because it's generated from the code, not maintained separately.
/merlin:route docs-keeper "task"Specialists
Component architecture and design systems that scale. Not just pixels — structure.
/merlin:route ui-designer "task"Frontend implementation that's responsive, accessible, and follows your component patterns.
/merlin:route ui-builder "task"60fps animations that feel right. Transitions, micro-interactions, scroll effects.
/merlin:route animation-expert "task"Swift 6, SwiftUI, AppKit. Full iOS/macOS lifecycle — from architecture to App Store submission.
/merlin:route apple-swift-expert "task"Kotlin, Jetpack Compose, Material Design 3. Full Android lifecycle.
/merlin:route android-expert "task"Electron, Tauri, cross-platform distribution. IPC security included.
/merlin:route desktop-app-expert "task"Scientific-method debugging with persistent state across context resets. Manages checkpoints so no context is lost.
/merlin:debugFinds the bottleneck, not just the slow code. Profiling with benchmarking guidance.
/merlin:route merlin-performance "task"Deep security audits with OWASP awareness. Thinks like an attacker so your app doesn't get treated like one.
/merlin:route merlin-security "task"Code review that catches architectural issues, not just style nits.
/merlin:route merlin-reviewer "task"React, Vue, modern web. State management, accessibility, performance — all applied together.
/merlin:route merlin-frontend "task"Clean REST and GraphQL APIs with versioning, error handling, and documentation baked in.
/merlin:route merlin-api-designer "task"Database migrations that won't take your app down. Rollback strategies. Zero-downtime.
/merlin:route merlin-migrator "task"Creates execution plans with dependency graphs and wave-based parallelization. Spawns a fresh planning context.
Auto-spawned by /merlin:plan-phaseExecutes plans with atomic commits and deviation handling. Stops if something goes wrong.
Auto-spawned by /merlin:execute-phaseVerifies that what was built actually delivers what was promised. Goal-backward analysis.
Auto-spawned by /merlin:verify-workDeep research with source verification before you make architecture decisions. Know before you build.
/merlin:research-phaseTransforms code into production-grade quality. Memory leak detection, race conditions, line-by-line review.
/merlin:route elite-code-refactorer "task"Monitors file sizes, enforces folder structure. Catches files before they become unmaintainable.
/merlin:route code-organization-supervisor "task"Scans the codebase before you write new code to prevent duplicating existing functionality.
Auto-invoked before new featuresCreates programmatic videos using React. Compositions, animations, rendering, deployment.
/merlin:route remotion "task"Catches injection flaws, XSS, SSRF before they reach production. Static analysis with context.
/merlin:route merlin-sast-reviewer "task"Finds CVEs in your dependencies, supply chain risks, and license compliance issues.
/merlin:route merlin-dependency-auditor "task"Detects hardcoded credentials and API keys before they get committed. Pre-commit protection.
/merlin:route merlin-secret-scanner "task"Reviews auth flows, CSRF protection, rate limiting. The stuff that gets breached.
/merlin:route merlin-access-control-reviewer "task"Ensures every endpoint validates its inputs. No unvalidated data ever reaches your business logic.
/merlin:route merlin-input-validator "task"Slash Commands
43 commands. Every workflow, covered.
Project Setup
Deep context gathering that creates a PROJECT.md your AI actually understands. No more re-explaining your app every session.
ManualTurns requirements into phased roadmaps with dependencies and execution waves. Structured delivery, not chaos.
ManualDefines what "done" looks like with checkable requirements. Prevents scope creep before it starts.
ManualStart a new milestone cycle with an updated PROJECT.md. Clean slate, preserved history.
ManualParallel mapper agents analyze your codebase and write structured documents to .planning/codebase/. Full knowledge, instantly.
ManualPlanning
Creates PLAN.md files with dependency graphs and wave parallelization. Spawns a fresh planner with 200K context.
ManualAdaptive questioning before planning. Surfaces unknowns before they become blockers.
ManualGathers context for the next milestone through conversation. Aligns before committing.
ManualResearch how to implement a phase before committing to a plan. Saves expensive mistakes.
ManualResearch the domain ecosystem before creating a roadmap. Know the landscape before building in it.
ManualSurfaces Claude's assumptions about a phase so you can correct them before planning starts.
ManualValidates planning is complete before implementation begins. Catches gaps that would stall execution.
ManualAdd a new phase to the end of the current milestone without disrupting existing numbering.
ManualInsert urgent work as a decimal phase (e.g., 72.1) between existing phases without renumbering everything.
ManualRemove a future phase and automatically renumber all subsequent phases.
ManualExecution
Executes all plans in a phase with wave-based parallelization. Multiple agents run in parallel, each in a fresh 200K context.
ManualExecute a single PLAN.md file step by step with full atomic commit tracking.
ManualRoute any task to the right specialist agent with a fresh 200K context window. The most-used command in Merlin.
ManualRun an ad-hoc task with Merlin guarantees but no ceremony. No plan files, no phase tracking. Just execute.
ManualRun predefined multi-agent pipelines: feature-dev, bug-fix, security-audit, refactor. End-to-end, structured.
ManualVerification
Validates built features through conversational UAT with persistent state. Cold reviewer confirms delivery.
ManualAudits milestone completion against original intent. Did you actually deliver what was promised?
ManualArchives the completed milestone and prepares PROJECT.md for the next version. Clean transition.
ManualCreates phases to close all gaps identified by the milestone audit. Nothing left behind.
ManualNavigation
Smart navigator — detects project state and recommends the single best next action. Never wonder "what now?"
ManualCheck project progress, show current context, and route to the next action.
ManualGenerate daily standup summary — done, in progress, blocked. Copy-paste ready for Slack.
Manual10-point planning integrity check. --repair auto-fixes common issues before they stop execution.
ManualList all pending todos and select one to work on. Keeps tasks from disappearing into context.
ManualCapture an idea or task as a todo from the current conversation context. Nothing gets lost.
ManualSession Management
Resume work from a previous session with full context restoration. Pick up exactly where you left off.
ManualCreate a structured context handoff when pausing work mid-phase. Future sessions start informed, not blank.
ManualHandle plan pivots — when implementation reveals the plan needs changing. Structured deviation, not chaos.
ManualSystematic debugging with persistent state across context resets. Scientific method applied to every bug.
ManualAdvanced
Snapshot and switch between agent/hook/rule configurations. Dev profile, review profile, release profile.
ManualIsolated Docker execution for agents. Build, run, shell, status — resource-limited and clean.
ManualPromote a high-confidence learned behavior into a permanent reusable skill. Merlin learns what works.
ManualAnalyze agent prompt effectiveness with RL-inspired scoring. Surface which prompts deliver results.
ManualSession cost report — per-agent breakdown, token counts, savings vs all-Opus baseline. Know your spend.
ManualUpdate Merlin to the latest version with changelog display. Stay current with one command.
ManualSee exactly what changed since your installed version. No guessing what's different.
ManualShow available Merlin commands and usage guide. Always available, always accurate.
ManualPre-built /loop patterns for common Merlin workflows. Copy-paste ready automation.
ManualAutomated Hooks
They run without you. That's the point.
Scans every file write, edit, and bash command for prompt injection patterns, hardcoded secrets, and data exfiltration. 21 injection patterns checked.
Before Write/Edit/BashAuto-approves 45+ safe commands (git status, npm test, ls) and blocks dangerous ones (rm -rf, curl to external). No permission fatigue.
Before BashEnforces the 400-line file limit. Stops files from becoming unmaintainable before it happens — not after.
Before Write/EditChecks Sights for context before every file modification. Your AI always knows what it's editing, not just what you told it.
Before EditPre-warms Sights context at session start. Your AI has full codebase knowledge from the first prompt, not after you explain the project.
Session startGenerates a structured session summary, classifies outcomes, and appends to the learning engine. Every session makes Merlin smarter.
Session endSyncs architectural decisions to Sights API asynchronously. Future sessions start with your decisions already in context.
Session end (async)Desktop notification when agents complete. macOS and Linux. Never miss a result while you context-switch.
Agent completionSlack and Discord webhook notifications on agent completion. Fire-and-forget delivery to your team.
Agent completionPropagates .merlin-session/ state to isolated worktrees. Agents in worktrees get full context — not a blank slate.
Worktree createdLogs lifetime analytics and cleans up .merlin-session/ state when a worktree is removed. No orphaned state.
Worktree removedAPI key validation and audit trail to config-changes.log on every configuration modification. Catches misconfigurations before they cause silent failures.
Config modifiedDetects when a teammate agent has been idle for 2+ minutes. Creates alert files for the Lead so parallel work stays unblocked.
Agent idle > 2minHook Templates
10 opt-in automations. Enable what fits your workflow.
Auto-formats code on every save. Prettier and ESLint integration. Consistent style without thinking about it.
Enable in configRuns affected tests after every code change. Catches regressions immediately, not at PR review.
Enable in configAuto-commits after successful changes with descriptive messages. Keeps history clean and granular.
Enable in configPrevents direct commits to main/master. Forces the branch workflow that protects production.
Enable in configWarns when cyclomatic complexity exceeds thresholds. Keeps code simple enough to understand and test.
Enable in configPrompts for changelog entries on significant changes. Significant features never go undocumented again.
Enable in configValidates imports match project conventions. Catches wrong import paths before the build does.
Enable in configEnsures license headers appear on new files. Compliance automation that costs you nothing.
Enable in configTracks TODO comments and surfaces them as actionable tasks. Nothing promising gets lost in the codebase.
Enable in configAuto-generates PR descriptions from commit history. Better pull requests with zero extra effort.
Enable in configMCP Tools
12 tools the AI calls automatically — you never invoke these directly.
Gives your AI instant understanding of how any part of your codebase works — conventions, patterns, anti-patterns. Called before every file edit.
Before every file editSemantic search across your codebase. Find code by meaning, not by filename or exact string match.
When AI needs to find codeFinds relevant files for a given task. Faster than grep, smarter than glob — context-aware file discovery.
During task analysisRoutes tasks to specialist agents with effort-level optimization. High-effort tasks get more compute; quick tasks run lean.
Called by orchestratorTracks per-agent cost, token counts, and savings vs all-Opus baseline. Know exactly what you're spending on every task.
On demandRL-inspired prompt effectiveness scoring. Surfaces which agent prompts produce the best results over time.
During optimizationPromotes learned behaviors into permanent skills using Jaccard keyword clustering. Merlin learns from every session.
During skill evolutionLists behaviors ready for promotion based on confidence scores. Shows you what Merlin has learned and is ready to formalize.
During optimizationRestores context from previous sessions. Structured summaries, not raw transcripts — fast and accurate.
Session startKeyword search across all session history. Find what was decided, discussed, or built in any past session.
When searching historyShows what breaks before you edit. Every dependent file surfaced instantly — before the change, not after.
Before risky editsFinds code similar to what you're about to write. Prevents duplication before it happens.
Before new codeMulti-Agent Workflows
4 end-to-end pipelines. Entire feature lifecycle in one command.
7-step pipeline: spec → architecture → implement → harden → test → verify → PR. Each step runs in a fresh 200K context. A cold reviewer verifies at the end.
/merlin:workflow run feature-dev "description"6-step pipeline: triage → investigate → fix → regression test → verify → PR. Finds root cause, not just symptoms.
/merlin:workflow run bug-fix "description"5-step pipeline: scan → prioritize → fix → independent review → security tests. OWASP-aware at every step.
/merlin:workflow run security-audit5-step pipeline: analyze → plan → apply → verify behavior preservation → test. Safe, verified refactoring with no surprises.
/merlin:workflow run refactor "scope"Runtime Support
Works where you work. Every major AI coding environment.
Full integration. All 34 agents, 43 commands, 20 hooks, Loop, everything included.
Primary runtimeFull integration. Same agents, hooks, and commands via MCP. Configured automatically.
Configured automaticallyFull integration. Same complete system. Drop-in installation.
Configured automaticallyFull integration. Same agents and tools via MCP server.
Configured automaticallyMCP context integration. Sights queries and pattern enforcement for every edit.
Via MCP serverMCP integration. Full codebase knowledge layer available in every session.
Via MCP serverIf it speaks MCP, Merlin works. The protocol is the integration layer.
Via MCP serverOne install. All of this.
npx create-merlin-brainWorks with Claude Code, Codex CLI, OpenCode, Gemini CLI