[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-83197":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":17,"stars7d":18,"stars30d":18,"stars90d":16,"forks30d":16,"starsTrendScore":19,"compositeScore":20,"rankGlobal":10,"rankLanguage":10,"license":21,"archived":22,"fork":22,"defaultBranch":23,"hasWiki":24,"hasPages":24,"topics":25,"createdAt":10,"pushedAt":10,"updatedAt":32,"readmeContent":33,"aiSummary":10,"trendingCount":16,"starSnapshotCount":16,"syncStatus":34,"lastSyncTime":35,"discoverSource":36},83197,"munder-difflin","chaitanyagiri\u002Fmunder-difflin","chaitanyagiri","local multi-agent harness","https:\u002F\u002Fmunderdiffl.in",null,"TypeScript",514,56,157,11,0,15,220,87,9.27,"Other",false,"main",true,[26,27,28,29,30,31],"agents","claude-code","free","harness","harness-engineering","memory","2026-06-12 02:04:32","\u003Cdiv align=\"center\">\n\n\u003Cimg src=\".\u002Fdocs\u002Flogo.png\" alt=\"Munder Difflin Inc — Multi-Agent Harness\" width=\"340\">\n\n# Munder Difflin\n\n**Local multi-agent harness for [Claude Code](https:\u002F\u002Fclaude.com\u002Fclaude-code).**\nAutonomous agents that message, route, and remember — coordinated by a **GOD** orchestrator\nyou talk to, and visualized as avatars at work on a shared office floor.\n\n\u003Cp>\n  \u003Cem>Electron · React · TypeScript · Pixi.js · xterm.js · node-pty\u003C\u002Fem>\n\u003C\u002Fp>\n\n\u003Cp>\n  \u003Ca href=\".\u002FLICENSE\">\u003Cimg alt=\"License: MIT\" src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Flicense-MIT-F4D35E.svg?style=flat-square&labelColor=6E1423\">\u003C\u002Fa>\n  \u003Cimg alt=\"Status: prototype\" src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fstatus-working%20prototype-F4F1EA.svg?style=flat-square&labelColor=6E1423\">\n  \u003Cimg alt=\"Platform: macOS | Windows | Linux\" src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fplatform-macOS%20%7C%20Windows%20%7C%20Linux-F4F1EA.svg?style=flat-square&labelColor=6E1423\">\n  \u003Ca href=\".\u002FCONTRIBUTING.md\">\u003Cimg alt=\"PRs welcome\" src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FPRs-welcome-F4D35E.svg?style=flat-square&labelColor=6E1423\">\u003C\u002Fa>\n\u003C\u002Fp>\n\n\u003Cbr>\n\n\u003Cimg src=\".\u002Fdocs\u002Fmedia\u002Fog.png\" alt=\"Munder Difflin — A hive of agents that message, route, and remember\" width=\"1240\">\n\n\u003Cbr>\n\n\u003C!-- Inline player renders on github.com (raw URL required; relative paths only link). -->\n\u003Cvideo src=\"https:\u002F\u002Fgithub.com\u002Fchaitanyagiri\u002Fmunder-difflin\u002Fraw\u002Fmain\u002Fdocs\u002Fmedia\u002Fhero.mp4\" poster=\"https:\u002F\u002Fgithub.com\u002Fchaitanyagiri\u002Fmunder-difflin\u002Fraw\u002Fmain\u002Fdocs\u002Fmedia\u002Fog.png\" controls muted loop playsinline width=\"820\">\n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Fchaitanyagiri\u002Fmunder-difflin\u002Fraw\u002Fmain\u002Fdocs\u002Fmedia\u002Fhero.mp4\">▶ Watch the floor — Munder Difflin running a hive of Claude Code agents\u003C\u002Fa>\n\u003C\u002Fvideo>\n\n\u003C\u002Fdiv>\n\n---\n\n> [!NOTE]\n> **The world's best agents. The world's worst paper company.**\n> Munder Difflin takes the `claude` CLI sessions you already run in your terminal and turns them\n> into a self-coordinating team: each agent gets long-term memory, a mailbox, and a desk on a 2D\n> office floor — and a **GOD orchestrator agent** routes work between them while you watch.\n\n## What it is\n\nMunder Difflin is a desktop app that wraps **real Claude Code terminals** as fully-capable agents,\nwires them into a **hive mind**, and puts a **GOD orchestration agent** in charge — the one agent\n*you* talk to in order to get things done. Under the hood it runs the **fastest memory layer in the\nworld** so every agent remembers what it learns and recalls it instantly.\n\n- **Every terminal is an agent.** Each `claude` session runs as a real process in a pseudo-terminal\n  (`node-pty`), byte-for-byte authentic, rendered with xterm.js.\n- **Every agent is an avatar.** Sessions appear as characters on a Pixi.js office floor — they walk\n  to stations as they work, and envelopes fly desk-to-desk when they message each other.\n- **The hive coordinates them.** Agents read their memory and drain a mailbox; the router moves\n  messages between inboxes; the GOD agent adjudicates, assigns, and escalates only when it needs you.\n- **Memory that's instant.** A markdown-first memory layer with a semantic recall index means agents\n  remember across sessions and recall in milliseconds.\n\n## How it works\n\n```\n            you ── talk to ──►  ┌─────────────┐\n                                │  GOD agent  │  orchestrator \u002F supervisor\n                                │ (Michael's  │  roster · routing · adjudication\n                                │   office)   │  blackboard · task ledger\n                                └──────┬──────┘\n                                       │ assigns · routes · escalates\n              ┌────────────────────────┼────────────────────────┐\n              ▼                         ▼                         ▼\n        ┌───────────┐            ┌───────────┐            ┌───────────┐\n        │  agent A  │  message   │  agent B  │  message   │  agent C  │\n        │  claude   │ ─────────► │  claude   │ ─────────► │  claude   │\n        │  + memory │            │  + memory │            │  + memory │\n        └───────────┘            └───────────┘            └───────────┘\n              └──────── shared hive: memory · mailbox · blackboard · log ───────┘\n```\n\n1. **You spawn agents** — each is a normal `claude` process with its own working directory,\n   identity, and hook lifecycle.\n2. **Agents collaborate through the hive** — a local git repo of plain files. They write to their own\n   `outbox\u002F`; the harness's router delivers into recipients' `inbox\u002F`. No agent ever touches git\n   (single-committer design avoids `index.lock` corruption).\n3. **The GOD agent runs the floor** — it reads every request, resolves routine ones itself (keeping\n   the system fully autonomous), and only escalates *critical* items (spend, destructive ops, scope\n   changes) into an approvals queue you act on.\n4. **Everything is visible** — you watch avatars move, envelopes fly, and the live terminal stream;\n   you can type back into any session, browse its files, and read its git history.\n\nSee [`HIVE.md`](.\u002FHIVE.md) for the full multi-agent design, [`SPEC.md`](.\u002FSPEC.md) for the\nterminal\u002Fevent plane, and [`DESIGN.md`](.\u002FDESIGN.md) for the visual system.\n\n## Features\n\n| Area | What works today |\n|---|---|\n| **Real terminals** | Spawn any command (default: `claude`) in a `node-pty` PTY. Full read\u002Fwrite\u002Fresize\u002Fkill, live streaming over IPC, multi-agent. |\n| **The hive** | On-disk multi-agent layer: per-agent identity + long-term memory, atomic-file mailboxes, a shared blackboard, append-only event log, single-committer git. |\n| **GOD orchestrator** | An always-on supervisor agent that adjudicates traffic, routes tasks, scribes the blackboard, and escalates only critical items to you. |\n| **Memory layer** | Markdown-first long-term memory per agent, mined into a shared semantic palace for instant recall; searchable from the UI. Degrades gracefully when the index isn't installed. |\n| **Office floor** | Pixi.js scene with a Tiled office map, camera, recolored cast, pathfinding, seat assignment, and tool-bubble overlays. |\n| **Message handoffs** | When the hive routes a message, an envelope flies from sender to recipient (tinted by speech-act; escalations fly to the door) and pops an arrival sparkle. |\n| **Per-agent panel** | Live terminal, command bar to type back, fullscreen terminal, sandboxed file browser + CodeMirror editor, and a git tab (status, log, commit graph, branches). |\n| **Approvals & memory panels** | Human-in-the-loop approval queue for escalations; a memory search panel over the shared palace. |\n| **Onboarding wizard** | First-run setup: harness home, registered repos, default command, auto-mode. |\n| **Design system** | Fully tokenized SNES \u002F Animal-Crossing aesthetic — pixel panels, buttons, badges, hand-drawn icons. See [`DESIGN.md`](.\u002FDESIGN.md). |\n| **Command Center** | Michael's control surface, overhauled in v0.2.0: Terminal, Floor (roster + dispatch + per-agent model selector + live fleet monitoring), Memory (MemPalace + text search + memory graph), Activity (log + board + real token telemetry + observability + CI watcher), Tasks (kanban board with dependencies + status tracking), Schedules (recurring missions + heartbeat). |\n| **Per-agent git worktrees** | 'Git isolation' toggle in Add Agent auto-provisions a dedicated worktree per agent on spawn and tears it down on kill — agents never collide on branches. |\n| **Token & cost telemetry** | Activity tab reads `~\u002F.claude\u002Fprojects\u002F` JSONL transcripts and surfaces real token counts + estimated USD cost per agent per session, backed by a durable cost ledger that survives restarts. |\n| **Per-agent token budgets** | Set a token budget per agent and watch live fleet monitoring track consumption across the whole roster — paired with the cost\u002Frunaway circuit breaker to keep spend in check. |\n| **Observability** | Live OpenTelemetry collector with per-model cost attribution, a fleet grid, and a per-agent tool-span waterfall — see exactly what every agent is doing and what it costs, in real time. |\n| **Context-window gauge** | Each agent card's progress bar is a context-window gauge — see how much of the model's context each agent has consumed at a glance. |\n| **Circuit breaker** | A cost\u002Frunaway guard with a steer → constrain → stop ladder: the breaker nudges, then constrains, then stops agents that loop, storm errors, or blow their budget. |\n| **HITL gate & mid-run control** | Human-in-the-loop gate, mid-run steer, and graceful stop — all driven through Claude Code hook returns, so you can intervene without killing the session. |\n| **Durable persistence** | SQLite-backed durable store keeps window bounds + history across restarts, alongside the durable cost ledger and persisted session IDs. |\n| **MemoryReflector** | Memory condensation that summarizes and bounds per-agent memory over time, so long-term memory doesn't grow without limit. |\n| **Configurable home folder** | Point the hive\u002Fmemory home at any folder, with a safe move that relocates existing state without losing it. |\n| **Restore team** | One-click \"Restore team\" rebuilds last session's workers after a harness restart — no more re-adding agents by hand. |\n| **Task kanban** | Dependency-aware kanban board in the Command Center Tasks tab — assign tasks to agents, track status across todo\u002Fdoing\u002Fblocked\u002Fdone, wire dependencies so work starts in order. |\n| **Scheduled missions & heartbeat** | Recurring auto-dispatch missions with label, interval, target agent, and body — plus a scheduler heartbeat that re-engages the floor when it goes quiet. Delete scheduled missions inline, and see last\u002Fnext-fired times in the Schedules tab. |\n| **GitHub ingestion** | Pull open issues from any registered repo via the `gh` CLI and assign them to agents with one click from the Command Center. |\n| **CI status watcher** | Live pass\u002Ffail\u002Fin-progress status for GitHub Actions runs, visible in the Activity tab for every registered repo. |\n| **Threaded chat** | Every hive message is grouped by conversation and rendered as a reply chain in each agent's Messages tab — readable, replyable, auditable. |\n| **Desktop notifications** | Native OS notifications when an agent finishes a task or is waiting for your input. |\n| **Agent archival** | Closing an agent tab archives it (memory + history preserved) rather than destroying it. |\n| **Avatar states** | Avatars reflect real work — including new v0.2.0 states for *compacting* (context compaction) and *looping* (circuit-breaker intervention), on top of crisper HiDPI floor text and high-contrast speech bubbles. |\n\n> [!NOTE]\n> **Status: v0.2.0 — observability, control, and durability.** This release brings a Command Center overhaul, per-agent token budgets with live fleet monitoring, full observability (live OpenTelemetry collector, per-model cost, fleet grid + per-agent tool-span waterfall), an agent-card context-window gauge, a cost\u002Frunaway circuit breaker (steer → constrain → stop) with a scheduler heartbeat, a human-in-the-loop gate plus mid-run steer and graceful stop via hook returns, SQLite-backed durable persistence (window bounds + history) and a durable cost ledger, the MemoryReflector for memory condensation, a configurable hive\u002Fmemory home folder with safe move, one-click \"Restore team\" after restart, a delete button for scheduled missions, new *compacting* and *looping* avatar states, terminal legibility\u002Fcontrast + HiDPI fixes, and a Windows fix to keep the hive alive behind the lock screen. All of v0.1.x — the hook plane, office floor, hive coordination, git isolation, token telemetry, task kanban, scheduled missions, GitHub\u002FCI integration, threaded conversations, desktop notifications, agent archival, a Slack→queue bridge, and native human-in-the-loop approvals — remains functional and shipping. macOS (signed), Windows, and Linux builds are available on the releases page.\n\n## Getting started\n\n### Prerequisites\n\n- **macOS** (macOS-first; Windows\u002FLinux untested).\n- **Node.js 18+** and npm.\n- A **C\u002FC++ toolchain** for `node-pty`'s native addon — on macOS, install Xcode Command Line Tools:\n  ```bash\n  xcode-select --install\n  ```\n- **[Claude Code](https:\u002F\u002Fclaude.com\u002Fclaude-code)** on your `PATH` so agents can run `claude`\n  (the default command). Any other command works too.\n- *Optional:* the semantic memory index for instant cross-session recall (the app works without it —\n  markdown memory still functions).\n\n### Install & run\n\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002Fchaitanyagiri\u002Fmunder-difflin.git\ncd munder-difflin\nnpm install        # postinstall rebuilds node-pty against Electron's ABI\nnpm run dev        # launches the Electron app with hot reload\n```\n\nOn first launch you'll go through the onboarding wizard, then land on the floor. Use **Add agent** to\nspawn your first session — the GOD agent seats itself in Michael's office automatically.\n\n### Other scripts\n\n```bash\nnpm run build      # production build via electron-vite\nnpm run preview    # preview the production build\nnpm run typecheck  # type-check the node (main\u002Fpreload) and web (renderer) projects\n```\n\n> If `node-pty` fails to load after an Electron upgrade, re-run `npm install` (the `postinstall` hook\n> runs `electron-rebuild` against the current Electron ABI).\n\n## Architecture\n\nTwo data planes feed one renderer:\n\n```\n┌───────────────────────────────────────────────────────────────┐\n│                     Electron Renderer (React)                  │\n│   ┌──────────────────┐    ┌──────────────────────────────┐    │\n│   │ Office Floor      │    │ Terminal + Command Bar       │    │\n│   │ (Pixi.js)        │    │ Files + Git tabs (xterm.js)  │    │\n│   └─────────▲────────┘    └────────────▲─────────────────┘    │\n│             │ avatar state             │ pty bytes \u002F fs \u002F git  │\n└─────────────┼──────────────────────────┼───────────────────────┘\n              │ IPC (contextBridge: window.cth)\n       ┌──────┴──────────┐        ┌──────┴─────────────┐\n       │  Event Plane    │        │  Terminal Plane    │\n       │  hooks \u002F hive   │        │  node-pty PTYs     │\n       │  router + GOD   │        │  + fs + git        │\n       └────────▲────────┘        └──────▲─────────────┘\n                │ hook payloads          │ stdin \u002F stdout\n                └─────────┬──────────────┘\n                   ┌──────┴──────────────┐\n                   │  claude (or any cmd)│\n                   └─────────────────────┘\n```\n\n- **Terminal plane.** The main process owns a `PtyManager` that spawns each agent as a `node-pty`\n  process and streams output over per-id IPC (`pty:data:\u003Cid>`). The renderer talks only through a\n  typed `window.cth` bridge ([`src\u002Fpreload\u002Findex.ts`](.\u002Fsrc\u002Fpreload\u002Findex.ts)), which also exposes\n  sandboxed filesystem and git helpers.\n- **Hive \u002F event plane.** `hive.ts` is the on-disk multi-agent layer; `hooks.ts` runs a Unix-socket\n  server that the per-agent `cth-hook` shim POSTs Claude Code hook payloads to (`PreToolUse`,\n  `PostToolUse`, `Stop`, …); `memory.ts` wraps the semantic memory CLI. The router delivers messages,\n  the GOD agent adjudicates, and a `Stop`-loop keeps idle agents draining their inboxes.\n\n## Project structure\n\n```\nsrc\u002F\n  main\u002F                      Electron main process (Node)\n    index.ts                 window, IPC handlers, quit guard\n    pty.ts                   node-pty manager (spawn\u002Fwrite\u002Fresize\u002Fkill\u002Fstream)\n    hive.ts                  on-disk multi-agent layer (memory, mailboxes, router)\n    hooks.ts                 UDS hook server + cth-hook shim + Stop-loop\n    memory.ts                semantic memory layer (CLI wrapper, degrade-to-noop)\n    config.ts                harness config persistence + home setup\n    transcript.ts            reads ~\u002F.claude\u002Fprojects\u002F JSONL transcripts for real token\u002Fcost telemetry\n    telemetry.ts             live OTel collector + usage\u002Fcost feed for observability\n    usage.ts \u002F pricing.ts    UsageProvider seam + per-model cost attribution\n    breaker.ts \u002F control.ts  cost\u002Frunaway circuit breaker (steer\u002Fconstrain\u002Fstop) + HITL gate \u002F steer \u002F stop\n    reflect.ts               MemoryReflector — memory condensation\n    db.ts                    SQLite durable store (window bounds + history) + durable cost ledger\n    github.ts                GitHub issue + CI run ingestion via the gh CLI\n    assistant.ts             headless Sonnet enrichment pipeline (Dwight)\n    shellEnv.ts              resolve PATH and shell env for child processes\n    fs.ts \u002F git.ts           sandboxed filesystem + git bridges\n  preload\u002F                   contextBridge → typed window.cth API\n  renderer\u002Fsrc\u002F\n    App.tsx                  top-level layout + wiring\n    design\u002F                  tokens.css \u002F tokens.ts \u002F global.css (design source of truth)\n    components\u002F              PixelPanel, AgentDetailPanel, CommandBar, ApprovalsPanel, MemoryPanel, …\n    CommandCenterPanel,      Michael's control surface (Terminal\u002FFloor\u002FMemory\u002FActivity\u002FTasks\u002FSchedules\u002FHandbook tabs)\n    ToolWaterfall,           per-agent tool-span waterfall for the observability view\n    TasksKanban,             dependency-aware kanban board (Tasks tab)\n    ThreadsPanel,            hive message conversation viewer (Messages tab)\n    MessageQueueComposer,    park messages for a busy agent + enrich toggle\n    scene\u002Foffice\u002F            Pixi office floor: OfficeFloor, Character, Camera, cast, pathfinding, …\n    store\u002F · hooks\u002F          zustand store, event loop, PTY parser, typewriter\n    assets\u002F                  tilesets, maps, character sheets (see ATTRIBUTION.md)\ndocs\u002F                        `logo.png`, `banner.png`, landing page (GitHub Pages → munderdiffl.in)\ndocs\u002Fmedia\u002F                  `og.png` (social previews) + rendered Remotion clips\nlanding-remotion\u002F            Remotion project that renders the landing page's \"how it works\" clips\nHIVE.md · SPEC.md · DESIGN.md   multi-agent · terminal\u002Fevent · visual design\n```\n\n## Design system\n\nThe aesthetic is **Animal Crossing × Earthbound × SNES menu UI** — pixel-snapped, chunky, friendly.\n[`DESIGN.md`](.\u002FDESIGN.md) is canonical; every component derives from its tokens. The Munder Difflin\nbrand layers a **Dunder-Mifflin maroon** (`#6E1423`) and **gold** (`#F4D35E`) on top for logo and\nchrome. The 15 avatars are the cast of *The Office*, differentiated by hair\u002Fskin\u002Fshirt recipes.\n\n## Roadmap\n\nShipped in **v0.2.0**:\n\n- [x] **Heartbeat** — scheduler heartbeat that re-engages the floor when it goes quiet, with last\u002Fnext-fired times surfaced in the Schedules tab.\n- [x] **Memory reflection** — the MemoryReflector summarizes and bounds per-agent memory over time to prevent unbounded growth.\n- [x] **Persistence** — SQLite-backed durable store for window bounds + history across restarts, plus a durable cost ledger and persisted session IDs.\n- [x] **Hook-driven avatars** — broadened hook→station coverage and caged the synthetic demo loop, with new *compacting* and *looping* avatar states.\n\nNext up:\n\n- [ ] **Chat integrations** — Slack and Telegram bridges that pipe a channel straight into Michael's queue (and route his replies back out), so you can run the floor from your phone.\n- [ ] **Pluggable agent CLIs** — run the harness over coding-agent CLIs beyond Claude Code: Claw Code, opencode, and Codex CLI.\n- [ ] **Realtime Michael** — a low-latency realtime LLM channel for quick, snappy back-and-forth with the orchestrator, alongside the async terminal.\n- [ ] **Fuller avatar coverage** — push the remaining station visits and tool-bubbles to be driven 100% by real Claude Code hook events.\n- [ ] **Durable layout & command history** — extend persistence to agent layout and per-session command history.\n\n## Contributing\n\nContributions are welcome — this is an early prototype with a lot of surface area. Start with\n[`CONTRIBUTING.md`](.\u002FCONTRIBUTING.md). The short version: fork, `npm install && npm run dev`, keep\n`npm run typecheck` green, and **derive any new UI from [`DESIGN.md`](.\u002FDESIGN.md) tokens**. Good\nfirst areas: wiring real hook events, the add-agent flow, the config drawer, and cross-platform work.\n\n## License\n\n> [!IMPORTANT]\n> **Asset licensing.** The bundled pixel art (tilesets, maps, and the base character sheets the\n> Office cast is recolored from) comes from [LimeZu](https:\u002F\u002Flimezu.itch.io\u002F) via\n> [`shahar061\u002Fthe-office`](https:\u002F\u002Fgithub.com\u002Fshahar061\u002Fthe-office) under the **LimeZu FREE VERSION\n> license — non-commercial use only**. The recolored sprites inherit that restriction. See\n> [`src\u002Frenderer\u002Fsrc\u002Fassets\u002FATTRIBUTION.md`](.\u002Fsrc\u002Frenderer\u002Fsrc\u002Fassets\u002FATTRIBUTION.md). **To\n> commercialize, replace these assets or obtain a paid LimeZu license.**\n\nThe **source code** is licensed under the **MIT License** — see [`LICENSE`](.\u002FLICENSE). The MIT grant\ncovers the code only; the non-commercial asset restriction above is carved out in the `LICENSE` scope\nnote. *Munder Difflin* is an affectionate parody and is not affiliated with NBC's *The Office* or\nDunder Mifflin.\n\n## Acknowledgements\n\n- [LimeZu](https:\u002F\u002Flimezu.itch.io\u002F) — pixel-art tilesets and character base sheets.\n- [`shahar061\u002Fthe-office`](https:\u002F\u002Fgithub.com\u002Fshahar061\u002Fthe-office) — office tileset\u002Fmap vendoring.\n- [Pixi.js](https:\u002F\u002Fpixijs.com\u002F) · [xterm.js](https:\u002F\u002Fxtermjs.org\u002F) · [node-pty](https:\u002F\u002Fgithub.com\u002Fmicrosoft\u002Fnode-pty) · [electron-vite](https:\u002F\u002Felectron-vite.org\u002F) · [CodeMirror](https:\u002F\u002Fcodemirror.net\u002F) — the libraries this is built on.\n- [Remotion](https:\u002F\u002Fwww.remotion.dev\u002F) — the landing page's animated \"how it works\" clips (`landing-remotion\u002F`).\n- *The Office* (US) — for Munder Difflin, Inc.\n",2,"2026-06-11 04:10:22","CREATED_QUERY"]