Add Challenge 113: kimi delta attention - #306
Draft
shxjames wants to merge 3 commits into
Draft
Conversation
shxjames
marked this pull request as draft
July 31, 2026 04:34
Contributor
|
Impressive to put this together so quickly! Assuming lot's of people will want to play around with this challenge now that they have released the architecture. |
ishaan-arya
reviewed
Aug 7, 2026
| K = torch.tensor([[[1.0, 0.0], [0.0, 1.0]]], device=device, dtype=dtype) | ||
| V = torch.tensor([[[1.0, 2.0], [2.0, 0.0]]], device=device, dtype=dtype) | ||
| alpha = torch.tensor([[[1.0, 1.0], [0.5, 0.5]]], device=device, dtype=dtype) | ||
| beta = torch.tensor([[1.0, 0.5]], device=device, dtype=dtype) |
Contributor
There was a problem hiding this comment.
The constraints in the spec say 0 ≤ beta < 1 and the example test seems to violate that. Either make the constraint ≤ 1 or change the example.
| beta = jnp.asarray(beta, dtype=jnp.float32) # (batch, seq_len) | ||
|
|
||
| batch = Q.shape[0] | ||
| d = Q.shape[2] |
Contributor
There was a problem hiding this comment.
nit: batch and d are passed in as input params so we don't need to re-derive them here.
- Use seq_len in challenge.html to match the solve signature (all other seq_len challenges do the same); T appeared nowhere in the API. - Widen the beta constraint to [0, 1] — the worked example uses beta = 1.0, which the old [0, 1) bound excluded. - Add an SVG diagram of one recurrence step, showing the per-channel decay gate that distinguishes KDA from the head-wise gated delta rule. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
- Use seq_len (the actual solve parameter) instead of T throughout challenge.html - Widen the beta constraint to [0, 1] so it covers the example's beta_1 = 1.0 - Drop a stray authoring note from reference_impl Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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.
No description provided.