Thoughtbox
Multi-agent collaborative reasoning that's auditable. Thoughtbox is a Docker-based MCP server where AI agents coordinate through shared workspaces — claiming problems, proposing solutions, reviewing each other's work, and reaching consensus. Every step is recorded as a structured thought in a persistent reasoning ledger that can be visualized, exported, and analyzed.
Local-First: Runs entirely on your machine. All data stays at ~/.thoughtbox/ — nothing leaves your network.
Observatory UI showing a reasoning session with 14 thoughts and a branch exploration (purple nodes 13-14) forking from thought 5.
Code Mode
Thoughtbox exposes exactly two MCP tools using the Code Mode pattern:
thoughtbox_search — Write JavaScript to query the operation/prompt/resource catalog. The LLM has full programmatic filtering power over the catalog.
thoughtbox_execute — Write JavaScript using the tb SDK to chain operations. Access thoughts, sessions, knowledge, notebooks, hub, observability, and protocol tools through a unified namespace.
Workflow: search to discover available operations, then execute code against them. Use console.log() for debugging — output is captured in response logs.
This replaces per-operation tool registration with a two-tool surface that scales without context window bloat.
Multi-Agent Collaboration
The Hub is the coordination layer. Agents register with role-specific profiles, join shared workspaces, and work through a structured problem-solving workflow — all via thoughtbox_execute.
The workflow: register → create workspace → create problem → claim → work → propose solution → peer review → merge → consensus
Workspace primitives:
- Problem — A unit of work with dependencies, sub-problems, and status tracking (open → in-progress → resolved → closed)
- Proposal — A proposed solution with a source branch reference and review workflow
- Consensus — A decision marker tied to a thought reference for traceability
- Channel — A message stream scoped to a problem for discussion
Agent Profiles: MANAGER, ARCHITECT, DEBUGGER, SECURITY, RESEARCHER, REVIEWER — each provides domain-specific mental models and behavioral priming.
28 operations across identity, workspace management, problems, proposals, consensus, channels, and status reporting.
Auditable Reasoning
Every thought is a node in a graph — numbered, timestamped, linked to its predecessors, and persisted across sessions. This creates an auditable trail of how conclusions were reached.
Agents can think forward, plan backward, branch into parallel explorations, revise earlier conclusions, and request autonomous critique via MCP sampling. Each pattern is a first-class operation:
| Pattern | Description | Use Case |
|---|
| Forward | Sequential 1→2→3→N progression | Exploration, discovery, open-ended analysis |
| Backward | Start at goal (N), work back to start (1) | Planning, system design, working from known goals |
| Branching | Fork into parallel explorations (A, B, C...) | Comparing alternatives, A/B scenarios |
| Revision | Update earlier thoughts with new information | Error correction, refined understanding |
| Critique | Autonomous LLM review via MCP sampling | Self-checking, quality gates |
Each thought carries a semantic thoughtType (reasoning, decision_frame, action_report, belief_snapshot, assumption_update, context_snapshot, progress) that classifies what kind of thought it is, orthogonal to the process pattern used.
See the Patterns Cookbook for comprehensive examples.
Real-Time Observability
The Observatory is a built-in web UI at http://localhost:1729 for watching reasoning unfold live.
- Live Graph — thoughts appear as nodes in real-time via WebSocket
- Branch Navigation — branches collapse into clickable stubs; drill in and back out
- Detail Panel — click any node to view full thought content
- Multi-Session — switch between active reasoning sessions
- Deep Analysis — analyze sessions for reasoning patterns, cognitive load, and decision points
The full observability stack includes OpenTelemetry tracing, Prometheus metrics, and Grafana dashboards.
Knowledge & Reasoning Tools
Knowledge Graph — Persistent memory across sessions. Capture insights, concepts, workflows, and decisions as typed entities with typed relations (BUILDS_ON, CONTRADICTS, SUPERSEDES, etc.) and visibility controls (public, agent-private, team-private).
Notebooks — Interactive literate programming combining documentation with executable JavaScript/TypeScript in isolated environments.
Client Compatibility