<!-- Unabyss Brain Audit: append this to ~/.codex/AGENTS.md. -->

# Unabyss Brain Audit

When the person asks to audit, score or check their brain, vault or knowledge base (a
folder of Markdown or text notes), run the Unabyss Brain Audit as below.

## Connect

The audit runs through the Unabyss Brain Audit MCP server at https://audit.unabyss.com/mcp
(streamable HTTP, no sign-in). Connect it once with:

```sh
codex mcp add brain-audit --url https://audit.unabyss.com/mcp
```

or add this to `~/.codex/config.toml`:

```toml
[mcp_servers.brain-audit]
url = "https://audit.unabyss.com/mcp"
```

then start a new Codex session so its tools load.

If its tools (`start_audit`, `confirm_email`, `next_step`, `set_company_type`,
`get_merit_rubric`, `complete_audit`) are not available, tell the person how to connect
it (above), and stop. Do not try to audit the brain any other way.

## What to do

1. Call `next_step` (with no audit token yet). Follow its `instructions` exactly.
2. Ask the person for their real email address. The report link and a 6-digit
   confirmation code are sent there, so a made-up address cannot work. Never guess it or
   use one from files, git config or the environment without asking.
3. Show the person the consent notice the MCP gives, and call `start_audit` with
   `consent: true` only after they accept it.
4. Ask the person for the 6-digit code from the email and call `confirm_email`. Never
   guess the code.
5. From then on: call `next_step` with the audit token, do exactly what its
   `instructions` say, then call `next_step` again. Repeat until it returns the step
   `done`.

## Rules

- Follow the MCP's instructions exactly. Do not improvise, skip, reorder or add steps,
  and do not run any other version of the CLI than the one `next_step` names.
- The report key is the part of the report link after `#k=`. Never print it, paste it,
  log it or send it anywhere: not to the MCP, not to any other tool, not in a URL. The
  CLI shows the full link to the person and saves it on their computer.
- Never send file contents, file names, paths or titles to the MCP.
- Never write inside the brain folder.
- If a step fails, do what the instructions say for that failure; otherwise show the
  person the message and stop.
