Dashboardopencode-loreResponses sparse-index representation

Responses sparse-index representation

Category: gotcha
Confidence: 1.00
ID: 01a0a9ac-d2c4-7972-a35f-5ca42302b283
Project ID: 6f4be9ff-ed84-4cca-a9e7-732a0b0b8677
Cross-project: No
Recalled in other projects: 0
Source session: 1QlDwh91ws2eThRpC
Created: 2026-09-13 00:32:03
Updated: 2026-09-16 10:04:30

Content

Trap: validating only event-level coordinates or relying on retained-byte limits looks sufficient, but terminal-only arrays and shifted continuation indices can create unbounded sparse state or change coordinates. Fix: validate output_index, content_index, and summary_index against min(maxSSEFrames, DEFAULT_MAX_SSE_FRAMES) before normalization or mutation; include continuation offsets and bidirectionally reconcile terminal arrays with completed lifecycle state. Preserve validated holes in raw output, skip holes only during semantic flattening, and never compact coordinates.

Move to: