The llama.cpp project has added support for DFlash speculative decoding with the HunyuanOCR model by exposing layer input tensors in the target graph. This change allows the draft model to read residual streams, enabling image requests to run successfully with a draft acceptance rate of approximately 0.5 and byte-identical OCR output compared to non-speculative runs.
The update also fixes DFlash draft conversion against HunYuan targets, resolving two specific failures: an AttributeError caused by unbound vocab handling and config lookups that incorrectly read draft parameters instead of target configurations. These fixes ensure that converting tencent/HunyuanOCR DFlash drafts succeeds for both version 1.5 and v1.0 checkpoints without altering base model conversions.
These changes enable efficient speculative decoding for Hunyuan-based models in llama.cpp, improving inference speed while maintaining output fidelity.