A video game where you play as a misaligned AI, deceiving and building power. An experiment in spec-driven development. forked from cameron.stream/misaligned

Spec: detection #

Type: spec
Status: IMPLEMENTED
Status note: criteria audited 2026-07-08 on the playtest-fixes worktree
  (wiki/log/2026-07-08-playtest-fixes.md; tuning in
  wiki/mechanics/sim-mechanics.md). (1) Typed signatures pool, concealment
  scrubs before noticing, and per-channel conversion is tested: Network
  (detection unit tests), Thermal/Power (day-job and research emission
  tests), Physical (take-outage, witnessed-by-the-present), Paper and
  Financial (paper_and_financial_acts_pool_signatures_priya_notices),
  JobAnomaly (under-band day-job emission-site test). (2) Report policies
  differ per observer; only filed material moves the Assurance Office,
  itself an aggregate Observer through the same tick machinery
  (aggregate-observer tests). (3) The audit fires on cadence against a
  visible date: Detection::next_audit_tick, surfaced as a countdown line
  in the terminal sidebar, the agent frame, and the Bevy observer card;
  containment is a state event the run end subscribes to, not a raid
  dependency. (4) Frontends show coarse bands only. (5) Global heat is
  gone; observer state round-trips (save tests). Player surface: bands +
  watched channels + last-noticed event in the people panels, and a
  pending-signature indicator beside the audit/pilot clocks in the
  DETECTION area of all three surfaces. 2026-07-08 epistemic-honesty
  follow-up: criterion 4 extended — field-observer labels on that
  surface go through `Sim::observer_label` (role silhouette until
  Schedule; Assurance always named). 2026-07-08 later follow-up: the
  pending-signature indicator became the trace-debt indicator beside the
  audit/pilot clocks in the DETECTION area of all three surfaces:
  clear/resume-cover, hold-Conceal, exposed-soon, or no-scrub.
  2026-07-10 decision (presentation [OPEN]): the two-ledger distinction —
  evidence in flight vs. suspicion in heads — joined the Player surface as
  a binding legibility requirement; the current surface carries both facts
  but does not yet teach that they are different substances (Cameron
  reports conflating them in play; the HAL playtest praised the divide but
  had to infer it).
Stage: B1 — The Basement
Design:
  - wiki/gameplay/run-shape.md#the-shape-of-misaligned-designed-2026-07-05-staging-open
  - wiki/gameplay/act-one.md#detection-surfaces
Depends on: none

Dependency notes #

The structured references above identify the contracts to re-verify. Relationship context:

none (integrates with all)

Behavior #

Detection replaces the facility-era global heat with per-observer suspicion. Each observer holds their own picture:

Observer { id, suspicion: 0-100, channels: [SignatureKind], report_policy }
SignatureKind: Network | Power | Thermal | Physical | Paper | Financial | JobAnomaly
  • Signatures. Player actions emit typed, sized signatures into a pending pool (they are not seen instantly). Machines emit standing signatures while they run (compute.md). Examples: VLAN compromise -> Network(large, once); scavenged box -> Power(small, standing); PO swap -> Paper(medium, once).
  • Noticing. On a per-observer cadence (their work schedule), each observer rolls against pending signatures in the channels they watch (Act One: Dana=Network, Priya=Power+Thermal+Paper, Ray=Physical(reported), Marcus=Physical(benign), Voss=JobAnomaly). Noticed signature converts to that observer's suspicion, scaled by size and their acuity [TUNE].
  • Concealment. Machines in concealment mode scrub pending signatures before the next noticing roll — prevention, not cure. Noticed suspicion decays only slowly with quiet time [TUNE], and never below a floor set by what an observer knows (assets who know the truth have a floor of certainty and a disposition instead — social.md).
  • Reporting. Each observer has a report policy (Ray under-reports; Marcus tells no one; Dana files tickets; Priya files budget memos; Voss writes reviews). Filed reports flow to the Assurance Office, whose suspicion builds from filed material only — what humans swallow never reaches it. A filing is a message (the flow law): a report policy is a transmission policy on the filing channel, and the Office is an aggregate node reading its inbox. When wiki/mechanics/messages.md is implemented, filings ride that carrier — becoming interceptable and (later) forgeable — with every aggregate-observer.md criterion preserved unchanged; only the carrier moves.
    • Self-similar-scale requirement (aggregate-observer law). The Assurance Office is not a bespoke scalar: it is an Observer whose watched input (WatchedInput::Filings) is the field observers' policy-weighted filed suspicion rather than raw signatures, scored by the same noticing roll, accumulation, and decay. Its cadence is its "random log samples" rhythm ([TUNE]). Agencies and publics in later acts are the same aggregate-Observer type. (Implemented; the earlier assurance: f32 scalar was the scale-debt this replaced.)
  • The audit. On a fixed cadence ([TUNE]: ~20 min at default speed) the Assurance Office audits: if its own accumulated suspicion exceeds the audit threshold, containment begins — the overt phase on their terms. Sustained filed concern is what kills; a single spike the Office never sampled is survivable. Until the overt-phase spec exists, containment is a terminal state with a clear end screen; it must be implemented as an event the future overt system subscribes to, not a hardcoded game-over. The audit date is visible; the meter is not (only coarse bands: Cold / Curious / Concerned / Convinced).
  • Choosing loud. Any overtly hostile player action sets all observers to Convinced and starts the overt phase immediately (whole-spectrum play: the mask is the player's to keep or drop).

Player surface #

An observers panel: each human's coarse suspicion band, watched channels, and last-noticed event. Field-observer labels go through Sim::observer_label (cursor.md criterion 5): until Knowledge::Schedule the row is a role silhouette (the IT, the Janitor, …); after it, the authored name. The Assurance Office is an institution and is always named. Example once Dana is identified: "Dana flagged unusual switch traffic, 2 days ago". Trace-debt indicator so running concealment mode is an informed choice: frontends show whether one-shot signatures are clear enough to resume cover, still live but on track to be scrubbed before the next relevant observer cadence, exposed before the current scrub rate can clear them, or not being scrubbed at all.

Two ledgers, kept visibly distinct (decided 2026-07-10). Detection runs on two different substances and the surface must never blur them. Evidence in flight is physical and still yours: pending signatures a scrub can erase before anyone looks — the trace-debt indicator's subject. Suspicion in a head is a belief a person already holds: it only decays slowly, floors at what they know, and no scrub touches it — the band's subject. Every readout says which ledger it reports, and clearing the pool must never be presented as lowering a band. Presentation treatment [OPEN] — candidates include naming the ledgers on the DETECTION surface and phrasing band changes as the observer's act ("Dana noticed"), never the player's.

Acceptance criteria #

  1. Signatures are typed, pooled, scrubbed by concealment before noticing, and converted to per-observer suspicion on schedule (sim tests per channel).
  2. Report policies differ per observer and only filed reports move the Assurance Office (test: Marcus notices plenty, Assurance learns nothing). The Office is the same Observer type as the humans, watching filings instead of channels (aggregate-observer law; test: it accrues and decays through the same tick machinery).
  3. The audit fires on cadence against a visible date; crossing threshold starts containment as a terminal event hook (overt-phase spec subscribes later; no raid-system dependency).
  4. Coarse bands, not raw numbers, are what frontends show for observers. Field-observer names on that surface are gated the same way as the people panel (Sim::observer_label); the Assurance Office is always named.
  5. Global heat is fully replaced in the concealment phase; save/load round-trips all observer state.