DeepSpeed
932f0b52 - Add OPSD example: config, divergence losses, utils + tests

Commit
53 days ago
Add OPSD example: config, divergence losses, utils + tests First slice of the on-policy distillation example app under examples/opsd/. This commit lands the framework-agnostic foundation: the OPSDConfig dataclass hierarchy, chunked / streamed forward-KL / reverse-KL / JSD losses with sequence-axis chunking to bound peak memory, response-mask + shift helpers, and a 24-case CPU-only test suite covering identity, masking, chunk equivalence, gradient flow, and numerical edge cases. Signed-off-by: Zhipeng Wang <zhipengbayern@gmail.com>
Author
Committer
Parents
Loading