← Lab
cleanband
confirmedupstream bugC++ · CPUInference & servingJuly 13, 2026
the question
Does llama_detokenize's negative-return magnitude equal the cleaned output length its contract documents, or the raw concatenated length before clean_spaces shrinks it?
what came out
For every space-trimming token the size-probe returns the raw length before clean_spaces shrinks it (R=2 vs cleaned C=1), and a buffer sized to the true cleaned length is spuriously rejected with -R. Non-trimming tokens satisfy R==C. A documented-contract violation, benign, with a deterministic repro on build 9760.
method & receipts
- Result: confirmed
- Pre-registered — the prediction was written down and committed before the run.
- Reproducible — one script re-runs the whole thing from scratch.
- Tested — a correctness/benchmark suite ships alongside the code.
→ read the code and re-run it
github.com/v-code01/cleanband