> ## Documentation Index
> Fetch the complete documentation index at: https://prism.ntecdev.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Plan #3: BIOS v2 rollout — env-var paths + SOR/replica sync

> BIOS v2 rollout — env-var paths + SOR/replica sync

<Info>**Status:** `superseded` · **Version** `1` · Filed 2026-04-17</Info>

## Goal

Implement ADR #11. Move CLAUDE.md from a project-specific, path-hardcoded legacy file to a thin, project-agnostic BIOS. Add version-pin drift detection and a manual force-sync verb. Ship the SOR templates under \$PRISM\_ROOT/templates/.

## Waves

### Wave A — SOR templates (files to disk)

A1. Create $PRISM_ROOT/templates/ directory if absent.
A2. Write SOR CLAUDE.md v2.0.0 to $PRISM\_ROOT/templates/CLAUDE.md (draft provided in handoff).
A3. Audit existing templates/prism-base.md and templates/prism-application.md from the last sprint — confirm they don't overlap CLAUDE.md BIOS scope; if they do, reconcile.
A4. Update PRISM.md template to remove any BIOS-layer content that moved up to CLAUDE.md.

### Wave B — Server: version sync protocol

B1. Add bios\_version parsing to prism\_start. Read replica's bios\_version header from current project dir's CLAUDE.md.
B2. Compare to SOR version at \$PRISM\_ROOT/templates/CLAUDE.md.
B3. On MAJOR mismatch, return a sync\_required flag in the prism\_start payload so the client prompts the user.
B4. On MINOR mismatch, emit a soft warning in the payload (no prompt).

### Wave C — New verb: prism\_sync\_bios

C1. Spec the verb: signature prism\_sync\_bios(pid, force=false, files=\['CLAUDE.md'|'all']).
C2. Implementation reads SOR from $PRISM_ROOT/templates/, writes to `$PROJECT\_ROOT/{project_dir}/\`, preserves any user-local override blocks (TBD — see Wave E).
C3. When force=false, requires replica bios\_version \< SOR bios\_version (major) to run; otherwise errors "already current."
C4. When force=true, overwrites unconditionally. Use for recovery.

### Wave D — Replica rollout for existing projects

D1. Migrate PID-PGR01's CLAUDE.md to v2 BIOS (replica). This session's /mnt/project/CLAUDE.md becomes the test case.
D2. If PrismGR is a separate project from Prism, register it, bootstrap it, and write a v2 replica there.
D3. Confirm Frank's two other projects (DFWP, MemRGR) — register if tracked, note if not.

### Wave E — Open questions to resolve before freezing

E1. Do replicas allow user-local override blocks (e.g. project-specific custom instructions)? If yes, define a delimiter like `<!-- PRISM:LOCAL-START -->` ... `<!-- PRISM:LOCAL-END -->` that prism\_sync\_bios preserves.
E2. Does AGENTS.md also need BIOS/replica treatment, or does it stay universal and live only at \$PRISM\_ROOT/templates/AGENTS.md (no per-project replica)?
E3. The PID resolution rule — "match prism\_start on current project dir name" — needs definition. Exact match? Case-insensitive? What if dir name != project name in Prism metadata (the Prism/PrismGR case live right now)?

## Exit criteria

* SOR CLAUDE.md v2.0.0 exists at \$PRISM\_ROOT/templates/CLAUDE.md.
* prism\_start detects version drift and emits sync\_required flag.
* prism\_sync\_bios verb implemented and tested (both paths: normal upgrade, force recovery).
* PID-PGR01's replica is v2.0.0 and loads cleanly in a fresh session.
* Open questions in Wave E are either resolved or deferred to a named follow-up plan.

## Not in scope

* Four-file ring chain philosophical review (CLAUDE → PRISM → AGENTS → ORG scope and responsibility). Explicitly deferred to a future "philosophical noodling" session per Frank's call.
* Ring 4 enforcement of other methodology signals (wraps without journals, TODOs open past completion). Existing Plan #2 Wave D covers that separately.
