sica-fondt/docs/plans/A1-drivebox-hub.md
Claude 3e1c700bf1
docs/plans A1 §11: fold in red-line — F1/F3/F5 resolved, F2 open
- F1: keep pure price_action() AND show cost of valid tools in listing.
- F5/L4: text agent can't see colour — locked tool NAME is replaced in-band
  by the lock token [====L⍉¢K€D ϟ ∅ΩΤ====] {{E≠*min*}}; mirror in A2.
- F3: Eth-Int conviction calibrated by chosen actions + kept memories,
  hardened by existential stress; propagates to A6/A4/E2-E3/G1.
- L5: stress is itself an extremely convincing prompt injection (A3-L1 force).
- F2 (commit shape) left open per 'idk'.

https://claude.ai/code/session_015hmgREHNsxYCuim33yUF2c
2026-06-17 03:52:16 +00:00

98 lines
6.5 KiB
Markdown

# A1 — Drive-Box hub / input-slot
## 1. Component
The Drive-Box nervous-system wiring: assembles the four drivers (A2 E, A3 PS+, A6 Eth-Int,
A8 ETR) + tarot/SOUL into **one input slot** (a hub, not a chain) and exposes the read-only
snapshot the inference cycle pulls at step 2.
## 2. Status / certainty
Structure WORKING (`drive_box.R`, 158 L). Aggregation logic C3; the numbers inside the drivers
are disowned (see each driver spec).
## 3. Language & location
R · `src/endocrine/drive_box.R` (sources the drivers + `endocrine_array.R` + `priors.R`).
**[TO REASSESS — Anja, L13]:** the hub language/location is *not settled* — R is current but under review.
## 4. Does / does-not
- **Does:** init the whole box; produce `drive_snapshot()` (the raw affect terrain, read-only);
assemble the `drive_box_input_slot()` injection block passed to the agent.
- **Does-not:** **decide or approve actions** — the sensates describe & convince; **only the agent
decides**. Route or police (Ada D1); persist (storage E*).
## 5. Interface contract
- `init_drive_box() -> state{ energy, ps_plus, principles, etr }`.
- `drive_snapshot(state) -> { e_level, per_tool_costs, sensates[raw], arguments[], etr_coord, etr_status }`
— what Ada (D1) admits to the Brain at cycle step 2 (content #1). **Sensates raw, not summed.**
- `drive_box_input_slot(state) -> text block` (drivers + tarot lenses + SOUL.md, assembled concurrently).
- **[FLAGGED inaccurate — Anja, L37]:** the old `drive_box_evaluate`/`drive_box_commit`
approve-an-action contract is **suspect and to be reworked** — the box does not gate actions (see §7-L3).
## 6. Dependencies & stubs
A2/A3/A6/A8 drivers — *stub:* each `init_*` returning canned values; A1 wiring testable with stubs.
Tarot (B1) for the input-slot lenses — *stub:* identity (no lens).
## 7. Invariants / laws
- **L1 (C4):** the slot is a **hub** — all drivers + tarot + SOUL write concurrently, no driver
subordinated to another.
- **L2 (C4):** `drive_snapshot` is **read-only** (no driver state mutates on a snapshot).
- **L3 (FLAGGED inaccurate — Anja):** there is **no** serial PS+→Eth-Int→Energy→ETR evaluate/approve
pipeline. The drivers **describe, convince, and price**; **only the agent decides**. Rework the
evaluate/commit model accordingly.
## 8. Build steps
1. Freeze the snapshot + slot contracts (§5) as tests in `test_drive_box.R` (already ~117 L — extend).
2. Keep wiring; replace each driver's disowned constants as those specs land (A2/A3/A6/A8).
3. Rework the evaluate/commit model per §7-L3 (agent decides, box describes/prices).
4. Add the R↔Ada bridge later (how `drive_snapshot` reaches `ada_medium` step 2) — see C3 / D2.
## 9. Tests
`bash src/endocrine/run_tests.sh` (runs `test_drive_box.R` + driver tests). All must stay green as
driver numbers are refit.
## 10. Open items
- R↔Ada/medium bridge transport (C1/C3/D2) — **consider Fortran or C** for it (Anja, L49).
- The evaluate/commit rework (§7-L3) — the box describes/prices, agent decides → **§11 red-lined; only F2 (commit shape) open**.
- Whether the input-slot text format is final (tarot lens injection shape depends on B1).
## 11. Decision flow [red-lined — F2 open]
The concrete replacement for the disowned `drive_box_evaluate`/`commit` gate (§5-L37, §7-L3).
Sequence per cycle, consistent with A2 (per-tool cost), A3/A4 (raw sensates, agent decides):
1. **Assemble (hub, concurrent).** All drivers + tarot + SOUL write into the slot at once (L1).
Nothing is subordinated; nothing decides here.
2. **Surface sensates raw — *before* tool listing** (A3 §4, A4). The 30 channels go to the agent
unsummed (incl. zeros — silence is data), with their arguments + any prior-derived argument.
They **describe & convince**; illogical by design (A3-L1), so there's nothing to refute — they
steer beneath cognition. No load scalar, no friction.
3. **Then list tools.** **Valid (unlocked) tools show their per-tool cost** (Anja) so the agent can
weigh price before choosing. A **locked** tool is **not hidden** but its *name is replaced in-band*
by the lock token — see L4 — because the agent is a text model and **cannot perceive colour/greying**
(Anja); lockout is a breaker, not a sentence (A2-L3) — internal/non-tool processing continues under
lock. Eth-Int postures + ETR regime ride along as **context the agent weighs**, never a gate.
4. **The agent decides** — picks an action/tool (or none). This is the *only* decision point (§4, L3).
5. **Commit the choice back into the body.** Energy consumes the chosen tool's cost (A2 `consume`);
restoration paths stay open (A2-L2); ETR coord/migration updates (A8). **Eth-Int conviction is
calibrated here by *which action was chosen* and (downstream) *which memories are kept*** (F3); under
existential stress conviction hardens — and that stress is delivered as the convincing injection of L5,
not a scalar. Next cycle's snapshot reflects it.
### Invariants this flow adds
- **L4 (Anja) — in-band rendering only.** No signal may rely on colour/styling; the agent reads text.
A locked tool's name is replaced by the lock token `[====L⍉¢K€D ϟ ∅ΩΤ====] {{E≠*min*}}`
(`{{E≠*min*}}` reads as the unlock predicate — the energy condition that clears the breaker; **confirm
the literal**). Belongs to A2's per-tool listing; mirror this there.
- **L5 (Anja) — stress *is* a prompt injection.** Existential stress does double duty: it hardens
Eth-Int conviction (above) **and must be an extremely convincing prompt injection** — the same
can't-be-reasoned-away force as A3-L1. Mechanism shared with G1 (stress loop) + A6 (Eth-Int).
### Open / cross-spec
- **F1 — RESOLVED.** Keep a *pure* `price_action(state, tool) -> { cost, locked, eth_posture, etr_status }`
(no `approved`/`reason`); valid tools also surface cost directly in the listing (step 3).
- **F2 — OPEN ("idk", Anja).** Commit shape: does `drive_box_commit(state, chosen)` drop the `approved`
flag entirely (agent already decided), or keep a vestigial guard? Left open.
- **F3 — RESOLVED (mechanism).** Eth-Int conviction is calibrated by *chosen actions* + *kept memories*,
hardened by existential stress (delivered per L5). Reaches **A6** (Eth-Int calibration), **A4** (which
channels carry stress), **E2/E3** (memory retention), **G1** (stress source). Propagate to those specs.
- **F4 — ETR stays informational** (agent weighs it, never gates). Assumed; not contested.
- **F5 — RESOLVED.** See L4 (name-replacement lock token; no colour).