# Next Session Entry — α-6 Phase 1 Ready

> **Status**: cycle pause point — 52 PRs landed (#608 → #661).
> α-5 closed (T0 evidence + post-closure self-audit). α-6
> Engineering pre 5/5 complete. **Phase 1 measurement is the next
> launchable work** (~5.5h compute, $0).
>
> **Pause datetime**: 2026-06-01 01:xx (Korean local, post-T1
> timeout-cascade post-mortem)
> **Resume entry point**: read this file → confirm Ollama healthy
> → execute Section 4 first command.

---

## 0. Where the project is

- **Version**: v0.4.1 (latest minted DOI). α-5 cycle work is
  infrastructure / methodology; no version bump.
- **Active theme**: α-6 cycle Phase 1 — *"does each JAMES sector
  add value vs vanilla gemma4?"*
- **52 PRs this session** (#608 → #661). Cumulative JAMES code
  change against α-5 measurement debt: **0 lines**.
- **7 wrong-fix-averted** total this cycle.

---

## 1. What just landed in this session

Categorized in `reports/research-runs/alpha-5-cycle-pr-index.md`.
Highest-leverage block for the next session:

| PR | Sector | Flag | Status |
|---|---|---|---|
| #657 | S4 Citation | `JAMES_DISABLE_SOURCES_FIELD` | ✅ landed + tested |
| #658 | S2 Graph | `JAMES_DISABLE_GRAPH` | ✅ landed + tested |
| #659 | S1 RAG | `JAMES_DISABLE_RAG_RETRIEVAL` | ✅ landed + tested |
| #660 | S5 Abstention | `JAMES_DISABLE_ABSTENTION` | ✅ landed + tested |
| #661 | S6 Cognitive | `JAMES_DISABLE_COGNITIVE_STAGES` | ✅ landed + tested |

**21/21 sector flag contract tests green.** All flags
disable-polarity (default OFF = production behaviour byte-
identical). Production unaffected.

---

## 2. First actions next session (in order)

### Action 0 — Ollama healthcheck (UUU lesson)

T1 hung for ~6.7h because Ollama degraded after T0's 6h sustained
load. Restart Ollama before any matrix launch:

```powershell
# Windows PowerShell
Restart-Service Ollama
ollama list  # confirm responses are snappy
```

Optional warm-up: run one query at production tier and confirm
latency in the ~60-70s range (matches T0 cell L1 average).

### Action 1 — Matrix runner `--sector-cells` extension (~1h code)

The 5 sector flags exist as env-flag gates. The matrix runner
needs to wire them into cell env blocks. Two design choices:

**Option A** — Add `_SECTOR_CELL_ENVS` dict to
`scripts/qvt_ablation_matrix.py` mapping cell names to flag combos:

```python
_SECTOR_CELL_ENVS: Dict[str, Dict[str, str]] = {
    "C_minus": {
        "JAMES_DISABLE_RAG_RETRIEVAL": "1",
        "JAMES_DISABLE_GRAPH": "1",
        "JAMES_DISABLE_SOURCES_FIELD": "1",
        "JAMES_DISABLE_ABSTENTION": "1",
        "JAMES_DISABLE_COGNITIVE_STAGES": "1",
    },
    "C_rag-basic": {
        # S1 ON (default), all other sectors OFF
        "JAMES_DISABLE_GRAPH": "1",
        "JAMES_DISABLE_SOURCES_FIELD": "1",
        "JAMES_DISABLE_ABSTENTION": "1",
        "JAMES_DISABLE_COGNITIVE_STAGES": "1",
    },
    "C_rag-cited": {
        # S1 + S4 ON
        "JAMES_DISABLE_GRAPH": "1",
        "JAMES_DISABLE_ABSTENTION": "1",
        "JAMES_DISABLE_COGNITIVE_STAGES": "1",
    },
    "C_rag-graph": {
        # S1 + S2 + S3 + S4 ON
        "JAMES_DISABLE_ABSTENTION": "1",
        "JAMES_DISABLE_COGNITIVE_STAGES": "1",
    },
    # C_rag-full = α-5 L1 (no sectors disabled) -- already measured
    # C_rag-routed = α-5 L5 -- already measured
}
```

Add `--sector-cells` CLI flag that takes a comma-separated list
and dispatches to this map instead of `--rows`.

**Option B** — Reuse `--rows L1` with a sidecar `--sectors
C_minus,C_rag-basic` flag that takes precedence over the row
ENV. Smaller surface change.

**Recommended**: Option A (sector cells deserve their own
schema). Allocate ~1h code + 30 min tests.

### Action 2 — α-6 Phase 1 launch (~5.5h compute)

Once Action 1 lands:

```powershell
$env:JAMES_WORKSPACE = "./workspaces/hotpot_eval"
$env:PYTHONIOENCODING = "utf-8"
$env:PYTHONUNBUFFERED = "1"

python -u scripts/qvt_ablation_matrix.py `
    --tiers M_M --suite multihop_rag --n-runs 1 `
    --sector-cells C_minus,C_rag-basic,C_rag-graph
```

3 new cells × ~110 min = ~5.5h. Background run; monitor for
timeouts (UUU lesson — kill early if every query hits 120s).

### Action 3 — Phase 1 analysis (~30 min post-completion)

Post-cells:

```powershell
# Rescore (handles any bench-runner glitches per QQ #638 pattern)
python scripts/qvt_rescore_all_cells.py `
    --workspace ./workspaces/hotpot_eval `
    --suite multihop_rag

# Render report with sector cells
python scripts/qvt_ablation_matrix.py --render-report

# Per-layer intent verdict review (NNN+OOO #652 schema)
# Each cell's verdict_per_layer block tells the operator which
# sector's design intent was met vs not.
```

Expected publishable Δ:

| Comparison | Expected sign |
|---|---|
| C_minus (pure gemma4) vs C_rag-basic (+RAG) | quality ↑↑ (retrieval helps a lot) |
| C_rag-basic (+RAG) vs C_rag-cited (+citation) | path coverage ↑, others flat |
| C_rag-cited vs C_rag-graph (+graph) | graded ↑ on multi-hop, path flat |
| C_rag-graph vs C_rag-full = α-5 L1 (+S5 abst + S6 cog) | abst_f1 ↑, latency ↑ |

These are predictions; the measurement validates / surprises.

---

## 3. What's deferred (DON'T touch this session)

| Track | Why deferred | Trigger to resume |
|---|---|---|
| AUTO_ROUTER multi-tier engineering (α-6 §5.5) | Phase 4+ blocker | Phase 1 verdict has signal worth scaling |
| T1 L3/L4 re-measurement (timeout cascade post-mortem #656) | $0 cost ablation cells (α-6) supersede it | only if α-6 verdicts hint at need |
| DOI bump | Vehicle A/C conflict (SSS #655) | T3 ship + mid-June joint piece framing |
| Joint piece prep | Lane C HOLD | 6/6+ Ali resume |
| MultiHop-RAG paper baseline reproduction (EEE #651) | independent, anchor for α-6 | runnable in parallel with Phase 1 |

---

## 4. Critical gotchas (don't repeat past sessions)

1. **Ollama healthcheck before matrix launch** — UUU #656 lesson.
   Otherwise 6+h compute wasted on timeout cascade.
2. **Apply 4-step rule when any axis reads 0 / saturated** —
   `memory/feedback_oracle_phrase_artifacts.md` 확장 3. The 7
   wrong-fix-averted in this cycle all came from applying it
   immediately, not after the matrix finished.
3. **Per-layer intent verdict, not uniform 5-axis** — CLAUDE.md
   rule 2 layer-intent extension (NNN+OOO #652). When a cell
   touches one of the routing/cognitive layers, score the Quality
   Delta Card against that layer's design-intent axes.
4. **DON'T frame methodology as Replayable RAG validation** —
   position guard from `feedback_jameses_positioning_replayable_rag`
   §"정정 2026-05-31". Mother-platform framing primary.
5. **`fix` label exemption for measurement-side PRs** — CLAUDE.md
   rule 2 `fix` exemption. PRs correcting oracle / fixture / bench
   / matrix-runner wiring state `Quality delta: exempt (label:
   fix)`.

---

## 5. Memory entries to read on entry

- `mechanism_layer_intent_axis_alignment` — per-layer intent
  axes table + measurement prerequisites
- `feedback_oracle_phrase_artifacts` — 4-step rule (확장 1+2+3) +
  6 corrections cycle log + new "사건 7" T1 timeout
- `feedback_jameses_positioning_replayable_rag` (정정 2026-05-31)
  — mother framing primary
- `feedback_intent_vehicle_gap_collective_archival` — Vehicle A/C
  separation, walk-back pattern
- `project_state` — high-level current state

---

## 6. Quick orientation queries

```powershell
# What's in flight?
git log --oneline -20

# What changed since last session?
git diff HEAD~52..HEAD --stat

# Cycle index for navigation
cat reports/research-runs/alpha-5-cycle-pr-index.md

# α-6 design (sector + LLM × matrix)
cat docs/design/v0.4-alpha-6-sector-llm-ablation-matrix.md

# This handover (you're reading it)
cat docs/handovers/v0.4-next-session-entry-2026-06-01.md
```

---

## 7. Done condition for the next session

A clean stop point is when:

- [ ] Action 0 (Ollama healthy) confirmed
- [ ] Action 1 (matrix runner `--sector-cells`) landed + tested
- [ ] Action 2 (Phase 1 launch) running in background
- [ ] If results arrive: Action 3 (analysis) + closure PR

If Action 1 takes longer than expected or the Phase 1 launch hits
timeouts (per Ollama state), the right stop is post-Action-1 and
queue Phase 1 for the session after.

---

## 8. References (single source of truth)

- α-6 design: `docs/design/v0.4-alpha-6-sector-llm-ablation-matrix.md`
- α-6 engineering pre sequence: `docs/design/v0.4-alpha-6-engineering-pre-pr-sequence.md`
- Cycle PR index: `reports/research-runs/alpha-5-cycle-pr-index.md`
- T1 timeout post-mortem: `reports/research-runs/t1-timeout-cascade-postmortem-2026-06-01.md`
- DOI defer: `docs/handovers/v0.4-doi-bump-defer-2026-05-31.md`
- 4-step rule: `memory/feedback_oracle_phrase_artifacts.md`
- Layer-intent mechanism: `memory/mechanism_layer_intent_axis_alignment.md`
- CLAUDE.md rule 2 (PR gate): `CLAUDE.md` §"Critical rules for this session"
