> ## 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.

# ADR-21: Two-bucket tiered environment resolution (HOST_ENV / PRISM_ENV + MODE_PROFILES) — modes named local/lan/cloud

> Supersedes ADR-19. Same architectural decision, one naming correction: PRISM_MODE values are now `local`, `lan`, `cloud` (previously `personal`, `lan`, `cloud`)

<Info>**Status:** `accepted` · **ADR-21** · Filed 2026-04-19</Info>

## Decision

Supersedes ADR-19. Same architectural decision, one naming correction: PRISM\_MODE values are now `local`, `lan`, `cloud` (previously `personal`, `lan`, `cloud`). All other content stands: two-bucket env split (HOST\_ENV discovered, PRISM\_ENV chosen), 4-tier resolution (system -> env -> config -> MODE\_PROFILES), startup provenance logs, one-codebase mode-awareness concentrated in MODE\_PROFILES. Contract in SPEC-019 v1.1.

## Rationale

`local / lan / cloud` mirrors standard dev conventions (.env.local, .env.lan, .env.cloud; next-style NEXT\_ENV=local; Rails RAILS\_ENV=local) — a developer reading PRISM\_MODE=local immediately knows the shape. `personal` was a Prism-internal coinage that required explanation and would confuse external collaborators reading SPEC-019 or the PDF Lola is compiling. Renaming now (before any implementation code is written against SPEC-019) is free; renaming after implementation would cost a cascade. Existing artifacts that carry the old name (docker-compose.personal.yml, container names prism-personal-\*, neo4j/prism\_personal auth, BackendMode literal in install/backend.py) are renamed as part of SPEC-019's migration path — they're implementation-side, not decision-side, so the rename follows the new decision mechanically.

## Alternatives Considered

(a) Edit ADR-19 in place: violates PRISM.md §A3 ADR immutability. (b) Keep `personal`: loses dev-convention recognizability, forces explanation in every external-facing doc including Lola's PDF. (c) Use `self-hosted` instead of `local`: more descriptive but longer, and `local` already denotes the common case (my machine, no remote).
