Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Introduction

The Problem

You have side projects. Maybe 3, maybe 10. You work on them in bursts — a flurry of commits, then months of silence.

When you return, the question is always the same:

“Wait, what was I working on? Where did I leave off?”

You scroll through git history. You grep for “TODO”. You search your notes. By the time you remember, you’ve already lost 20 minutes.

The Solution

Cerebro watches your development activity and builds a personal mission control dashboard. It aggregates:

  1. OpenCode sessions — Your AI pair-programming history
  2. Git activity — Commits, branches, file changes
  3. TODOs — TODO, FIXME, HACK, XXX comments in your code
  4. Manual notes — Your status, next actions, goals

When you return to a dormant project, your dashboard answers the question in seconds.

How It Works

Cerebro uses a two-repo architecture:

flowchart LR
    subgraph "Sources"
        G[Git repos]
        O[OpenCode sessions.db]
    end

    subgraph "cerebro (CLI)"
        C[cerebro build]
    end

    subgraph "cortex (your data directory)"
        CT[content/ generated md]
        NB[content/notes/ manual]
        BK[book/ rendered HTML]
    end

    subgraph "cerebro-mcp"
        MS[MCP server]
    end

    subgraph "Consumers"
        MDB[mdbook]
        OC[OpenCode]
    end

    G -->|scrape| C
    O -->|scrape| C
    C -->|writes| CT
    NB -. manual .-> CT
    CT -->|mdbook| BK
    NB -->|mdbook| BK
    MS -->|reads| CT
    MS -->|reads| NB
    OC <-->|JSON-RPC| MS

The Two Repos

RepoPurpose
~/Projects/cerebroSource code — CLI, MCP, TUI, shared types
~/Projects/<name>Your cortex — config, generated content, manual notes, rendered HTML

The Three Binaries

BinaryPurposeUsed by
cerebroCLI: scrape repos, generate markdownYou, cron
cerebro-mcpMCP server: answer questions about projectsOpenCode
cerebro-tuiTerminal UI: browse projects interactivelyYou (feature branch)

Content Boundaries

Your cortex’s content/ has a clear split:

PathGenerated byEdit?
content/index.mdcerebroNo
content/projects/*.mdcerebroNo
content/journal/cerebroNo
content/today.mdcerebroNo
content/this-week.mdcerebroNo
content/intent/HumanYes
content/notes/HumanYes
content/SUMMARY.mdHumanYes

The boundary is enforced by an AGENTS.md file in your cortex — AI agents are instructed not to edit manual content.

Why It Works

Cerebro succeeds when it reduces context-switching friction. You’ll notice it when:

  • You return to a project you haven’t touched in weeks
  • You have too many projects to track mentally
  • You use AI assistants and want to remember what you worked on

Key Concepts

TermMeaning
CollectorA source of data (git, opencode, todos, notes)
GeneratorCreates output files from collected data
ProjectA repo + notes + activity you’re tracking
DashboardThe generated markdown output

Architecture

Cerebro is a Rust workspace with three crates (four on the TUI branch):

  • cerebro — CLI tool and collectors
  • cerebro-core — Shared types and storage traits
  • cerebro-mcp — MCP server for OpenCode integration
  • cerebro-tui — Terminal UI for browsing projects (feature branch)

Next Steps

  1. Quick Start — Get running in 5 minutes
  2. Dashboard Guide — Understand the output
  3. Configuration — Customize for your projects