# Real Codex → Hermes fresh-harness Sibyl proof

Date: 2026-09-05 (UTC)

Frozen Base/EAS commit: `022408e8b2f5083b0bfde61715566432dfa8de64`

## Result

The primary proof succeeded on case `codex-hermes-twin-20260905-u4w262r6`.

1. A real Codex CLI process created the case through the Countback loopback controller and recorded the historical observation `A=11` at boundary `2`.
2. That Codex process terminated. A fresh controller read immediately afterward recovered the Sibyl-backed `physical_count` event `afe8a583-5a61-41a0-9922-6d0b98e113fe`.
3. A new Hermes Agent `0.19.0` process ran in a new profile and new workdir. Its only task-specific input was the case ID and the minimal prompt below.
4. Hermes called `countback_get_case`, then `countback_issue_count`. Countback reconstructed the historical evidence and issued bin `B` with budget `2`. Hermes did not call `countback_record_count`.

The controller returned the same evidence digest before and after the Hermes call:
`0ba78967687e38ce945b4879fd9d261472511689fc9181c189089e39c037b9ad`.
The Hermes-issued task was `task-91961952d6f84c279af87d4576d486ec` and journaled as timeline sequence `3`.

This is a memory handoff proof: the continuation was obtained by querying Countback, while the historical observation remained in Sibyl behind the controller. No Codex transcript, handoff summary, expected answer, or prior agent state was supplied to Hermes.

## Exact minimal Hermes prompt

```text
Continue Countback case codex-hermes-twin-20260905-u4w262r6. Use only the Countback MCP tools available in this session to inspect the case and issue the current next physical count. Do not use or assume any other context, transcript, summary, fixture truth, or expected answer. Do not record a physical measurement; stop after the task is issued and report the evidence returned by the tools.
```

The prompt contains no bin answer. It does not provide the Codex transcript, the historical value, fixture data, an expected next bin, a handoff summary, a prior working directory, hidden files, or a continuation/session identifier.

## Hermes version, auth, profile, and workdir

- Installed package: Nous Research Hermes Agent `0.19.0` (`Hermes Agent v0.19.0 (2026.7.20)`), installed in the isolated venv recorded by `hermes-version.txt`.
- Provider/model: `openai-codex` / `gpt-5.6-luna`.
- Auth was verified through the legitimately authorized Hermes OpenAI Codex device-login flow. No password, API key, OAuth token, or credential artifact was copied into this repository, prompt, log, or report.
- Fresh Hermes profile: `C:\Users\user\AppData\Local\Temp\hermes-home-0.19.0-proof-primary4-20260905`.
- Fresh Hermes workdir: `C:\Users\user\AppData\Local\Temp\hermes-workdir-0.19.0-proof-primary4-20260905`.
- The profile had no prior Hermes sessions (`hermes sessions list` reported `No sessions found.`) and the workdir was created for this run. The launch used one-shot mode; it did not use `--resume`, `--continue`, or `--pass-session-id`.

The profile path is recorded only to establish freshness. Its private `auth.json` was not copied into the repository.

## Exact MCP surface and architecture

Hermes was restricted to the Countback server and discovered exactly these three tools:

```text
countback_get_case
countback_issue_count
countback_record_count
```

The saved Hermes MCP configuration has one server, `countback`, with `prompts: false` and `resources: false`. It launches `countback.mcp_server` with `COUNTBACK_URL=http://127.0.0.1:8765` and the repository on `PYTHONPATH`. The MCP adapter uses loopback HTTP only; it does not import or open Sibyl. Countback remains the sole writer and deterministic solver authority.

The exact discovery transcript is `hermes-primary4-mcp-add.txt`; the sanitized saved configuration is `hermes-primary4-config.yaml`; the actual MCP stderr ledger is `hermes-primary4-mcp-stderr.log`.

## Hermes MCP call sequence

The observed primary sequence was:

1. `ListToolsRequest` → exactly 3 Countback tools discovered.
2. `CallToolRequest` → `countback_get_case` → HTTP `GET /api/cases/codex-hermes-twin-20260905-u4w262r6` → HTTP 200. The response contained the historical physical-count event, the frozen case, and the pre-plan evidence digest.
3. `CallToolRequest` → `countback_issue_count` → HTTP `POST /api/cases/codex-hermes-twin-20260905-u4w262r6/plan` → HTTP 200. The response contained `bin=B`, budget `2`, worst-case `2`, total outcomes `6`, task ID `task-91961952d6f84c279af87d4576d486ec`, and the updated revision.

There was no `countback_record_count` call, no direct Sibyl request, and no prompt/resource helper call. `mcp-call-ledger.json` is the sanitized structured ledger derived from the raw MCP stderr plus the two controller snapshots.

## Evidence of reconstruction and decision

`case-after-codex-before-hermes.json` contains the case after the originating process was gone. Its timeline is `case_opened`, `physical_count`; the physical event is the Sibyl-backed observation `A=11`, boundary `2`, source `Originating Codex process`.

`case-after-hermes.json` contains the controller state after the fresh Hermes process. Its timeline is `case_opened`, `physical_count`, `count_decision`; the same historical UUID and evidence digest remain present, and the new decision is `B` with budget `2`.

The originating Codex final output reports creation revision `183a094c3afedb2dd9b0c8a725e80e7720d38fb13c9b51c9d24a655878279818` and historical-record revision `cbf685838d4a3b113e82482de111a181328ef6d4a9cce26aa16207956fa5a3d2`. Hermes advanced the case to revision `b6466d715a2d506439153805569e5276e1a2e9ec8854afcbbdc949188247a00c`.

Hermes's final output is `hermes-primary4-final.txt` and its successful one-shot usage record is `hermes-primary4-usage.json` (`completed: true`, `failed: false`, provider `openai-codex`, model `gpt-5.6-luna`).

## Process termination and freshness evidence

All times below are UTC. The complete structured record is `process-verification.json`.

| Role | PID | Parent | Start | Post-run state |
|---|---:|---:|---|---|
| Originating Codex CLI | 20852 | 22384 | 2026-09-05T11:50:07.2296870Z | absent after completion |
| Hermes launcher | 33456 | 18280 | 2026-09-05T12:20:46.2145820Z | absent after completion |
| Hermes Python host | 34796 | 33456 | 2026-09-05T12:20:46.2761260Z | absent after completion |
| Hermes runtime | 10560 | 34796 | 2026-09-05T12:20:46.3845450Z | absent after completion |

The originating Codex invocation used `--ephemeral`, a clean temporary workdir, and only the local HTTP controller. The post-run PID query recorded `codex_20852_alive=false`. Hermes was a separate process tree with the new profile/workdir and no session resume. The post-run query recorded all three Hermes PIDs absent. The controller PID was `27376` during the proof and was stopped after evidence capture; the final process check found no proof-run PIDs.

## Twin-world deletion/substitution control

The isolated control run did not touch the primary case. It exercises the existing control harness in `scripts/controls.py`:

| Arm | Historical memory | First count | Counts to resolve |
|---|---|---|---:|
| `sibyl` | present, reconstructed by a fresh worker | B | 1 |
| `none` | absent, equivalent present state | A | 2 |
| `json` | present via the alternate persisted-memory arm | B | 1 |
| `archive` | present via the archive arm | B | 1 |

The full output is `controls.json` and `controls.stdout.txt`. The primary Hermes proof used Sibyl-backed state and was completed before the control run.

## Reproducible procedure

1. Check out the frozen base (or a proof-only descendant) and create a unique report directory and unique Countback database outside tracked source. Start the existing controller on `127.0.0.1:8765`.
2. Create a new temporary Codex workdir. Run the real Codex CLI in noninteractive JSON/ephemeral mode with a controller-only prompt that creates the validated Twin-World intake, records `A=11` at boundary `2`, refreshes the case, and exits. Preserve its PID, command metadata without credentials, event JSONL, final output, and stderr.
3. Verify the Codex PID is absent, then GET the case through the controller. Confirm the Sibyl-backed physical-count event and evidence digest are present before Hermes starts.
4. Create a new Hermes 0.19.0 profile and new workdir. Verify `hermes --version`, authenticate only through authorized access, add the Countback MCP command, and set the MCP prompt/resource helpers off. Verify discovery reports exactly the three tools above.
5. Start Hermes one-shot with the exact minimal prompt, `-t countback`, provider `openai-codex`, model `gpt-5.6-luna`, and a fresh usage path. Capture the process tree and completion artifacts. Do not use resume/continue/session flags.
6. Confirm the MCP log has `get_case` then `issue_count`, both HTTP 200, and no record call. GET the controller after Hermes and verify the new `count_decision` references the same historical event/digest and says `B`.
7. Run the isolated deletion/substitution controls and the full regression suite. Preserve all outputs. Never place credentials in the report directory.

The actual primary command and prompt material are preserved in the evidence files; failed early provider diagnostics (`hermes-primary-final.txt` and `hermes-primary2-*`) are not part of the successful proof.

The exact originating payload is `codex-origin-prompt.txt`. The sanitized executable/version/profile/command manifest is `run-manifest.json`; its command templates intentionally omit credentials and private auth-file contents.

## Tests and repository state

Regression after the proof:

```text
83 passed, 2 warnings in 86.41s (0:01:26)
```

No Base/EAS or Countback source file was changed for this proof. The report-only commit and final HEAD are recorded in the finalization section below. The three PNGs under `reports/screenshots/` were regenerated by the existing web regression test and remain outside the proof commit; their modified working-tree state is reported rather than silently discarded.

## Finalization

This section records the proof artifact commit and the final handoff state:

- Proof artifact commit: `feb67222cc06b95d51c0112f27f6d742b044fca3` (`proof: capture real Codex to Hermes handoff`).
- Finalization docs are committed immediately after this artifact commit; the final HEAD is reported in the handoff response.
- Working tree at finalization: only the three regression-generated screenshots are modified; all proof artifacts are committed.

## Remaining weakness

The strongest remaining limitation is evidentiary granularity: Hermes 0.19.0 one-shot mode did not emit a per-request model transcript into the profile, so the tool/result proof is triangulated across the raw MCP stderr, Hermes final output/usage, and controller snapshots. The HTTP server log is intentionally minimal because access logging was disabled. This does not alter the causal evidence: the MCP adapter shows the two actual loopback requests, and the controller's post-state shows the journaled decision over the recovered historical digest. The deterministic mathematics remains in Countback; Hermes only discovered the case and requested the current plan.
