Source: cccl_upstream/cub/test/catch2_test_device_three_way_partition.cu (random pick)
CCCL test design pattern applied:
1. Empty input handling (TC-10: empty messages → 4xx)
2. Stability verification (TC-11: chat_dataset_v0.json all turns pass)
3. Edge cases (TC-07 tool calling, TC-08 stop sequence, TC-06 reasoning)
4. Large problem coverage (TC-11: multi-turn conversations)
CCCL three-way partition test insight: always verify both CUB and Thrust
paths produce identical results. Our equivalent: verify every modification
we make to base doesn't break any of the 11 functional test cases.
Also deploys sampler.py with CCCL-ported top-k fast path (from
partition/flagged.cu benchmark's radix select insight).