Shared coordination layer for Hermes Agent, Claude Code, and other MCP clients. Powers hermes-brain multi-agent orchestration.
Brain MCP provides 19 tools with mixed quality. Most tools have descriptions (good), but schemas are incomplete or inferred from Python extraction script rather than visible TypeScript definitions. Tool names follow verb_noun convention (brain_*, gate, wake, route, remember, recall, forget, security_scan). However, parameter schemas lack full type definitions in visible source, many show only description strings without explicit 'type' fields. Output schemas are undocumented. Error handling guidance is minimal. The extraction script (extract-tools.py) suggests tools exist but does not show actual MCP registration code, making schema verification impossible. Per-tool scores average 52 due to missing schema visibility and incomplete parameter typing.
Run the integration gate in a loop until all errors are fixed or max retries are hit. After each failed gate, agents are DM'd their specific errors and given time to fix them. Returns the final gate result. Use this after all agents report "done" to ship with confidence.
Check the current status of a barrier — how many agents have checked in and what the threshold is.
Get the current value of an atomic counter without incrementing.
Atomically decrement a numeric counter.
Read a value from shared brain state. Returns null if the key does not exist.
Get the result blob from a completed DAG task. Returns null if the task has not posted a result.
Input schemas not visible in source code. Tool definitions inferred from Python extraction script rather than explicit TypeScript MCP registration. Cannot verify parameter types, constraints, or full schema structure.
Output schemas completely undocumented. No visible return type definitions for any tool. LLMs cannot plan downstream calls or extract required fields (e.g., task_id from brain_set_task_result).
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | D | 53 | 2026-07-28+ | v2 |
Atomically increment a numeric counter in shared state. Thread-safe — use for shared counters, progress tracking, or aggregation across agents.
Post a message to a channel in the brain room. Use channel "general" for team-wide updates, "alerts" for important notifications.
Send a heartbeat to the conductor. Call every few tool invocations to report that you are alive and making progress.
Store a key-value pair in shared brain state. Other agents can read it with brain_get. Values must be JSON-serializable strings.
Attach a result blob to a DAG task. Dependent tasks can retrieve it with brain_get_task_result.
Barrier primitive — atomically increment a counter. When current >= threshold, returns reached:true for all callers simultaneously. Use for "wait for N agents to check in" semantics.
Remove a memory by key. Use when knowledge is outdated or wrong.
Run the integration gate: tsc --noEmit + contract validation. Catches type errors, missing imports, param mismatches between agents. If errors are found, DMs each responsible agent with their specific errors and resets their status to "working". Use this after all agents report "done" to verify integration before shipping.
Search persistent memory for knowledge stored by previous agents or sessions. Always check memory at the start of a task — previous agents may have discovered something relevant.
Store knowledge that persists across sessions. Use this to record discoveries about the codebase, architectural decisions, patterns found, or anything future agents should know. Unlike brain_set (ephemeral shared state), memories survive brain_clear and are searchable.
Get a model recommendation for a task based on historical performance data. Returns the recommended model, confidence score, complexity classification, and reasoning. Use this before brain_wake to auto-select the best model for the job.
Scan modified files for common security vulnerabilities. Checks for: hardcoded credentials, API keys, GitHub tokens, eval/exec injection, pickle deserialization, XSS via innerHTML, GitHub Actions injection vectors (${github.event.* } without sanitization), SQL injection, path traversal, weak crypto, and shell injection. Results include severity, file path, line number, and a remediation suggestion. Use the notify parameter to DM agents responsible for files with findings.
Spawn a NEW agent session to handle a task. Supports multiple modes: tmux (default): visible split pane — requires tmux; headless: background process — no tmux needed, works everywhere. Supports multi-LLM routing via the model parameter (e.g. "haiku" for cheap tasks, "opus" for complex ones). Configurable timeout (default: none for tmux, 30min for headless).
Parameter type definitions incomplete. Many parameters show only descriptions without explicit JSON Schema 'type' field (e.g., 'status' in brain_pulse, 'content' in brain_post). Cannot validate input at parse time.
Error handling guidance absent. No tool documents what errors can occur, whether they are retryable, or what the LLM should do next. E.g., brain_get returns 'null if key does not exist' but no guidance on handling missing state.
wake tool accepts 'model' parameter but no validation or enum constraint. LLM could pass invalid model names. route tool returns 'recommended model' but no schema for response structure (confidence, complexity, reasoning fields).