-- Append-only event log of coordinator-issued reorders on a -- research-bound loop. Whenever a run's coordinator emits -- REORDER: INT-05 before INT-04 because prereq X is unmet -- (or any `REORDER: ` line in the run's final output), the -- topology_worker completion hook parses it and appends a -- {iteration, run_id, text, ts} -- object to this array. The loop card can then surface a mini-timeline -- of when the plan was adjusted and why — useful when the reviewer -- wants to understand why P0 items landed out of order. -- -- JSONB rather than a separate table so the loop row carries its own -- history — reads are already fast (loops list <10ms) and a -- per-iteration event log lives naturally alongside consumed_int_ids + -- current_int_index. If the log grows huge we can promote to a -- dedicated table later. ALTER TABLE loops ADD COLUMN reorder_events JSONB NOT NULL DEFAULT '[]'::jsonb;