Repository navigation
[kimi] Update and Make Kimi K3 B200 numerics reproducible - #5143
Merged
Merged
Conversation
shuhuayu
force-pushed
the
k3-parity
branch
2 times, most recently
from
October 8, 2026 09:34
923b29b to
6254905
Compare
shuhuayu
marked this pull request as ready for review
October 9, 2026 00:35
shuhuayu
requested review from
fegin,
tianyu-l,
wconstab and
wwwjn
as code owners
October 9, 2026 00:35
Contributor
Author
|
the numerical parity test passed, the remaining failure related to kimi is from spmd type check, will fix it in a separate pr. |
tianyu-l
approved these changes
Oct 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
kimi_k3_debugmodel_mm_muonrecipe and FSDP2/EP2 topology unchanged.Why
The old golden predates #4881, which intentionally changed Kimi K3 attention-residual projections from truncated-normal to zero initialization.
While re-exporting it, two otherwise identical deterministic B200 runs diverged after step 1. A back-to-back diagnostic on the same runner reproduced both traces: Attention Gym's KDA autotuner can select numerically different valid schedules based on benchmark/cache state. Deterministic mode now skips that benchmark-dependent choice and uses the default schedule, matching TorchTitan's existing handling for other autotuned attention kernels.
Numerical source
kimi_k3_debugmodel_mm_muonlossandgrad_norma261836fb1c17635d71f2a04b81b882e9b60ba08f6229091393861dc33160ae5Both sequential exports were byte-for-byte identical.
Validation
kimi_k3_mm_muoncompleted withrc=0.loss_compare.py --assert-equalmatched all 10 losses and all 10 gradient norms exactly.main.