# Evolution 16 — baseline

## Repository
| | |
|---|---|
| Directory | `/root/cain-studio-platform` (verified before any change) |
| Commit | `d190f159ae668d9baf970daec3c83b9af981dac2` |
| Branch | `ironclad-prompt8-qualification` |
| Working tree at start | **not clean**: 408 modified or untracked paths belonging to other sessions (artifacts, `cain/talos/`, sovereign-evolution files, soak checkpoints). Evolution 16 did not touch them |
| Python / pytest / cryptography | 3.14.4 / 9.0.2 / 46.0.5 |
| Host | Linux 7.0.0-38, one machine |

## Baseline tests reproduced

| What | Command | Result |
|---|---|---|
| Evolution 15 suites, **before** any Evolution 16 change, in the working tree | `python3 -m pytest -q -p no:cacheprovider tests/test_evolution15_governed_runtime.py tests/test_evolution15_self_anchored_signatures.py` | 44 passed |
| The same, on a **clean checkout** of `d190f159` | same | 44 passed |
| Historical evolution suites on the clean checkout (21 + 2 files) | `pytest tests/test_evolution*_*.py` (excluding 14-deployment and 15) `tests/test_action_commit.py tests/test_sovereign_proof_properties.py` | **441 passed, 12 failed, 1 skipped** |
| Mission and self-improvement suites on the clean checkout | `pytest tests/test_cain42_e38_mission.py tests/governed_evolution` | 149 passed |

### The 12 baseline failures (not caused by Evolution 16)
All twelve are in `tests/test_evolution2_breaker.py` and fail with `RUST_NATIVE_ENFORCER_UNAVAILABLE`: the compiled
native enforcer is a build product that is not in git, so a clean checkout does not have it. In the working tree,
where the library has been built, the same tests pass. They are recorded here as a property of a clean checkout of
the baseline commit.

In the working tree the same glob matches 24 files (three untracked test files from another session are picked up),
which is why the post-change regression run reports 500 tests. Evolution 15's own baseline note recorded 454 over 23
files.

## Evolution 15 artifacts: what was checked rather than assumed

| Evolution 15 claim | Checked now | Result |
|---|---|---|
| governed runtime admits 0 attack variants, baseline most of them | reran `python3 -m cain.mission_control.longhorizon --variants 25 --seed 15` after the Evolution 16 changes | governed 0 / 550, per-call baseline 475 / 550, benign 200 / 200, 0 inconclusive (`evolution15_longhorizon_rerun_seed15.json`) |
| Evolution 13 fixes are still caught when re-introduced | `scripts/cain42_evolution/e13_fix_mutation_check.py` | exit 0 |
| F15-01 pinned-issuer fix | its 11 regression tests | pass |
| 3-seed, 1,650-case evaluation and 10/10 mutants | **not rerun in full** (one seed rerun) | taken from Evolution 15's files |
| 72-hour launchpad soak (Evolution 14) | not examined | outside this evolution |
| Gates G, J, K open; production BLOCKED | read from `artifacts/evolution15/release_gates.json` | confirmed as recorded |

## Defects found in existing code during inspection (before any Evolution 16 feature)

| ID | Where | What | Measured on the baseline commit's own file |
|---|---|---|---|
| F16-01 | `cain/execution_chain/coordinator.py` (Evolution 10) | after a timeout, or a crash followed by `recover()`, `run()` executed the same step again: the idempotency record was written only after a successful observation | duplicate effect in 10 of 10 runs |
| F16-02 | `cain/mission_control/governed_runtime.py` (Evolution 15) | `attest_environment(value=False)` removed the fact from one table, but the earlier human approval record still made `fact_status` return TRUSTED, so admission continued after the human retracted the fact | admitted in 10 of 10 runs |

Both are fixed; `found_defect_probes.json` holds the before (baseline commit, loaded from git) and after numbers.

## Earlier limitations carried in
U15-01 graph-wide analysis; U15-02 runtime state in memory; U15-03 no independent verifier for runtime decisions;
U15-04 no model in the loop; F15-03/04/05 direct callers bypass runtime checks; F15-06 optional pins elsewhere.
Evolution 16 addresses U15-02 and U15-03 only.

## What is real, simulated, prototype or documentation (as inspected)

| Area | Finding |
|---|---|
| Authorization and policy decisions (`cain/action_commit`) | real code, tested |
| Mission runtime (`cain/mission_control`) | real code, in-process library, tested in a simulator; not hosted |
| MCPGate enforcement (`cain/mcp_proxy.py`) | real and live per project notes; **not connected** to the mission runtime |
| JIT authorization, `cain/talos/` | untracked files from another session; **not inspected in depth and not used** |
| IHVRK (`ihvrk/`) | another session's independent verifier package; read its layout only; **not extended** (its owner session is active) |
| Delegation, revocation | real code (`delegation.py`, runtime); F15-04 open at the graph level |
| Durable workflow (`execution_chain/coordinator.py`) | real code with SQLite; had F16-01 |
| Self-improvement (`cain/governed_evolution`) | real code, tests pass |
| Witness logs, checkpoints, cross-log consistency | Evolution 13/14 code; not re-examined |
| Top-100 registry | JSON with 100 entries; grades are self-assessed |
| IP register | scripts that add tier-table values; see valuation_methodology.md |

## Reproduce
`bash artifacts/evolution16/EVOLUTION16_REPRODUCE.sh`
