doem1997 commited on
Commit
de04b98
路
verified 路
1 Parent(s): cbad87e

Update the model card

Browse files
README.md CHANGED
@@ -11,7 +11,7 @@ tags:
11
  datasets:
12
  - "mlfoundations/dclm-baseline-1.0-parquet"
13
  model-index:
14
- - name: "looptitan-p1-moe18-muon"
15
  results:
16
  - task:
17
  type: text-generation
@@ -30,14 +30,16 @@ model-index:
30
  <div class="hidden md:block"><p align="center"><img class="not-prose dark:hidden" src="assets/banner-light.svg" width="720" alt="18 layers"><img class="not-prose hidden dark:block" src="assets/banner-dark.svg" width="720" alt="18 layers"></p></div>
31
  <div class="md:hidden"><p align="center"><img class="not-prose dark:hidden" src="assets/banner-light-narrow.svg" width="360" alt="18 layers"><img class="not-prose hidden dark:block" src="assets/banner-dark-narrow.svg" width="360" alt="18 layers"></p></div>
32
 
33
- <p align="center" class="not-prose dark:hidden" style="margin:1.5em 0"><img class="not-prose inline-block" src="assets/capsule-homepage-light.svg" height="32" alt="Homepage"><a href="https://github.com/datamllab/LoopTitan"><img class="not-prose inline-block" src="assets/capsule-code-light.svg" height="32" alt="Code"></a><a href="https://github.com/datamllab/LoopTitan/tree/main/docs"><img class="not-prose inline-block" src="assets/capsule-docs-light.svg" height="32" alt="Documentation"></a><img class="not-prose inline-block" src="assets/capsule-models-light.svg" height="32" alt="Models"><img class="not-prose inline-block" src="assets/capsule-paper-light.svg" height="32" alt="Paper"><a href="https://github.com/datamllab/LoopTitan/blob/main/docs/results/phase1.md"><img class="not-prose inline-block" src="assets/capsule-results-light.svg" height="32" alt="Results"></a></p>
34
- <p align="center" class="not-prose hidden dark:block" style="margin:1.5em 0"><img class="not-prose inline-block" src="assets/capsule-homepage-dark.svg" height="32" alt="Homepage"><a href="https://github.com/datamllab/LoopTitan"><img class="not-prose inline-block" src="assets/capsule-code-dark.svg" height="32" alt="Code"></a><a href="https://github.com/datamllab/LoopTitan/tree/main/docs"><img class="not-prose inline-block" src="assets/capsule-docs-dark.svg" height="32" alt="Documentation"></a><img class="not-prose inline-block" src="assets/capsule-models-dark.svg" height="32" alt="Models"><img class="not-prose inline-block" src="assets/capsule-paper-dark.svg" height="32" alt="Paper"><a href="https://github.com/datamllab/LoopTitan/blob/main/docs/results/phase1.md"><img class="not-prose inline-block" src="assets/capsule-results-dark.svg" height="32" alt="Results"></a></p>
35
 
36
- # Standard MoE, deeper and narrower, 18 layers
37
 
38
  **Muon** 路 LoopTitan Phase 1 路 design 3 of 8, each trained with AdamW and with Muon
39
 
40
- Deeper and narrower: 18 layers at width 1056, 58 experts per layer, expert hidden size 384, top-8. A base language model trained from scratch, not instruction tuned.
 
 
41
 
42
  ## Results
43
 
@@ -45,8 +47,8 @@ Deeper and narrower: 18 layers at width 1056, 58 experts per layer, expert hidde
45
  |---:|---:|---:|
46
  | 0.970165 | 0.971959 | -4.21 mBPB |
47
 
48
- <div class="hidden md:block"><p align="center"><img class="not-prose dark:hidden" src="assets/standing-light.svg" width="720" alt="Test mBPB of the 8 designs of this release against the standard MoE, by optimizer: Standard MoE: AdamW +0.0, Muon +0.0; Finer experts: AdamW -4.2, Muon -0.9; Deeper, narrower: AdamW -6.9, Muon -4.2; Expert layout: AdamW -5.9, Muon -3.4; Untied twin: AdamW -8.9, Muon -3.3; The loop: AdamW -9.0, Muon -3.7; One more visit: AdamW -14.8, Muon -12.2; Twice the experts: AdamW -14.3, Muon -9.9."><img class="not-prose hidden dark:block" src="assets/standing-dark.svg" width="720" alt="Test mBPB of the 8 designs of this release against the standard MoE, by optimizer: Standard MoE: AdamW +0.0, Muon +0.0; Finer experts: AdamW -4.2, Muon -0.9; Deeper, narrower: AdamW -6.9, Muon -4.2; Expert layout: AdamW -5.9, Muon -3.4; Untied twin: AdamW -8.9, Muon -3.3; The loop: AdamW -9.0, Muon -3.7; One more visit: AdamW -14.8, Muon -12.2; Twice the experts: AdamW -14.3, Muon -9.9."></p></div>
49
- <div class="md:hidden"><p align="center"><img class="not-prose dark:hidden" src="assets/standing-light-narrow.svg" width="360" alt="Test mBPB of the 8 designs of this release against the standard MoE, by optimizer: Standard MoE: AdamW +0.0, Muon +0.0; Finer experts: AdamW -4.2, Muon -0.9; Deeper, narrower: AdamW -6.9, Muon -4.2; Expert layout: AdamW -5.9, Muon -3.4; Untied twin: AdamW -8.9, Muon -3.3; The loop: AdamW -9.0, Muon -3.7; One more visit: AdamW -14.8, Muon -12.2; Twice the experts: AdamW -14.3, Muon -9.9."><img class="not-prose hidden dark:block" src="assets/standing-dark-narrow.svg" width="360" alt="Test mBPB of the 8 designs of this release against the standard MoE, by optimizer: Standard MoE: AdamW +0.0, Muon +0.0; Finer experts: AdamW -4.2, Muon -0.9; Deeper, narrower: AdamW -6.9, Muon -4.2; Expert layout: AdamW -5.9, Muon -3.4; Untied twin: AdamW -8.9, Muon -3.3; The loop: AdamW -9.0, Muon -3.7; One more visit: AdamW -14.8, Muon -12.2; Twice the experts: AdamW -14.3, Muon -9.9."></p></div>
50
 
51
  Bits per byte on the complete held-out test and validation splits after the last update; lower is better. The standard MoE is [`recipes/phase1/m0-muon.json`](https://github.com/datamllab/LoopTitan/blob/main/recipes/phase1/m0-muon.json); 1 mBPB is 0.001 BPB.
52
 
@@ -67,7 +69,7 @@ Matched budgets: all three within 5% of the standard MoE (Muon).
67
  import torch
68
  from transformers import AutoModelForCausalLM, AutoTokenizer
69
 
70
- repo = "NaturalScale/looptitan-p1-moe18-muon"
71
  tokenizer = AutoTokenizer.from_pretrained(repo, trust_remote_code=True)
72
  model = AutoModelForCausalLM.from_pretrained(repo, trust_remote_code=True).eval()
73
  ids = torch.tensor([[tokenizer.bos_token_id] + tokenizer.encode("The model", add_special_tokens=False)])
@@ -83,14 +85,14 @@ The model runs Python code from this repository: read it first, or pin `revision
83
 
84
  | Design | AdamW | Muon |
85
  |:---|---:|---:|
86
- | Standard MoE, 12 layers | [0.9995](https://huggingface.co/NaturalScale/looptitan-p1-moe12-adamw) | [0.9744](https://huggingface.co/NaturalScale/looptitan-p1-moe12-muon) |
87
- | Standard MoE with finer experts | [0.9953](https://huggingface.co/NaturalScale/looptitan-p1-moe12-finer-adamw) | [0.9735](https://huggingface.co/NaturalScale/looptitan-p1-moe12-finer-muon) |
88
- | Standard MoE, deeper and narrower, 18 layers | [0.9926](https://huggingface.co/NaturalScale/looptitan-p1-moe18-adamw) | **0.9702** |
89
- | Standard MoE, 18 layers, fewer experts in the middle | [0.9936](https://huggingface.co/NaturalScale/looptitan-p1-moe18-layout-adamw) | [0.9710](https://huggingface.co/NaturalScale/looptitan-p1-moe18-layout-muon) |
90
- | Untied twin of the loop | [0.9906](https://huggingface.co/NaturalScale/looptitan-p1-twin-adamw) | [0.9710](https://huggingface.co/NaturalScale/looptitan-p1-twin-muon) |
91
- | Looped MoE: the middle 6 layers run twice | [0.9905](https://huggingface.co/NaturalScale/looptitan-p1-loop6x2-adamw) | [0.9707](https://huggingface.co/NaturalScale/looptitan-p1-loop6x2-muon) |
92
- | Standard MoE with one more visit, outside matched budgets | [0.9847](https://huggingface.co/NaturalScale/looptitan-p1-moe12-loop6x2-unmatched-adamw) | [0.9621](https://huggingface.co/NaturalScale/looptitan-p1-moe12-loop6x2-unmatched-muon) |
93
- | Standard MoE with twice the experts, outside matched budgets | [0.9852](https://huggingface.co/NaturalScale/looptitan-p1-moe12-2e-adamw) | [0.9645](https://huggingface.co/NaturalScale/looptitan-p1-moe12-2e-muon) |
94
 
95
  ## Citation
96
 
 
11
  datasets:
12
  - "mlfoundations/dclm-baseline-1.0-parquet"
13
  model-index:
14
+ - name: "LoopTitan-Base-1.3B-A0.2B"
15
  results:
16
  - task:
17
  type: text-generation
 
30
  <div class="hidden md:block"><p align="center"><img class="not-prose dark:hidden" src="assets/banner-light.svg" width="720" alt="18 layers"><img class="not-prose hidden dark:block" src="assets/banner-dark.svg" width="720" alt="18 layers"></p></div>
31
  <div class="md:hidden"><p align="center"><img class="not-prose dark:hidden" src="assets/banner-light-narrow.svg" width="360" alt="18 layers"><img class="not-prose hidden dark:block" src="assets/banner-dark-narrow.svg" width="360" alt="18 layers"></p></div>
32
 
33
+ <p align="center" class="not-prose dark:hidden" style="margin:1.5em 0"><a href="https://datamllab.github.io/LoopTitan/"><img class="not-prose inline-block" src="assets/capsule-homepage-light.svg" height="32" alt="Homepage"></a><a href="https://github.com/datamllab/LoopTitan"><img class="not-prose inline-block" src="assets/capsule-code-light.svg" height="32" alt="Code"></a><a href="https://github.com/datamllab/LoopTitan/tree/main/docs"><img class="not-prose inline-block" src="assets/capsule-docs-light.svg" height="32" alt="Documentation"></a><img class="not-prose inline-block" src="assets/capsule-models-light.svg" height="32" alt="Models"><img class="not-prose inline-block" src="assets/capsule-paper-light.svg" height="32" alt="Paper"><a href="https://github.com/datamllab/LoopTitan/blob/main/docs/results/phase1.md"><img class="not-prose inline-block" src="assets/capsule-results-light.svg" height="32" alt="Results"></a></p>
34
+ <p align="center" class="not-prose hidden dark:block" style="margin:1.5em 0"><a href="https://datamllab.github.io/LoopTitan/"><img class="not-prose inline-block" src="assets/capsule-homepage-dark.svg" height="32" alt="Homepage"></a><a href="https://github.com/datamllab/LoopTitan"><img class="not-prose inline-block" src="assets/capsule-code-dark.svg" height="32" alt="Code"></a><a href="https://github.com/datamllab/LoopTitan/tree/main/docs"><img class="not-prose inline-block" src="assets/capsule-docs-dark.svg" height="32" alt="Documentation"></a><img class="not-prose inline-block" src="assets/capsule-models-dark.svg" height="32" alt="Models"><img class="not-prose inline-block" src="assets/capsule-paper-dark.svg" height="32" alt="Paper"><a href="https://github.com/datamllab/LoopTitan/blob/main/docs/results/phase1.md"><img class="not-prose inline-block" src="assets/capsule-results-dark.svg" height="32" alt="Results"></a></p>
35
 
36
+ # LoopTitan-Base-1.3B-A0.2B
37
 
38
  **Muon** 路 LoopTitan Phase 1 路 design 3 of 8, each trained with AdamW and with Muon
39
 
40
+ Deeper and narrower: 18 layers at width 1056, 58 experts per layer, expert hidden size 384, top-8. A base language model trained from scratch, not instruction tuned. In the paper: LoopTitan-Base (MoE-18).
41
+
42
+ 1.31B parameters stored without embeddings, 1.63B with the input embedding and output head (the count Hugging Face shows), 0.22B active per token.
43
 
44
  ## Results
45
 
 
47
  |---:|---:|---:|
48
  | 0.970165 | 0.971959 | -4.21 mBPB |
49
 
50
+ <div class="hidden md:block"><p align="center"><img class="not-prose dark:hidden" src="assets/standing-light.svg" width="720" alt="Test mBPB of the 8 designs of this release against the standard MoE, by optimizer: Standard MoE: AdamW +0.0, Muon +0.0; Finer experts: AdamW -4.2, Muon -0.9; Deeper, narrower: AdamW -6.9, Muon -4.2; Expert layout: AdamW -5.9, Muon -3.4; Unrolled: AdamW -8.9, Muon -3.3; The loop: AdamW -9.0, Muon -3.7; One more visit: AdamW -14.8, Muon -12.2; Twice the experts: AdamW -14.3, Muon -9.9."><img class="not-prose hidden dark:block" src="assets/standing-dark.svg" width="720" alt="Test mBPB of the 8 designs of this release against the standard MoE, by optimizer: Standard MoE: AdamW +0.0, Muon +0.0; Finer experts: AdamW -4.2, Muon -0.9; Deeper, narrower: AdamW -6.9, Muon -4.2; Expert layout: AdamW -5.9, Muon -3.4; Unrolled: AdamW -8.9, Muon -3.3; The loop: AdamW -9.0, Muon -3.7; One more visit: AdamW -14.8, Muon -12.2; Twice the experts: AdamW -14.3, Muon -9.9."></p></div>
51
+ <div class="md:hidden"><p align="center"><img class="not-prose dark:hidden" src="assets/standing-light-narrow.svg" width="360" alt="Test mBPB of the 8 designs of this release against the standard MoE, by optimizer: Standard MoE: AdamW +0.0, Muon +0.0; Finer experts: AdamW -4.2, Muon -0.9; Deeper, narrower: AdamW -6.9, Muon -4.2; Expert layout: AdamW -5.9, Muon -3.4; Unrolled: AdamW -8.9, Muon -3.3; The loop: AdamW -9.0, Muon -3.7; One more visit: AdamW -14.8, Muon -12.2; Twice the experts: AdamW -14.3, Muon -9.9."><img class="not-prose hidden dark:block" src="assets/standing-dark-narrow.svg" width="360" alt="Test mBPB of the 8 designs of this release against the standard MoE, by optimizer: Standard MoE: AdamW +0.0, Muon +0.0; Finer experts: AdamW -4.2, Muon -0.9; Deeper, narrower: AdamW -6.9, Muon -4.2; Expert layout: AdamW -5.9, Muon -3.4; Unrolled: AdamW -8.9, Muon -3.3; The loop: AdamW -9.0, Muon -3.7; One more visit: AdamW -14.8, Muon -12.2; Twice the experts: AdamW -14.3, Muon -9.9."></p></div>
52
 
53
  Bits per byte on the complete held-out test and validation splits after the last update; lower is better. The standard MoE is [`recipes/phase1/m0-muon.json`](https://github.com/datamllab/LoopTitan/blob/main/recipes/phase1/m0-muon.json); 1 mBPB is 0.001 BPB.
54
 
 
69
  import torch
70
  from transformers import AutoModelForCausalLM, AutoTokenizer
71
 
72
+ repo = "NaturalScale/LoopTitan-Base-1.3B-A0.2B"
73
  tokenizer = AutoTokenizer.from_pretrained(repo, trust_remote_code=True)
74
  model = AutoModelForCausalLM.from_pretrained(repo, trust_remote_code=True).eval()
75
  ids = torch.tensor([[tokenizer.bos_token_id] + tokenizer.encode("The model", add_special_tokens=False)])
 
85
 
86
  | Design | AdamW | Muon |
87
  |:---|---:|---:|
88
+ | Standard MoE, 12 layers | [0.9995](https://huggingface.co/NaturalScale/LoopTitan-MoE12-1.3B-A0.2B-AdamW) | [0.9744](https://huggingface.co/NaturalScale/LoopTitan-MoE12-1.3B-A0.2B-Muon) |
89
+ | Standard MoE with finer experts | [0.9953](https://huggingface.co/NaturalScale/LoopTitan-MoE12-FineExperts-1.3B-A0.2B-AdamW) | [0.9735](https://huggingface.co/NaturalScale/LoopTitan-MoE12-FineExperts-1.3B-A0.2B-Muon) |
90
+ | Standard MoE, deeper and narrower, 18 layers | [0.9926](https://huggingface.co/NaturalScale/LoopTitan-MoE18-1.3B-A0.2B-AdamW) | **0.9702** |
91
+ | Standard MoE, 18 layers, fewer experts in the middle | [0.9936](https://huggingface.co/NaturalScale/LoopTitan-MoE18-Layout-1.3B-A0.2B-AdamW) | [0.9710](https://huggingface.co/NaturalScale/LoopTitan-MoE18-Layout-1.3B-A0.2B-Muon) |
92
+ | The looped MoE unrolled: 18 layers, no weights shared | [0.9906](https://huggingface.co/NaturalScale/LoopTitan-Unrolled-1.3B-A0.2B-AdamW) | [0.9710](https://huggingface.co/NaturalScale/LoopTitan-Unrolled-1.3B-A0.2B-Muon) |
93
+ | Looped MoE: the middle 6 layers run twice | [0.9905](https://huggingface.co/NaturalScale/LoopTitan-Looped-1.3B-A0.2B-AdamW) | [0.9707](https://huggingface.co/NaturalScale/LoopTitan-Looped-1.3B-A0.2B-Muon) |
94
+ | Standard MoE with one more visit, outside matched budgets | [0.9847](https://huggingface.co/NaturalScale/LoopTitan-MoE12-Revisit-1.3B-A0.3B-AdamW) | [0.9621](https://huggingface.co/NaturalScale/LoopTitan-MoE12-Revisit-1.3B-A0.3B-Muon) |
95
+ | Standard MoE with twice the experts, outside matched budgets | [0.9852](https://huggingface.co/NaturalScale/LoopTitan-MoE12-2xExperts-2.6B-A0.2B-AdamW) | [0.9645](https://huggingface.co/NaturalScale/LoopTitan-MoE12-2xExperts-2.6B-A0.2B-Muon) |
96
 
97
  ## Citation
98
 
assets/standing-dark-narrow.svg CHANGED
assets/standing-dark.svg CHANGED
assets/standing-light-narrow.svg CHANGED
assets/standing-light.svg CHANGED