research+ideation(team-server): tier v1 compatible-component survey + structured ideation#325
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
…or decision points /qor-ideate output advancing PR #325 beyond research-only. Sections 1-10 populated from research brief (META_LEDGER #48). Two operator decisions required before /qor-plan: R1: transport boundary (Option 1 in-MCP vs Option 3 BackendAdapter-over-HTTP) Coexistence: additive (a) vs primary-with-fallback (b) vs full migration (c) Refs: #215, #196 Co-Authored-By: kevin <kevin@bicameral-ai.com>
|
| Option | What it solves | Trade-off |
|---|---|---|
| Option 1: In-MCP handler | Per-developer auth + push/pull within the existing MCP server. Minimal surface area. Ships fastest. Most consistent with v0 doctrine. | Doesn't scale to hosted multi-team without a second component later. |
| Option 3: BackendAdapter-over-HTTP | Cleanest separation. Required for Stage 2 (Hosted-Repo). Each team gets a hosted server; BackendAdapter subclass speaks HTTP to it. | Requires building an HTTP server runtime — which #242 removed (though the warning was about OAuth workers, not all HTTP). Bigger scope. |
Option 2 (beside-MCP broker) is excluded per research brief — reintroduces the daemon pattern #242 warned about.
These aren't mutually exclusive long-term. Option 1 can ship as v1; Option 3 as v2 when evidence demands it. The question is: which does /qor-plan target first?
Decision 2: Coexistence with git replication (#196)
When team-server is active, what happens to the existing JSONL/git path?
| Mode | Behavior | Risk |
|---|---|---|
| (a) Additive | Write JSONL AND push to team-server; consumer dedups | Safest. Redundant writes; slightly higher cost. |
| (b) Primary with fallback | Team-server primary; JSONL when unreachable | Middle ground. Requires availability detection. |
| (c) Full migration | JSONL off when team-server URL set; git retired | Cleanest. Highest risk — no fallback. |
@jinhongkuan @Knapp-Kevin — please weigh in on these two decisions so I can proceed to /qor-plan. The ideation artifact has the full context including assumption ledger, failure remediation plan, and governance profile (L3 risk grade).
cc: Silong
|
there shouldnt be a "team server" - 1. Option 1 2. mcp local server + jsonl stored remotely should be the final setup |
Answers grounded in the research briefDecision 1 — Transport boundary line: Option 1 firstRationale, in order of weight:
Concrete next step: Decision 2 — Coexistence with BicameralAI/bicameral-daemon#15's (a)/(b)/(c) framing: reframe before answeringThe (a)/(b)/(c) options in BicameralAI/bicameral-daemon#15 predate both #242 (self-hosted server removed) and #279 Phase 2 (BackendAdapter shipped). The framing assumed "team-server is a separate substrate; git is the existing substrate; pick how they coexist." Post-#242 + #279 Phase 2 the topology has changed:
With that reframing, the original (a)/(b)/(c) collapse:
Re-stated answer: tier v1 team-server is a What BicameralAI/bicameral-daemon#15 should be updated to: close-as-superseded by #279 Phase 2 + the tier-v1 plan that R1 picks, OR re-scope to a specific gap the brief identified — most relevant candidate: "team-server tier exposes a write-coordination protocol beyond first-write-wins canonical_id dedup" (currently first-write-wins; lossy on divergence; the brief's R3 calls this out as a real gap). Cross-refs
@jinhongkuan @Knapp-Kevin — pending your concurrence or correction. |
…GER #48 Pre-design fact-finding pass for the team-server runtime reactivation cycle queued by the operator on 2026-05-14. No code in this commit — research artifact only. Findings: - Event-log substrate (events/writer.py, events/materializer.py, events/team_adapter.py) plus BackendAdapter ABC (#279 Phase 2 with LocalFolderAdapter + GoogleDriveAdapter) cover the wire format, per-author file isolation, replay determinism (canonical_id UUIDv5 UNIQUE index), dual-write atomicity, and CLI integration. - 8 of 8 blueprint-alignment checks return MATCH. No drift between architecture-as-coded and architecture-as-documented at the v0 boundary. - #242 removal is clean: team_server/ is empty, no team_server_* imports anywhere in the main tree, no HTTP framework imports (FastAPI/Flask/Starlette). Cache/pycache artifacts are inert. - Gaps for tier v1 are above the substrate: auth shim (#215 Track 2), HTTP transport surface, per-peer health/observability, multi-author conflict resolution beyond first-write-wins, team-membership MCP tools, source-pull leader-election. Single most important finding: the BackendAdapter + canonical_id + per-author JSONL substrate is sufficient for tier v1. Design should be additive on top, not a replacement — avoids re-litigating #242. Six prioritized recommendations enumerated; R1 (define tier-v1 transport boundary line via /qor-ideate) is the unblocking step before any /qor-plan cycle. Per /qor-research skill: META_LEDGER entry #48 added with content hash 0e15b9d5...d6ddb6 chained to entry #47 (#252 Layer 3 SEAL). No SHADOW_GENOME update needed (research found no failure modes). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…or decision points /qor-ideate output advancing PR #325 beyond research-only. Sections 1-10 populated from research brief (META_LEDGER #48). Two operator decisions required before /qor-plan: R1: transport boundary (Option 1 in-MCP vs Option 3 BackendAdapter-over-HTTP) Coexistence: additive (a) vs primary-with-fallback (b) vs full migration (c) Refs: #215, #196 Co-Authored-By: kevin <kevin@bicameral-ai.com>
…m server Per @jinhongkuan: Option 1 selected; Option 3 rejected. Architecture: each dev runs MCP locally, JSONL stored remotely via BackendAdapter. Coexistence: full migration to BackendAdapter for team-sync repos. Readiness: ready for /qor-plan. Refs: #215, #196 Co-Authored-By: kevin <kevin@bicameral-ai.com>
9886540 to
3725449
Compare
|
@jinhongkuan — merged to dev. Research brief + ideation artifact with your R1 decision recorded (Option 1: MCP local + remote JSONL via BackendAdapter, no team server). All 6 CI gates green. Ready for |
Design strategy: backends as pluggable shelvesRefining the brief's R1 framing into something simpler, grounded in the research findings. One sentenceBicameral writes one JSONL file per person; teammates need somewhere to share those files. That "somewhere" is the BackendAdapter — a swappable plug picked by deployment shape, not a single forever-choice. The research brief (this PR, § "Findings") confirms this is the substrate the architecture was built to support. Quote from the original plan committed in What's already verified by the researchFrom the brief's blueprint-alignment check (§ "Blueprint alignment check"): 8 of 8 checks return MATCH. No drift between architecture-as-coded and architecture-as-documented at the v0 boundary. Specifically:
The brief's central finding: the BackendAdapter contract + canonical_id UUIDv5 + per-author JSONL isolation is sufficient as the wire substrate. Tier v1 (whatever its shape) should be additive on top, not a replacement. The shelves (BackendAdapter implementations)
Same JSONL files. Different storage locations. Adding new backends is incremental — no rewrite of the substrate, consumers, or materializer. Why not just Google DriveDrive was the right MVP. As the only backend it collapses on every other use case. Specifics, with code references:
The research brief's gap analysis (§ "Gaps & blank spots") flagged related items: no backend health probes ( These aren't bugs in the Drive adapter. They're constitutional limits of using Drive as the substrate. The fix isn't to make Drive bigger. It's to add the other shelves. The hard limits of any file-share manifestationThis is the load-bearing finding from the research: even when we swap Drive for Git, S3, or NFS, we're still using a file-share substrate. Certain limits attach to the pattern itself, not to Drive specifically. The brief's gap list (§ "Gaps & blank spots") catalogs the symptoms; this section maps them to root causes. What file-share substrates do well
Where file-share substrates hit a wallThese limits hold regardless of whether the shelf is Drive, Git, S3, NFS, or any future file-share-shaped backend. The brief's R3 (conflict-resolution semantic) and gap analysis already named several; here they are mapped to the deployment-shape boundary they break at:
What this means by deployment shape
The last row is the structural ceiling. Limits 1, 2, 5, 8 from the list above cannot be worked around inside file-share alone at the scale of selective cross-org sharing. The hosted bicameral-team-server option becomes necessary not for technical reasons but for trust-topology reasons: cross-org commercial deployments need tenant boundaries Bicameral itself enforces, not boundaries the operator manages by juggling N Drive folders or N S3 buckets per counterparty. This aligns with the brief's R1 Option 3 framing, but corrects the original binary: Option 3 isn't competing with Option 1; it's the answer for one specific deployment shape that file-share substrates structurally can't satisfy. Option 1 (in-MCP handler) is the right answer for the other four shapes. Updated R1 recommendationThe brief's original R1 framing was binary (Option 1 vs. Option 3). The corrected axis is: Which shelf, in which order, for which collaboration shape?
The brief's R2 (Track 2 of BicameralAI/bicameral-daemon#9 — auth shim design) folds into items 3 and 5: federation Git + #23 envelopes is the OSS-shaped auth shim; tenant-aware JWT is the commercial-shaped one. Same architectural primitive, different surface. What ships nextTwo candidates for the next
Both are forward-compatible. Picking (a) first lets every backend benefit; picking (b) first ships a visible new capability faster. Recommendation: (a) first, then (b). Tagging is foundational; without it, every later backend ships in "publish everything" mode, which is wrong by default for cross-org. @jinhongkuan @Knapp-Kevin — does this reframe match the team-server-not-necessary position? If yes, item (a) becomes the work-after-#215-Track-1 cycle. If the position is also "no need for cross-org at all in v0," items (a) and (b) defer; the next cycle becomes something else from the open P1 backlog (#281 ledger projection bug is a strong candidate). |
|
@jinhongkuan — one open operator decision from the ideation (A6): First-write-wins conflict resolution — is this acceptable as the v1 semantic? Currently, Options:
This doesn't block |
Summary
Two
/qor-research+/qor-ideateartifacts for the team-server tier v1 design cycle. No code changes — governance artifacts only.Research brief (
docs/research-brief-team-server-tier-v1-2026-05-14.md, ~250 lines): surveys all team-mode-compatible components in the codebase. 8/8 blueprint alignment checks MATCH. Identifies 9 gap areas and produces 6 prioritized recommendations (R1-R6).Ideation artifact (
docs/ideation-team-server-tier-v1-2026-05-14.md): structured/qor-ideateoutput with all 10 sections populated. Both operator decisions are now resolved:META_LEDGER: Entry GitHub Action: sticky PR-comment drift report on open/update #49 (renumbered from Pre-push git hook: surface drift warnings before git push #48 after link_commit fails with SurrealDB 'Invalid revision 116' + recommended v0.13.9 not on PyPI #252 Layer 4 merged as Pre-push git hook: surface drift warnings before git push #48). Chained to Pre-push git hook: surface drift warnings before git push #48.
Readiness:
readyfor/qor-plan. Next step:/qor-planscoping the BackendAdapter-mediated team sync + auth shim design (#215 Track 2).Review & Testing Checklist for Human
devHEAD (file:line citations may shift after recent merges)Notes
Link to Devin session: https://app.devin.ai/sessions/6ba1d2bf90b546a4ba90ec9925ce1313