k-l-lambda commited on
Commit
9b80167
·
verified ·
1 Parent(s): 39e81c8

v3 fine-tune: L2-SP anchor + ttt=4 off-policy (accept_len 2.345, pos 0.648/0.419/0.278)

Browse files
Files changed (2) hide show
  1. README.md +32 -46
  2. model.safetensors +1 -1
README.md CHANGED
@@ -1,68 +1,54 @@
1
  ---
2
  license: other
3
- base_model: lightseekorg/kimi-k2.6-eagle3-mla
4
  tags:
5
  - text-generation
6
  - speculative-decoding
7
  - eagle3
8
  - kimi-k2.6
9
  - mla
10
- - camelot
11
  ---
12
 
13
- # kimi-k2.6-eagle3-mla (continual fine-tune)
14
 
15
  Eagle3 MTP draft model with MLA (Multi-Latent Attention) for accelerating
16
  inference of [Kimi-K2.6](https://huggingface.co/moonshotai/Kimi-K2.6).
17
 
18
- This checkpoint is a **continual fine-tune** of
19
- [lightseekorg/kimi-k2.6-eagle3-mla](https://huggingface.co/lightseekorg/kimi-k2.6-eagle3-mla),
20
- further trained on an in-house instruction distribution. The architecture,
21
- config, and tensor layout are identical to the base model, so it is a drop-in
22
- replacement in the same vLLM serving path.
23
 
24
- ## Training Setup
25
 
26
- - **Init**: continual FT from `lightseekorg/kimi-k2.6-eagle3-mla`.
27
- - **Framework**: Camelot online speculative-decoding training — concurrent
28
- FSDP training + vLLM rollout with cross-node hidden-state transfer over
29
- Mooncake (RDMA).
30
- - **Topology**: 1 datagen node (Kimi-K2.6, TP=8) -> Mooncake -> 1 trainer GPU.
31
- - **Schedule**: an initial 10k-step cosine phase (LR 2e-5), then a constant
32
- low-LR (2e-6) refinement phase continued from the best checkpoint. This
33
- published checkpoint is the best-val checkpoint of the refinement phase.
34
- - **Data**: online-generated hidden states from a ~100k-prompt instruction set
35
- (each sample consumed once).
36
- - seq len 4096, Eagle3 TTT steps 3, global batch size 1.
37
 
38
- ## Validation (training-time, teacher-forced)
39
 
40
- Per-position draft accuracy on a fixed held-out val split, measured during
41
- training. `acc@i` is the accuracy at TTT position `i` (`i = 0, 1, 2`):
42
- `full_acc@i` requires positions `0..i` all correct; `cond_acc@i` is conditioned
43
- on `0..i-1` correct. This is a **training-time, teacher-forced** metric on a
44
- small online-sampled val split — it indicates per-position draft quality but is
45
- **not** a runtime accept-length and is not comparable across runs/splits.
46
 
47
- Best checkpoint of the refinement phase (this published checkpoint):
 
 
 
48
 
49
- | metric | value |
50
- | --- | --- |
51
- | val_loss | 3.608 |
52
- | full_acc@0 | 0.799 |
53
- | full_acc@1 | 0.517 |
54
- | full_acc@2 | 0.306 |
55
- | cond_acc@1 | 0.648 |
56
- | cond_acc@2 | 0.594 |
57
 
58
- A runtime `accept_length` benchmark (vLLM 0.20, `num_speculative_tokens=3`) on a
59
- common held-out set is pending and will be added once measured.
60
 
61
- ## Quick Start (vLLM >= 0.20.0)
62
-
63
- ```bash
64
- vllm serve moonshotai/Kimi-K2.6 \
65
- --tensor-parallel-size 8 \
66
- --speculative-config '{"model": "k-l-lambda/kimi-k2.6-eagle3-mla", "method": "eagle3", "num_speculative_tokens": 3}' \
67
- --trust-remote-code
68
- ```
 
1
  ---
2
  license: other
3
+ base_model: moonshotai/Kimi-K2.6
4
  tags:
5
  - text-generation
6
  - speculative-decoding
7
  - eagle3
8
  - kimi-k2.6
9
  - mla
10
+ - torchspec
11
  ---
12
 
13
+ # kimi-k2.6-eagle3-mla
14
 
15
  Eagle3 MTP draft model with MLA (Multi-Latent Attention) for accelerating
16
  inference of [Kimi-K2.6](https://huggingface.co/moonshotai/Kimi-K2.6).
17
 
18
+ This is a fine-tuned draft, anchored to the official
19
+ [lightseekorg/kimi-k2.6-eagle3-mla](https://huggingface.co/lightseekorg/kimi-k2.6-eagle3-mla)
20
+ initialization. It targets multi-hop (downstream-position) acceptance while
21
+ preserving the first-hop gain, evaluated by runtime accept-length on a frozen
22
+ full-context held-out set.
23
 
24
+ ## Fine-tune setup
25
 
26
+ - **Init**: lightseekorg/kimi-k2.6-eagle3-mla (official MLA weights)
27
+ - **Objective**: Eagle3 distillation + multi-step TTT supervision
28
+ (`ttt_steps=4`, `ttt_step_loss_decay=1.0`, off-policy downstream tokens)
29
+ - **Anti-over-specialization**: L2-SP weight-space anchor toward the init
30
+ (penalize trainable-param drift; lambda=1e-4)
31
+ - **Optimizer**: lr 2e-5, cosine schedule
32
+ - **Checkpoint**: best by held-out runtime accept-length
 
 
 
 
33
 
34
+ ## Performance
35
 
36
+ Primary metric is **accept_length** average tokens accepted per speculation
37
+ step with `num_speculative_tokens=3` (higher is better). Per-position numbers
38
+ are conditional acceptance rates at hop 0/1/2. Evaluated on a frozen
39
+ full-context held-out judge set (912 prompts, greedy), vLLM 0.20.0, 8x H200,
40
+ TP=8, max-model-len 32768.
 
41
 
42
+ | Model | accept_len | pos-0 | pos-1 | pos-2 |
43
+ |-------|-----------:|------:|------:|------:|
44
+ | lightseek (official init) | 2.30 | 0.633 | 0.404 | 0.264 |
45
+ | this model | **2.345** | **0.648** | **0.419** | **0.278** |
46
 
47
+ This draft improves first-hop acceptance over the official init while also
48
+ lifting the downstream positions (pos-1, pos-2), yielding a higher overall
49
+ accept length.
 
 
 
 
 
50
 
51
+ ## Usage
 
52
 
53
+ Serve with vLLM as the speculative draft for Kimi-K2.6, with
54
+ `num_speculative_tokens=3` in the speculative-config.
 
 
 
 
 
 
model.safetensors CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:e799138e5bccba32a9b02628e99ef93912999b0166ada4542fab797f73f3e28b
3
  size 6031210296
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:57cf1a3b1cd6153619f37a42410e6123fd899f15d2f95d230dafe68399825d04
3
  size 6031210296