Search BrigadeStack

Search BrigadeStack pages and docs.

BrigadeStack
Menu

Verification modes and check records

Choose when agents must record their checks. A check record shows the command, exit code and exact tree another agent tested.

Choose how strict it is.

Switch a repo between modes whenever you like.

StrictDefault

In Claude Code, a changed session needs an eligible check record for its current tree. If the repo declares a required check, the record must meet that policy.

brigadestack work mode set strict

Observe

Blocks nothing. Hooks note the checks agents run, where the tool supports it, and work checks reports them.

brigadestack work mode set observe

Off

Keep the brief, memory and handoffs. Agents run checks raw and finish without a check record.

brigadestack work mode set off

Compare the modes, including the safety rails that stay on in every mode.

A task, start to finish.

Four things an agent does, memory first. Each one is a real command with its real output.

Hand it off

“Write down what you learned before you stop.”

The next session, in any agent tool, can find it.

brigadestack handoff draft --inbox claude --type gotcha --title "Retry test raced the fake clock" ...handoff draft: ~/my-app/.claude/memory-handoffs/20261111-235408-retry-test-raced-the-fake-clock.mdlint: ok
result lint: ok
Writes

The next agent can find it

“Before you touch the retry test, check what we learned about the fake clock.”

A second tool, in its own checkout, searches shared memory and finds a card another tool published. Claude Code can also get matches automatically; other tools run the search.

brigadestack memory search "fake clock" --target ~/my-app-bmemory search: fake clock (1 match(es), hub reports 1)- cards/card-54d4d0fc-b215-4ef1-a1b8-1db01342c148.md  [hub]  card-54d4d0fc-b215-4ef1-a1b8-1db01342c148brigadestack memory hub card card-54d4d0fc-b215-4ef1-a1b8-1db01342c148 ...Register the timer, then advance the fake clock.
result memory search: fake clock (1 match(es), hub reports 1)

Prove it passed

“Run the tests and keep a check record.”

The check record keeps the exit code and the exact tree that was tested.

brigadestack work verify run --command "npm test"work verify run: ~/my-apprun: 20261111-235407-work-verify-48524dstatus: completedcommands: 1- npm test [completed] exit=0receipt: ~/my-app/.brigade/work/verify-runs/20261111-235407-work-verify-48524d/receipt.json
result - npm test [completed] exit=0
Writes

Share MCP servers

“Give Claude Code and Codex the same GitHub server.”

One catalog, written into each tool's own config.

brigadestack mcp add --name github ...brigade mcp: added github to ~/my-app/.brigade/mcp.jsonbrigadestack mcp sync --writeclaude       github               missing        -> createcodex        github               missing        -> createwrote: ~/my-app/.mcp.jsonwrote: ~/my-app/.codex/config.toml
result wrote: ~/my-app/.mcp.json
Writes
Inspect example files

See the check record, handoff and configuration files from the walkthrough.

my-app

  • .brigade gitignored
  • work
  • verify-runs
  • 20261111-235407-work-verify-48524d
  • .claude gitignored
  • memory-handoffs
AGENTS.md first 24 of 76 lines
# AGENTS.md - Working In This Repo

This repo is Brigade-wired. These are the operating rules for any agent working here.

## Every Session

For substantial work, first gather context:

1. Read this file - operating rules and the memory handoff contract.
2. Read the repo's `README` and `CONTRIBUTING` (if present) for build, test, and style expectations.
3. Skim your harness's handoff inbox (`.claude/memory-handoffs/`, `.codex/memory-handoffs/`) for recent notes from other sessions.
4. Read `SAFETY_RULES.md` once. Hard boundaries.

For tiny read-only commands, do the command directly and avoid loading unrelated context. Do not ask permission for normal context gathering.

## Definition of Done

Before you report work as complete:

1. Run the project's checks (tests, linters, type checks, build). If you do not know them, look in `README`, `CONTRIBUTING`, `pyproject.toml` / `package.json`, or the CI config before guessing.
2. Report the actual result. Never claim success you did not observe; paste the command you ran and its output.
3. If a check could not run, say so and name the blocker instead of guessing.
4. If the session produced durable knowledge, confirm a Memory Handoff was written (see below).

The rules every agent tool reads first.

.brigade/work/tasks.json excerpt 39 lines
{
  "edges": [],
  "tasks": [
    {
      "acceptance": [
        "Retry test passes 20 runs in a row"
      ],
      "assignee": "codex",
      "claim": {
        "actor": "codex",
        "claim_id": "claim-900dc7d9900840538c499f06beffce54",
        "claimed_at": "2026-11-11T23:54:07.411722+00:00",
        "item_revision": 1
      },
      "completed_at": "2026-11-11T23:54:08.170926+00:00",
      "created_at": "2026-11-11T23:54:06.906799+00:00",
      "id": "20261111-235406-fix-the-flaky-retry-test-acec68",
      "item_revision": 1,
      "priority": "normal",
      "source": "manual",
      "status": "done",
      "text": "Fix the flaky retry test",
      "type": "bug",
      "updated_at": "2026-11-11T23:54:08.170926+00:00"
    },
    {
      "acceptance": [],
      "created_at": "2026-11-11T23:54:07.070534+00:00",
      "id": "20261111-235407-update-the-install-docs-685b18",
      "priority": "normal",
      "source": "manual",
      "status": "pending",
      "text": "Update the install docs",
      "type": "task",
      "updated_at": "2026-11-11T23:54:07.070534+00:00"
    }
  ],
  "version": 2
}

The shared task list, with claims and acceptance criteria.

.brigade/work/verify-runs/20261111-235407-work-verify-48524d/summary.md 20 lines
# Brigade Work Verification

- Run: `20261111-235407-work-verify-48524d`
- Status: completed
- Target: `~/my-app`
- Started: 2026-11-11T23:54:07.600799+00:00
- Completed: 2026-11-11T23:54:07.910665+00:00

- Baseline commit: `c27cfaabe7a3aeb57c2b5ed86b9e1b797df9f5d8`
- Tree fingerprint: `8a5cafbdd4709a7f6f1031ac0e15bb4b4343a35c`
- Patch hash: `e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855`
- verified tree 8a5cafbdd4709a7f6f1031ac0e15bb4b4343a35c = baseline c27cfaabe7a3aeb57c2b5ed86b9e1b797df9f5d8 + patch e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855

## Commands

- `npm test`: exit=0 status=completed

## Evidence

- Code graph delta: code graph delta: ok changed_symbols=0 edge_churn=0 added_nodes=0 removed_nodes=0 changed_nodes=0 added_edges=0 removed_edges=0

A readable summary of one verification run.

.brigade/work/verify-runs/20261111-235407-work-verify-48524d/receipt.json excerpt 21 lines
{
  "run_id": "20261111-235407-work-verify-48524d",
  "status": "completed",
  "baseline_commit": "c27cfaabe7a3aeb57c2b5ed86b9e1b797df9f5d8",
  "tree_fingerprint": "8a5cafbdd4709a7f6f1031ac0e15bb4b4343a35c",
  "changes_patch_sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
  "started_at": "2026-11-11T23:54:07.600799+00:00",
  "completed_at": "2026-11-11T23:54:07.910665+00:00",
  "commands": [
    {
      "command": "npm test",
      "argv": [
        "npm",
        "test"
      ],
      "exit_code": 0,
      "status": "completed",
      "duration_seconds": 0.156763
    }
  ]
}

The check record: commit, tree fingerprint, command and exit code.

.brigade/mcp.json 24 lines
{
  "servers": {
    "github": {
      "args": [
        "-y",
        "@modelcontextprotocol/server-github"
      ],
      "command": "npx",
      "enabled": true,
      "env": {
        "GITHUB_TOKEN": {
          "ref": "GITHUB_TOKEN"
        }
      },
      "targets": [
        "claude",
        "codex"
      ],
      "timeout": 30,
      "transport": "stdio"
    }
  },
  "version": 1
}

The one MCP catalog you edit.

.mcp.json 15 lines
{
  "mcpServers": {
    "github": {
      "command": "npx",
      "args": [
        "-y",
        "@modelcontextprotocol/server-github"
      ],
      "env": {
        "GITHUB_TOKEN": "${GITHUB_TOKEN}"
      },
      "timeout": 30
    }
  }
}

What sync wrote for Claude Code.

.claude/memory-handoffs/20261111-235408-retry-test-raced-the-fake-clock.md 33 lines
# Memory Handoff

## Type

gotcha

## Title

Retry test raced the fake clock

## Summary

The test advanced the fake clock before the timer was registered, so it failed about one run in ten.

## Durable facts

- Register the timer before advancing the clock.

## Evidence

- verify run receipt, exit 0

## Recommended memory action

no-card

## Target document

.learnings/LEARNINGS.md

## Suggested document content

Register the timer, then advance the fake clock.

A note for the next session, waiting to be reviewed.