Skip to main content
Glama

Brain doctor — is this brain current, wired, and in sync?

brain_doctor

Runs a read-only self-check of the installed klypix brain, returning one verdict on version, hooks, MCP tools, active sessions, and config drift.

Instructions

Read-only self-check of the installed klypix brain, as ONE verdict: VERSION (deployed brain-core + optional npm currency), CLAUDE (existing 5-hook capture readiness), CODEX (automatic MCP presence plus optional enhanced-hook status), TOOLS (discoverable MCP verbs), SESSIONS (all active presence-adapter sessions across hosts, never recent-chat history), and HARNESS (projection drift). Use to answer "is my brain current, correctly installed, in sync, and who is actually live?" without file-spelunking. Never writes: the only side effects are read-only subprocess queries (git rev-parse / tag --list / log / merge-base with fixed argument arrays, and npm view only when check_npm is true) — it creates, edits, and deletes nothing. SCOPE: only CLAUDE and CODEX get behavioural verdicts. HARNESS classifies the projected config/rules FILES on disk — a project can read fully ok while no other host has ever actually loaded them, so do not report a clean HARNESS as "Cursor/Cline/Windsurf/Copilot is working". The MCP-callable twin of npx klypix-mcp doctor. Besides the text, the result carries structuredContent {verdict, layers, version, autoUpdate, supervisors, readinessWarnings, actions}: the same verdict as data, including when the next automatic update check runs and what it will do.

Input Schema

NameRequiredDescriptionDefault
projectNoProject dir to audit harness + peers for. Defaults to the server's working directory.
check_npmNoAlso fetch npm latest to flag a stale brain (default false — this one does a network `npm view`).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries the full burden and does so: it declares read-only, lists the exact side effects (git rev-parse/tag/log/merge-base with fixed argument arrays, and `npm view` only when check_npm is true), and states it creates, edits, and deletes nothing. It also discloses the structuredContent return shape, which is above the bar for a no-annotation tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loads the verdict-scope sentence before constraints, and every sentence is substantive. It is a dense single paragraph that could be broken up, but there is little filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a diagnostic tool with no output schema, the description usefully enumerates the returned fields (verdict, layers, version, autoUpdate, supervisors, readinessWarnings, actions) and the layer semantics. Given the large sibling set, a bit more explicit routing versus brain_sync/brain_reconcile would make it fully complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% and both parameters are fully documented there (project default, check_npm's network behavior). The description only repeats the check_npm/network point already in the schema, so it adds little new parameter meaning beyond the baseline.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource (read-only self-check of the installed klypix brain) and enumerates the exact verdict layers (VERSION, CLAUDE, CODEX, TOOLS, SESSIONS, HARNESS). It is easily distinguished from siblings like brain_sync, brain_reconcile, or brain_insights, and it names its CLI twin.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives a clear triggering question ('is my brain current, correctly installed, in sync, and who is actually live?') and an exclusion ('never recent-chat history'), plus a scope warning not to over-read a clean HARNESS as other hosts working. It does not explicitly contrast against the other brain_* siblings, keeping it short of a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.