githubnext/chopinPublic

Let's compose rich plans together

Let a local agent hand an instruction to the Planner

Expose invoke_planner only for the full local Atomic mode. Resolve the
existing document and require a live browser login for the MCP caller's
GitHub identity; the bearer never supplies Planner ownership. Verify an
explicit checkout before posting, and retain it only for its own turn.

Persist the verbatim instruction as a member message before returning the
canonical document URL. Keep a server-opened room alive through the turn
and queue, without changing ordinary socket-only eviction. Document the
local shell and filesystem trust boundary and refusal codes.

Assistant-model: Claude Opus 5.5
Assistant-workflow: goal (run 98acf681-3730-4957-b885-0d70e0e6b32a)
Assistant-verification: bun test passed: 1718 pass, 2 PostgreSQL skips, 0 fail, 7344 assertions across 196 files
Assistant-verification: focused MCP tests passed: 87 tests, including capability gating, input bounds, output schemas, session ownership and checkout verification
Assistant-verification: harness tests passed: 141 tests; full Atomic and default isolated behavior remain covered
Assistant-verification: bun run types passed: all workspaces and E2E
Assistant-verification: bun run fix and bun run ci passed: formatting inspected; no errors, one existing lint warning and no new design findings
Assistant-verification: relative documentation links passed: 26 targets and anchors resolved with exact casing
Assistant-verification: qlty smells completed: guard-return complexity and existing archive/restore duplication recorded in implementation notes
User-preference: "Atomic's SDK is the runtime and the host supplies human input; Chopin implements HostInput rather than intercepting tools"
User-preference: "In local mode the Planner may run as a full Atomic session so workflows run inside Chopin with questions in Decisions"
Co-authored-by: Alex Lavaee <lavaman131@github.com>
ALAlex Lavaee authored
c4e32f5Patch
Parent59a8712
17 files changed+976-25
StackedSplit
apps/server/src/auth/session.test.ts+20 โˆ’0
apps/server/src/auth/session.ts+10 โˆ’0
apps/server/src/chat/address.ts+2 โˆ’1
apps/server/src/chat/invoke.test.ts+241 โˆ’0
apps/server/src/chat/limits.ts+1 โˆ’0
apps/server/src/chat/service.ts+83 โˆ’5
apps/server/src/main.ts+47 โˆ’11
apps/server/src/mcp.ts+97 โˆ’0
apps/server/src/mcp/documents.test.ts+1 โˆ’0
apps/server/src/mcp/hosted.test.ts+173 โˆ’0
apps/server/src/mcp/hosted.ts+61 โˆ’0
apps/server/src/mcp/invoke.test.ts+109 โˆ’0
apps/server/src/rooms.test.ts+35 โˆ’0
apps/server/src/rooms.ts+18 โˆ’0
docs/hosted-agent.md+7 โˆ’0
docs/local-agent-mcp.md+64 โˆ’8
docs/self-hosting.md+7 โˆ’0