# ECP-0005: deterministic chunking pipeline Status: Draft ## Problem We need a deterministic encoding and chunking pipeline so that identical broadcasts produce identical objects across relays. ## Decision Adopt a deterministic chunking profile with the following constraints: - Single-threaded encoding by default. - Fixed GOP cadence and keyframe placement. - Bitexact flags enabled wherever possible. - Fixed chunk duration (default 2 seconds) and stable object naming. Initial implementation uses ffmpeg CLI piping into the ac-ffmpeg chunker for rapid iteration, while the primary goal is to move to libav bindings for deeper control and determinism validation. ## Alternatives considered - Multithreaded encoders: rejected because they reduce reproducibility. - Hardware encoders: deferred because determinism is uncertain. - HLS segmentation: rejected as the primary format; MoQ objects will be derived directly. ## Rollout / teardown - Introduce `ec-chopper` with a deterministic profile and ffmpeg-based segmenter. - Measure determinism with repeated runs. - Replace the CLI with libav bindings once the control surface is verified.