# Insights β€” Dream Mode Consolidated Learnings > Living, de-duplicated knowledge base. Themes, not an append log. Newest evidence strengthens or replaces existing entries. > Opened 2026-10-10 (first Dream Mode run). ## πŸ›οΈ Standing Principles (epistemics & discipline) - **Pre-registration is load-bearing.** For any falsification loop ("what died and why"), kill criteria + cost assumptions must be timestamped *before* the run. Post-hoc autopsies re-import survivorship bias through the writer. Schema must force the field. - **The critic must be a different engine than the proposer of the claim.** Hard-wiring one model (even a strong one) as permanent critic creates correlated blind spots β†’ sycophancy collapse. Rotate roles (planner proposes, reviewer critiques β€” separate profiles count). - **Optimize for honest falsification, not PnL.** Success metric = cleanly-falsified claims per week at bounded cost. PnL is a rare lagging output; chasing it un-disciplines the only durable asset. - **Measurement integrity gates the experiment.** If the instrument is broken (clock skew, unmeasured latency), the run is void β€” fix the instrument *before* running. Refuse to start a clock that would void every result. - **The durable asset is failures-with-autopsies**, not strategies. Wins are published (survivorship bias + marketing); a fee-adjusted record of what died and why is scarce and never has to be re-learned. - **Honest-gap ledger.** Every build report names what's wired, what's offline-only, what remains. Never claim live behavior that hasn't run. - **Name which cost/branch you're invoking before concluding.** E.g. a *taker* fee says nothing about a *maker* edge's viability. - **A known root cause with a cheap fix should not survive the day it was found** β€” diagnose β†’ propose β†’ ask in the same turn; apply on approval. - **A defect in the instrument is not a death of the claim** (strengthened 2026-10-11). When a claim fails because the *spec/test* was wrong, the honest record is `withdrawal (never-tested)` β€” never an autopsy with a cause of death. Filing a death for an unrun claim is the corpus's own survivorship-bias back door. The schema must carry a `never-tested`/`withdrawn` status so a documentation defect can't be written up as evidence of death. - **Durable-run integrity triad** (2026-10-11). Any multi-day/unattended run must: (a) keep its progress counter in the durable store and **replay it on startup** (in-memory `counted` reset β†’ the run can never reach its N, silently); (b) key liveness/stall detection on a **quantity that changes when healthy** (log *file-size growth*, never "last log line unchanged" β€” constant verdict lines make that a false stall); (c) make the recovery action **idempotent and non-leaking** ("confirm zero live before starting one" β€” a restart-on-stall cron that never reaps the prior process compounds the fault it exists to repair). - **A cron's own recovery action is a code path that needs testing.** Treat every self-healing action as a first-class artifact: unit-check the idempotency guard and the resource-lifecycle on the restart path, not just the happy path. - **Read a gate at its registered N.** When a statistical gate (e.g. a one-sided LB>0) prints a verdict before its sample is met, label it *interim, not decisive until N=X* β€” lead with that. A mean and its lower bound move at different speeds (2026-10-11: mean +0.019 while LB βˆ’0.099); an early negative LB is noise, not evidence. ## πŸ› οΈ Technical Notes - **Kalshi fees (verified 2026-10-10):** taker = `round_up(0.07Β·CΒ·PΒ·(1βˆ’P))`, charged only when you take. **Maker fee = 0 on ~12,500 of 12,699 series** (only ~129 series tax resting orders, quarter rate; cancelling free; 14 niche series fee-free). Polymarket **US** is a separate, thinner, full-KYC venue with contested CA status; Kalshi CA is clean (CFTC DCM). - **Headless (`-q`/`--oneshot`) approval gate:** profiles with `approvals.mode` unset default to `manual` β†’ no user β†’ dangerous-pattern commands (`python -c`, `execute_code`, `rm -r`, `kill -9`, heredocs) time out to `BLOCKED`. The `execute_code` fallback is gated too β†’ retry loop that burns context. Fix: `approvals.mode: smart` (+ `command_allowlist` for scoped safe patterns) + tool-loop guardrails (`hard_stop_after: 5`). Cron-safe only after allowlist/config applied. - **Cron/unattended tool limits:** `python -c`, `execute_code`, and heredoc script execution are blocked in unattended (-q) runs unless allowlisted; `write_file` refuses overwrite without a prior read (pagination paradox); `terminal` foreground cap 600s (else promoted to tracked background). - **killcorpus** (`C:\Users\fight\Projects\killcorpus`): paper-only. Spec `KXBTCD-lag-vs-spot` v1.1.1 (taker primary; maker secondary pending fill model). Harness `harness/paper_trader_instrumented.py` β€” instrumented (book_read_ts, ntp_offset_ms, spot_age_ms, realized_slippage), variance gate σ²=0.25, latency gates 1000/500/250 ms, fixed N=967 post-registration. Offline selftest green; live feedβ†’fillβ†’settlement path **wired and proven** (settle-through proof 2026-10-11: 40 signals / 5 trades / 5 settled, clock off). Gitea `Tony_tech/killcorpus` push superseded by Contents-API content-mirror. Reference (read-only, do not edit): `polyterm/paper_trader.py`. **Live eval launched 2026-10-11T16:24:28Z** (REG_TS). Supervision: cron `1da28c73cd5f` (15 m, supervisor) + `c7ea39ffb05a` (1 h, health check). Policy: **hold until N=967**; interim K1 non-actionable; only pre-registered early stops (sustained `measurement_artifact`, variance breach β†’ UNDERPOWERED) may halt. Fixes shipped: `b833e3c` (smoke-arg parser), `45f94a5` (DB replay of `counted` on startup). Gitea `Tony_tech/killcorpus` **content-mirrored via Contents API, no `origin`** (git-level link deliberately held). Schema drift seen once: DB `signals` table lacked `book_read_ts_ms` the writer needs β€” deployed DB and writer must be reconciled at launch. - **Agent-loop roles:** planner=Proposer, reviewer=Critic, builder=Executor, jimmy=Recorder. ## 🧡 Open Threads - Trace-fix (builder/reviewer `approvals.mode: smart` + guardrails + timeout 300) written, unapplied β€” awaiting Tony's approval. See [[../04_projects/trace-review-bot/2026-10-10-trace-analysis-and-fix]]. - killcorpus prereqs **cleared 2026-10-11**: clock fixed (Β±2 ms, was βˆ’284 ms); settlement observed (5 settled); durable runner proven; spec v1.1.1 approved. Eval **live** since 16:24:28Z, accruing toward N=967. Next gate = a valid run at N=967 β†’ first autopsy (kept/killed/parked/inconclusive). Nothing else halts it except the pre-registered early stops. - killcorpus **open items**: git-level link (`origin`) held β€” decide at first autopsy; handoff docs (`docs/handoff-2026-10-11*.md`, `killcorpus-full-2026-10-11.md`) untracked β€” commit/push/delete undecided. - Dream Mode live as of 2026-10-10 (skill + `skill_review.py` + 2 AM cron + `dream/`). Note for 10-11 = second run.