Add Domino draft model training
Summary
- add a Domino draft model with a DFlash backbone and causal low-rank correction head
- add the base-anchored curriculum training wrapper and trainer dispatch
- register Domino configuration/model loading and provide a reference draft config
- add CPU tests for configuration, forward behavior, curriculum semantics, gradient flow, and learning
Why
This adds training support for the Domino speculative decoding method while reusing TorchSpec's existing DFlash anchor sampling, masking, metrics, and distributed trainer path.
Addresses #114.
Validation
pytest tests/test_domino.py tests/test_dflash.py -q(76 passed)ruff checkon all changed Python filesgit diff --check- JSON and Python syntax validation
Scope
This PR implements training support. Serving and inference integration for the fused Domino head remain follow-up work.
Thanks for adding Domino support! This is exciting to see and very encouraging. I’ll try it out when I get some time and share any feedback or issues I find.
@jianuo-huang @yubofredwang
Finished running some experiment on 8*H100 node, verified that implementation works. attached results in PR description, need review
@SeaTuKeMa thanks for the great work! I will run e2e over the weekend