Skip to content

Tutorial 02 — Your first capsule via the bridge

In tutorial 01 you ran the framework programmatically. The primary mode for day-to-day use is different: you (humano) ask Claude in VS Code to do work; Claude records progress through the bridge; the dashboard shows it live.

This tutorial walks you through that flow end-to-end.

Prerequisites

  • Completed Tutorial 01.
  • VS Code with the Claude extension installed (no Anthropic API key required — the model is the Claude you're already talking to).

Step 1 — Start the dashboard

In a terminal in the repo:

make dashboard-real

You should see uvicorn boot on http://localhost:8000. Open it in your browser. A connection banner flashes green for 1.5s when the WebSocket connects.

Step 2 — Register a capsule

Now imagine Claude is about to work on a feature. Claude would call this from a Bash tool block, but you can run it yourself to see how it works:

python -m src.bridge.cli start \
    --intent build_feature \
    --specialist frontend-specialist \
    --description "Implementar componente de login com email e password"

Output:

{"ok": true, "capsule": {"capsule_id": "cap_abc123", ...}}

Switch to the dashboard tab. Within ~1 second you should see:

  • currentStory field in the Project tab now shows cap_abc123 · Implementar…
  • Vitals heart rate ticked up from 60 → 62 BPM (active capsule load)
  • An event arrived: capsule.received

Step 3 — Advance phases as Claude works

Imagine Claude wrote some code. Claude would advance the phase:

CAP_ID=cap_abc123    # use the id from step 2

python -m src.bridge.cli advance --capsule $CAP_ID --phase planning
python -m src.bridge.cli advance --capsule $CAP_ID --phase execution

The dashboard's storyProgress now shows 0.67 (4/6 phases done).

Step 4 — Record artifacts

Each file Claude touches gets recorded:

python -m src.bridge.cli artifact --capsule $CAP_ID --path src/Login.tsx
python -m src.bridge.cli artifact --capsule $CAP_ID --path src/Login.test.tsx

artifact_count on the capsule increments. The procedural memory store also gets entries (visible in _framework/memory/procedural/procedural.jsonl).

Step 5 — Nudge hormones at meaningful moments

If tests pass:

python -m src.bridge.cli hormone --name dopamine --magnitude 0.3

The dopamine bar on the dashboard fills toward 0.5+ (active threshold).

If tests fail, raise cortisol instead:

python -m src.bridge.cli hormone --name cortisol --magnitude 0.2

The vitals heart rate jumps further — the framework is "stressed."

Step 6 — Complete the capsule

python -m src.bridge.cli complete --capsule $CAP_ID --status success \
    --summary "Login component shipped with 8/8 tests passing"

Dashboard reactions: - currentStory clears (no active capsule) - storyProgress resets to 0.0 - An episodic memory record is written (feed for MirrorLearner) - Final audit chain entry signed with HMAC

What you just observed

You drove a capsule from creation to completion. The framework recorded every state change, computed derived metrics (load, cost-proxy, error rate), and the dashboard rendered the whole arc live.

This is the default operating mode for mult-agentes when used in VS Code.

What's next