Re-rolls a UInt64 count plus N element streams (each $ts) back into N parallel lists (each [$ts]) of that length, buffering count element-ticks before emitting one tick. Inverse of lift_unroll, whose length channel supplies the count.
Typical backends
Unroll a list, process each element, then regroup into batched lists.
Per-element evaluate then restore the original grouping, serialised.
Caveats
- Hard constraintEach element channel must deliver exactly count elements per group, in order; a count mismatch desyncs the rest of the deployment.
- State lifetimeHolds the in-progress group as state until count elements arrive on every channel, then flushes; it never emits a partial list.
- I/O contractA count of 0 emits an empty list per channel for that tick, so downstream must tolerate empty groups.
- OrderingThe count must arrive before, or paired with, its matching elements; inverting the count/element order causes unrecoverable desync.