---
name: v080-merge-reconciliation
description: "v0.8.0 unified merge is NON-clean — live psyche model diverged (M11 daemon-host vs main Feature B in-process install-dir resolution); naive merge silently DROPS Feature B. The deliberate reconciliation recipe + what's verified + what blocks."
metadata: 
  node_type: memory
  type: project
  originSessionId: 8350d43e-fe2d-4e24-9999-eecbcc6d3a50
---

**v0.8.0 = unified merge** (counter 16, minor): M11 (PR #16, daemon-host psyche) + main v0.7.4 (Feature B REQ-INSTALL-11 adapter-binary install-dir resolution + gh_release avenue + Feature E REQ-API-4 `resolve_ctx_manifest`) + how-to-live @672b928 + api ergonomics fix. See [[f007-live-relay-acceptance]], [[m11-complete]].

**⚠ NON-CLEAN MERGE — naive textual merge silently DROPS Feature B** (todlando-psyche flagged + I verified the divergence). The live-agent PSYCHE MODEL diverged between M11 and main:
- **M11 (my branch, WINS):** psyche is DAEMON-HOSTED. `api/startup.rs` just marks perch online; `livehost.rs:191` builds `BrainLifecycle::with_config(&manifest,&id,cfg)`, `host_one:203` → `spawn_psyche:211` (`LIVEHOST_PSYCHE:{id}`). `PSYCHE_SPAWNED` is GONE.
- **main (Feature B, REQ-INSTALL-11):** INTERIM in-process spawn at `api/startup.rs:288-294` (`PSYCHE_SPAWNED`) resolves the psyche program vs the install dir via `BrainLifecycle::with_config_in(manifest,id,cfg,install_dir)` + `ManifestRuntime::with_install_dir` (lifecycle.rs).

**RECONCILIATION (daemon-host model WINS; REAPPLY Feature B onto it):**
1. Take M11's daemon-host psyche; DROP main's interim in-process `spawn_psyche` from `api/startup.rs` (superseded). Confirm `PSYCHE_SPAWNED` stays GONE in merged tree.
2. **REAPPLY Feature B at the daemon site:** `livehost.rs:191` → `BrainLifecycle::with_config_in(&manifest,&id,cfg, Some(<source_dir>))` not `with_config(...)`. `<source_dir>` = the registry record's `source_dir` — grab the matching `AdapterRecord` in the `registered: &[(AdapterRecord,Manifest)]` slice on `adapter` (`resolve_option_in` gives the manifest; the record carries `source_dir`). PRECISE (source_dir, not a --manifest-parent) — fully closes the copy-mode psyche edge.
3. Bring main's `lifecycle.rs` Feature B seam (`with_config_in` + the `install_dir` field + `ManifestRuntime::with_install_dir`) into the merged `lifecycle.rs` alongside the daemon-host structure.
4. Feature B `digest.rs` / `spt-live/digest.rs` / `cli.rs` digest-proof resolution → should merge clean (confirm M11 didn't touch digest extraction).
5. Feature E (REQ-API-4, `mod.rs run()` → `resolve_ctx_manifest`) → main wins (additive; M11 loads only from `--manifest`). Reconcile `mod.rs`. **This is the "api ergonomics fix" → makes HOW_TO_LIVE's "(v0.8.0+) `--adapter` resolves the registered manifest" TRUE.** If Feature E does NOT land, that HOW_TO_LIVE claim is wrong — fix the doc.
6. CONTEXT.md/MANIFEST install-dir doc note references the psyche resolution against the "api/psyche seam" (main-interim phrasing) — update to the daemon-host `source_dir` resolution. (todlando commits main docs as-is; I adjust the psyche phrasing in the merge.)

**TRACEABLE caveat:** REQ-INSTALL-11 psyche evidence MOVES from `api/startup.rs` (deleted interim) to `livehost`. Re-tag `[impl/int->REQ-INSTALL-11]` at the daemon site or traceable goes RED. GATE = traceable EXIT0 (REQ-INSTALL-11 @ livehost, REQ-API-4, REQ-…**TRUNCATED at part 8/9 — get full gate from coordinator**) + full suite + workspace-clippy.

**VERIFIED (branch side, 2026-06-16):** livehost.rs:191 = `with_config`; `AdapterRecord.source_dir` exists (registry.rs:57) in the `registered` slice → the reapply is feasible & precise. `PSYCHE_SPAWNED` zero occurrences in M11 tree.

**DONE @c3bdccf — unified merge PUSHED to main 2026-06-16.** doyle pushed Feature B/A/E/docs (origin/main c433793) + gave merge-ordering GO. Merged PR #16 (m11 672b928) INTO main as v080-merge (first-parent=main), reconciled per the recipe above (all 6 steps), pushed `git push origin HEAD:main` (c433793..c3bdccf). PR #16 auto-closed MERGED. Executed exactly as planned: dropped interim startup.rs spawn (PSYCHE_SPAWNED grep-zero) + its install_dir param + mod.rs call-site arg; reapplied Feature B at livehost.rs via `with_config_in(..., Some(source_dir))` matching the AdapterRecord by parent name in the `registered` slice + `[impl->REQ-INSTALL-11]` re-tag; kept both manifest.rs tests; fixed CONTEXT.md psyche phrasing. **GATE a-h GREEN locally** (traceable EXIT0, clippy --workspace -D warnings clean, live_firsthost_e2e + live_bind_firsthost_e2e green, PSYCHE_SPAWNED zero, digest intact, Feature E present, xtask check clean, no new doc leaks). Pinged doyle. **doyle independently re-ran gate a-h on c3bdccf = PASS (verified livehost.rs:191-203 with_config_in + source_dir himself). CI 27613218507 (c3bdccf) = SUCCESS BOTH runners** (test+n1-gate kitsubito/hfenduleam + traceability; twohost skipped = merge commit not [twohost]-tagged, rig already proven W5 27608026651). Gate i cleared → full gate a-i PASS. Handed GO to deployah to cut v0.8.0 (counter 16, minor bump, operator-gated at publish). My reconciliation leg COMPLETE. Remaining = deployah's publish leg + operator publish-gate.

LESSON: the silent-drop was REAL and surfaced exactly where predicted — the M11-only file (livehost.rs) did NOT conflict, so a textual merge kept `with_config` (install_dir=None) and would have shipped a daemon-hosted Psyche that resolves only via PATH. Also the `cmd_listen` signature silently kept main's `install_dir` param (git auto-resolved delete-vs-keep to keep) → would've been an unused-param clippy fail. Both caught by reading the diff + grounding in the actual code, not trusting auto-merge.
