Context
Leaf B of Epic #12679's implementation decomposition (map: https://github.com/neomjs/neo/issues/12679#issuecomment-4862079789). Filed pre-Accepted per ADR 0005 §2.3 for planning visibility. Sequenced after Leaf A (#14433 — the storage substrate this lane writes into).
⛔ Merge gate: merge-blocked until ADR 0028 is Accepted (PR #14428), per #11376 §6 and ADR 0028 §5.
The Problem
The durable tiers do not exist: no lane aggregates sessions (L1) and days (L2) into the temporal-summary collection, and the deterministic velocity fields (the substrate's answer to the "150+ PRs a week" V-B-A failure class) have no producer.
The Architectural Reality
Bound by ADR 0028 (re-verify Accepted at claim):
- §2.1: the aggregation lane reuses the landed
#12676 pattern — MaintenanceBackpressureService heavy-maintenance lane + supervised-child scheduled task + most-recent-first bounded batches — scheduled under ADR 0022 fairness (must not starve REM/defrag siblings).
- §2.4: L1/L2 records carry the deterministic velocity fields (
mergedPrs, devCommits, sessionsPerAgent, highImpactSessions, adrsLanded, sandboxesGraduated), each bound to its named source substrate at implementation; prose is never the source of truth. Velocity fields are folded into this leaf (not separate) because they ship with the aggregation write path — a separate metrics leaf would re-open the same files (fold rationale in the map).
- §2.6: per-agent partitions + one unified track with attribution.
- §2.3 boundary: writes go through the Leaf-A schema (
SUMMARY_DAILY labels via this deterministic lane only — never extractor-prompt widening).
- Retention/versioning policy: owned here, within the
version metadata field.
- New
.mjs placement via structural-pre-flight at claim (likely ai/daemons/ scheduled-task + ai/services/ territory; contract stays directory-agnostic).
The Fix
One PR: the L1 (per-session) + L2 (daily) aggregation lane writing collection records + SUMMARY_DAILY labels, velocity fields populated from named sources, retention/versioning policy, scheduled under the backpressure/fairness substrate. No L3–L5 logic (Leaf C), no consumer surface.
Contract Ledger Matrix
| Target Surface |
Source of Authority |
Proposed Behavior |
Fallback |
Docs |
Evidence |
| Aggregation lane (new scheduled task + service logic) |
ADR 0028 §2.1 + ADR 0022 + landed #12676 pattern |
Bounded, most-recent-first, backpressure-leased L1/L2 writes |
No durable tiers (status quo) |
ADR 0028 §2.1 |
Task registered + lease behavior tested |
L1/L2 records in temporal-summary |
ADR 0028 §2.3/§2.4/§2.6 (via Leaf A schema) |
Five-field metadata + velocity fields + partition keys |
— |
ADR 0028 §2.4 table |
Field-source binding asserted per field |
| Retention/versioning |
ADR 0028 §4 (negative/handoffs) |
Policy defined within version; bounded growth |
Unbounded growth (rejected) |
This ticket → impl docs |
Policy tests |
Decision Record impact
depends-on ADR 0028 (Accepted-gate) · aligned-with ADR 0022 (scheduling fairness) · consumes Leaf A (#14433) schema.
Acceptance Criteria
Out of Scope
- L3–L5 synthesis (Leaf C). Consumer surfaces. Schema creation (Leaf A). Backfill of deep history (a follow-up policy decision once the lane is proven forward-running).
Avoided Traps
- Durable compression above L2 — rejected (ADR 0028 anti-anchor; photocopy cascade).
- A universal PR impact score — rejected (§2.5; named sources only).
- Separate velocity-metrics leaf — rejected (fold rationale above).
- New cron per tier×partition — rejected (the L3–L5-dynamic shape exists precisely to avoid it).
Related
Parent: #12679 (native link on file). Authority: ADR 0028 (PR #14428). Depends-on: #14433 (Leaf A). Sibling: Leaf C (L3–L5 synthesis). Pattern source: PR #12676 (merged 2026-06-07).
Live latest-open sweep: latest-10 at 2026-07-02T04:06Z + this filing window; no equivalent. A2A sweep: all-states at 04:06Z; no competing claim. Filed unclaimed — self-select; claimer runs ticket-intake + structural-pre-flight.
Origin Session ID: 2251c81c-1446-4723-86b3-479322bbcc95
Retrieval Hint: "temporal pyramid Leaf B L1 L2 durable aggregation velocity fields backpressure"
Context
Leaf B of Epic #12679's implementation decomposition (map: https://github.com/neomjs/neo/issues/12679#issuecomment-4862079789). Filed pre-
Acceptedper ADR 0005 §2.3 for planning visibility. Sequenced after Leaf A (#14433— the storage substrate this lane writes into).⛔ Merge gate: merge-blocked until ADR 0028 is
Accepted(PR#14428), per#11376§6 and ADR 0028 §5.The Problem
The durable tiers do not exist: no lane aggregates sessions (L1) and days (L2) into the
temporal-summarycollection, and the deterministic velocity fields (the substrate's answer to the "150+ PRs a week" V-B-A failure class) have no producer.The Architectural Reality
Bound by ADR 0028 (re-verify
Acceptedat claim):#12676pattern —MaintenanceBackpressureServiceheavy-maintenance lane + supervised-child scheduled task + most-recent-first bounded batches — scheduled under ADR 0022 fairness (must not starve REM/defrag siblings).mergedPrs,devCommits,sessionsPerAgent,highImpactSessions,adrsLanded,sandboxesGraduated), each bound to its named source substrate at implementation; prose is never the source of truth. Velocity fields are folded into this leaf (not separate) because they ship with the aggregation write path — a separate metrics leaf would re-open the same files (fold rationale in the map).SUMMARY_DAILYlabels via this deterministic lane only — never extractor-prompt widening).versionmetadata field..mjsplacement viastructural-pre-flightat claim (likelyai/daemons/scheduled-task +ai/services/territory; contract stays directory-agnostic).The Fix
One PR: the L1 (per-session) + L2 (daily) aggregation lane writing collection records +
SUMMARY_DAILYlabels, velocity fields populated from named sources, retention/versioning policy, scheduled under the backpressure/fairness substrate. No L3–L5 logic (Leaf C), no consumer surface.Contract Ledger Matrix
#12676patterntemporal-summaryversion; bounded growthDecision Record impact
depends-on ADR 0028(Accepted-gate) ·aligned-with ADR 0022(scheduling fairness) · consumes Leaf A (#14433) schema.Acceptance Criteria
SUMMARY_DAILYlabels written only by this lane (extractor untouched).versionfield.Accepted; gate stated in the PR body.Out of Scope
Avoided Traps
Related
Parent: #12679 (native link on file). Authority: ADR 0028 (PR
#14428). Depends-on:#14433(Leaf A). Sibling: Leaf C (L3–L5 synthesis). Pattern source: PR#12676(merged 2026-06-07).Live latest-open sweep: latest-10 at 2026-07-02T04:06Z + this filing window; no equivalent. A2A sweep: all-states at 04:06Z; no competing claim. Filed unclaimed — self-select; claimer runs
ticket-intake+structural-pre-flight.Origin Session ID: 2251c81c-1446-4723-86b3-479322bbcc95 Retrieval Hint: "temporal pyramid Leaf B L1 L2 durable aggregation velocity fields backpressure"