Text Generation
Transformers
Safetensors
English
Italian
gpt2
1gpu-llm
official-release
single-gpu
trained-from-scratch
gpt2preln
bilingual
english
italian
pretraining
base-model
causal-lm
llm-nanochat
medium
decay-only
text-generation-inference
Instructions to use nazdef/1gpu-llm-medium-en-it-base-v2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use nazdef/1gpu-llm-medium-en-it-base-v2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="nazdef/1gpu-llm-medium-en-it-base-v2")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("nazdef/1gpu-llm-medium-en-it-base-v2") model = AutoModelForCausalLM.from_pretrained("nazdef/1gpu-llm-medium-en-it-base-v2", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use nazdef/1gpu-llm-medium-en-it-base-v2 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "nazdef/1gpu-llm-medium-en-it-base-v2" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "nazdef/1gpu-llm-medium-en-it-base-v2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/nazdef/1gpu-llm-medium-en-it-base-v2
- SGLang
How to use nazdef/1gpu-llm-medium-en-it-base-v2 with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "nazdef/1gpu-llm-medium-en-it-base-v2" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "nazdef/1gpu-llm-medium-en-it-base-v2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "nazdef/1gpu-llm-medium-en-it-base-v2" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "nazdef/1gpu-llm-medium-en-it-base-v2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use nazdef/1gpu-llm-medium-en-it-base-v2 with Docker Model Runner:
docker model run hf.co/nazdef/1gpu-llm-medium-en-it-base-v2
Release 1gpu-llm-medium-v2 step 34200
Browse files- .gitattributes +1 -0
- 1gpu-llm-official.png +3 -0
- README.md +154 -0
- config.json +26 -0
- decoding_grid_config.yaml +47 -0
- decoding_grid_report.md +219 -0
- export_command.json +519 -0
- generation_config.json +12 -0
- model.safetensors +3 -0
- recommended_decoding_params.json +20 -0
- release_note.md +7 -0
- special_tokens_map.json +6 -0
- step_34200.pt +3 -0
- step_34200.safetensors +3 -0
- step_34200.safetensors.json +519 -0
- tokenizer.json +0 -0
- tokenizer_config.json +9 -0
- tokenizer_meta.json +10 -0
- training_config.yaml +66 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
1gpu-llm-official.png filter=lfs diff=lfs merge=lfs -text
|
1gpu-llm-official.png
ADDED
|
Git LFS Details
|
README.md
ADDED
|
@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
+
pipeline_tag: text-generation
|
| 6 |
+
datasets:
|
| 7 |
+
- epfml/FineWeb-HQ
|
| 8 |
+
- epfml/FineWeb2-HQ
|
| 9 |
+
- google/wiki40b
|
| 10 |
+
tags:
|
| 11 |
+
- 1gpu-llm
|
| 12 |
+
- official-release
|
| 13 |
+
- single-gpu
|
| 14 |
+
- trained-from-scratch
|
| 15 |
+
- gpt2preln
|
| 16 |
+
- bilingual
|
| 17 |
+
- english
|
| 18 |
+
- italian
|
| 19 |
+
- pretraining
|
| 20 |
+
- base-model
|
| 21 |
+
- causal-lm
|
| 22 |
+
- llm-nanochat
|
| 23 |
+
- medium
|
| 24 |
+
- decay-only
|
| 25 |
+
---
|
| 26 |
+
|
| 27 |
+

|
| 28 |
+
|
| 29 |
+
# 1gpu-llm-medium-v2
|
| 30 |
+
|
| 31 |
+
Official medium bilingual base model of the `1gpu-llm` family, trained from
|
| 32 |
+
scratch and continued on a single NVIDIA GeForce RTX 4060 Ti 16GB.
|
| 33 |
+
|
| 34 |
+
This release is a base language model, not an instruction-tuned chat model.
|
| 35 |
+
|
| 36 |
+
## Release summary
|
| 37 |
+
|
| 38 |
+
- Released checkpoint: `step_34200`
|
| 39 |
+
- Parent/reference checkpoint: `step_34000` from the main CPT run
|
| 40 |
+
- Continuation: optimizer-preserving decay-only continuation, global steps
|
| 41 |
+
`34000 → 35700`; this release is the early scalar winner at `34200`
|
| 42 |
+
- Architecture: GPT-2-style decoder-only Transformer with pre-layernorm blocks
|
| 43 |
+
- Repo-native configuration: `architecture: gpt2`, `block_type: gpt2_prelayernorm`,
|
| 44 |
+
`norm_order: preln`
|
| 45 |
+
- Parameters: `337,639,424` (`~337.6M`)
|
| 46 |
+
- Context window and training sequence length: `2500` tokens
|
| 47 |
+
- Languages: English and Italian
|
| 48 |
+
|
| 49 |
+
## Why step_34200
|
| 50 |
+
|
| 51 |
+
The checkpoint was selected by a controlled 1000-token decoding comparison of
|
| 52 |
+
`step_34000`, `step_34200`, and `step_34800`, using the same tokenizer, seed,
|
| 53 |
+
device, precision, prompts, and generation budget across four presets.
|
| 54 |
+
|
| 55 |
+
Recommended pair:
|
| 56 |
+
|
| 57 |
+
- checkpoint: `step_34200`
|
| 58 |
+
- preset: `creative`
|
| 59 |
+
- tuning score: `3.1683`
|
| 60 |
+
- holdout score: `3.8405`
|
| 61 |
+
- EOS termination: `100%` on tuning and holdout
|
| 62 |
+
- truncation at 1000 tokens: `0%`
|
| 63 |
+
- strict loop rate: `0%`
|
| 64 |
+
- mean length: `410.6` tuning / `494.8` holdout tokens
|
| 65 |
+
- distinct-2: `0.9531` tuning / `0.9536` holdout
|
| 66 |
+
- language switches: `0%`
|
| 67 |
+
|
| 68 |
+
The model remains imperfect: long completions can show factual or semantic
|
| 69 |
+
drift. The conservative alternative is the parent `step_34000` with the
|
| 70 |
+
`anti_loop` preset, which is shorter and more controlled.
|
| 71 |
+
|
| 72 |
+
## Recommended generation
|
| 73 |
+
|
| 74 |
+
The public default is the `creative` preset selected by the holdout:
|
| 75 |
+
|
| 76 |
+
```python
|
| 77 |
+
from transformers import AutoModelForCausalLM, AutoTokenizer
|
| 78 |
+
import torch
|
| 79 |
+
|
| 80 |
+
repo_id = "nazdef/1gpu-llm-medium-v2"
|
| 81 |
+
tokenizer = AutoTokenizer.from_pretrained(repo_id)
|
| 82 |
+
model = AutoModelForCausalLM.from_pretrained(repo_id)
|
| 83 |
+
|
| 84 |
+
prompt = "La capitale d'Italia è"
|
| 85 |
+
prompt_ids = tokenizer(prompt, return_tensors="pt", add_special_tokens=False)
|
| 86 |
+
bos = torch.tensor([[tokenizer.bos_token_id]], dtype=prompt_ids["input_ids"].dtype)
|
| 87 |
+
input_ids = torch.cat([bos, prompt_ids["input_ids"]], dim=1)
|
| 88 |
+
attention_mask = torch.ones_like(input_ids)
|
| 89 |
+
|
| 90 |
+
with torch.no_grad():
|
| 91 |
+
outputs = model.generate(
|
| 92 |
+
input_ids=input_ids,
|
| 93 |
+
attention_mask=attention_mask,
|
| 94 |
+
do_sample=True,
|
| 95 |
+
max_new_tokens=1000,
|
| 96 |
+
temperature=1.0,
|
| 97 |
+
top_k=100,
|
| 98 |
+
top_p=0.95,
|
| 99 |
+
repetition_penalty=1.1,
|
| 100 |
+
no_repeat_ngram_size=0,
|
| 101 |
+
eos_token_id=tokenizer.eos_token_id,
|
| 102 |
+
pad_token_id=tokenizer.pad_token_id,
|
| 103 |
+
)
|
| 104 |
+
|
| 105 |
+
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
|
| 106 |
+
```
|
| 107 |
+
|
| 108 |
+
For a more conservative response style, use `anti_loop`:
|
| 109 |
+
|
| 110 |
+
- `temperature=0.8`
|
| 111 |
+
- `top_k=50`
|
| 112 |
+
- `top_p=0.9`
|
| 113 |
+
- `repetition_penalty=1.15`
|
| 114 |
+
- `no_repeat_ngram_size=4`
|
| 115 |
+
|
| 116 |
+
## Training provenance
|
| 117 |
+
|
| 118 |
+
The model was trained on a balanced English/Italian web + wiki corpus derived
|
| 119 |
+
from:
|
| 120 |
+
|
| 121 |
+
- English FineWeb-HQ (`epfml/FineWeb-HQ`)
|
| 122 |
+
- Italian FineWeb2-HQ (`epfml/FineWeb2-HQ`)
|
| 123 |
+
- English and Italian Wiki40B (`google/wiki40b`)
|
| 124 |
+
|
| 125 |
+
The local packed dataset used a 2500-token sequence length and a 50/50 EN/IT
|
| 126 |
+
source-balanced mix. The continuation loaded the model and AdamW optimizer
|
| 127 |
+
state from the `step_34000` checkpoint, deliberately ignored the saved scheduler
|
| 128 |
+
state, and created a local `wsd-decay-only` scheduler with no warmup or rewarm.
|
| 129 |
+
|
| 130 |
+
Included provenance files:
|
| 131 |
+
|
| 132 |
+
- `training_config.yaml`
|
| 133 |
+
- `decoding_grid_config.yaml`
|
| 134 |
+
- `decoding_grid_report.md`
|
| 135 |
+
- `export_manifest.json`
|
| 136 |
+
- `step_34200.safetensors.json`
|
| 137 |
+
|
| 138 |
+
## License
|
| 139 |
+
|
| 140 |
+
The model card uses `CC BY-SA 4.0` as the release license. Training data comes
|
| 141 |
+
from mixed upstream sources with their own terms, including FineWeb/FineWeb2
|
| 142 |
+
and Wiki40B. Downstream users are responsible for checking the applicable
|
| 143 |
+
upstream dataset terms, attribution requirements, share-alike obligations, and
|
| 144 |
+
any restrictions connected to the data or generated outputs in their intended
|
| 145 |
+
use case.
|
| 146 |
+
|
| 147 |
+
## Limitations
|
| 148 |
+
|
| 149 |
+
- This is a pretrained base model; it is not instruction-following aligned.
|
| 150 |
+
- It may hallucinate facts and drift semantically during long generations.
|
| 151 |
+
- English/Italian language consistency is strong in the selected decoding
|
| 152 |
+
holdout, but it is not a guarantee for arbitrary prompts.
|
| 153 |
+
- The public checkpoint is an experimental single-GPU family release, not a
|
| 154 |
+
claim of state-of-the-art performance.
|
config.json
ADDED
|
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"activation_function": "gelu",
|
| 3 |
+
"architecture": "gpt2",
|
| 4 |
+
"architectures": [
|
| 5 |
+
"GPT2LMHeadModel"
|
| 6 |
+
],
|
| 7 |
+
"attn_pdrop": 0.0,
|
| 8 |
+
"block_type": "gpt2_prelayernorm",
|
| 9 |
+
"causal_mask_mode": "buffered_upper_triangular",
|
| 10 |
+
"embd_pdrop": 0.0,
|
| 11 |
+
"init_strategy": "gpt2_std_0.02_residual_scale",
|
| 12 |
+
"layer_norm_epsilon": 1e-05,
|
| 13 |
+
"model_type": "gpt2",
|
| 14 |
+
"n_ctx": 2500,
|
| 15 |
+
"n_embd": 1024,
|
| 16 |
+
"n_head": 16,
|
| 17 |
+
"n_layer": 24,
|
| 18 |
+
"n_positions": 2500,
|
| 19 |
+
"norm_order": "preln",
|
| 20 |
+
"norm_type": "layernorm",
|
| 21 |
+
"positional_encoding": "learned_absolute",
|
| 22 |
+
"resid_pdrop": 0.0,
|
| 23 |
+
"tie_word_embeddings": true,
|
| 24 |
+
"use_cache": true,
|
| 25 |
+
"vocab_size": 32000
|
| 26 |
+
}
|
decoding_grid_config.yaml
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
name: medium_checkpoint_decoding_grid_1000
|
| 2 |
+
checkpoint_path: null
|
| 3 |
+
tokenizer_dir: null
|
| 4 |
+
tuning_prompts_path: eval_prompts/decoding_tuning.jsonl
|
| 5 |
+
holdout_prompts_path: eval_prompts/decoding_tuning_holdout.jsonl
|
| 6 |
+
seeds:
|
| 7 |
+
- 1337
|
| 8 |
+
holdout_top_k: 4
|
| 9 |
+
target_length_ratio: 1.0
|
| 10 |
+
ranking_weights:
|
| 11 |
+
prompt_pass_rate: 2.0
|
| 12 |
+
completion_rate: 0.5
|
| 13 |
+
distinct_2: 1.2
|
| 14 |
+
language_consistency: 0.75
|
| 15 |
+
length_closeness: 1.0
|
| 16 |
+
loop_rate: -2.0
|
| 17 |
+
repeated_4gram_rate: -1.5
|
| 18 |
+
language_switch_rate: -0.75
|
| 19 |
+
decoding_presets:
|
| 20 |
+
- name: anti_loop_conservative
|
| 21 |
+
max_new_tokens: 1000
|
| 22 |
+
temperature: 0.3
|
| 23 |
+
top_k: 50
|
| 24 |
+
top_p: 0.9
|
| 25 |
+
repetition_penalty: 1.15
|
| 26 |
+
no_repeat_ngram_size: 4
|
| 27 |
+
- name: anti_loop
|
| 28 |
+
max_new_tokens: 1000
|
| 29 |
+
temperature: 0.8
|
| 30 |
+
top_k: 50
|
| 31 |
+
top_p: 0.9
|
| 32 |
+
repetition_penalty: 1.15
|
| 33 |
+
no_repeat_ngram_size: 4
|
| 34 |
+
- name: balanced
|
| 35 |
+
max_new_tokens: 1000
|
| 36 |
+
temperature: 0.8
|
| 37 |
+
top_k: 50
|
| 38 |
+
top_p: 0.95
|
| 39 |
+
repetition_penalty: 1.1
|
| 40 |
+
no_repeat_ngram_size: 0
|
| 41 |
+
- name: creative
|
| 42 |
+
max_new_tokens: 1000
|
| 43 |
+
temperature: 1.0
|
| 44 |
+
top_k: 100
|
| 45 |
+
top_p: 0.95
|
| 46 |
+
repetition_penalty: 1.1
|
| 47 |
+
no_repeat_ngram_size: 0
|
decoding_grid_report.md
ADDED
|
@@ -0,0 +1,219 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Comparative 1000-token decoding grid — medium checkpoint selection
|
| 2 |
+
|
| 3 |
+
## Executive verdict
|
| 4 |
+
|
| 5 |
+
Recommended candidate for `1gpu-llm-medium`:
|
| 6 |
+
|
| 7 |
+
- checkpoint: `step_34200`
|
| 8 |
+
- preset: `creative`
|
| 9 |
+
- tuning score: `3.1683`
|
| 10 |
+
- holdout score: `3.8405`
|
| 11 |
+
- EOS termination: `100%` on tuning and holdout
|
| 12 |
+
- truncation at 1000 tokens: `0%`
|
| 13 |
+
- loop rate: `0%` on both splits
|
| 14 |
+
- repeated 4-gram rate: `0%` tuning, `25%` holdout
|
| 15 |
+
- mean generated length: `410.6` tuning / `494.8` holdout tokens
|
| 16 |
+
- median generated length: `392` tuning / `582.5` holdout tokens
|
| 17 |
+
- distinct-2: `0.9531` tuning / `0.9536` holdout
|
| 18 |
+
- language switches: `0%` on both splits
|
| 19 |
+
|
| 20 |
+
This is the strongest overall combination because it is the only checkpoint/preset
|
| 21 |
+
pair that combines the scalar champion checkpoint, a tuning winner confirmed by the
|
| 22 |
+
holdout, long completions, zero truncation, zero loops, high diversity, and no
|
| 23 |
+
language switching.
|
| 24 |
+
|
| 25 |
+
Conservative alternative:
|
| 26 |
+
|
| 27 |
+
- checkpoint: `step_34000`
|
| 28 |
+
- preset: `anti_loop`
|
| 29 |
+
- tuning score: `3.4540`
|
| 30 |
+
- holdout score: `3.6036`
|
| 31 |
+
- EOS termination: `100%` on both splits
|
| 32 |
+
- truncation: `0%`
|
| 33 |
+
- loop rate: `0%` on both splits
|
| 34 |
+
- repeated 4-gram rate: `0%` tuning, `25%` holdout
|
| 35 |
+
- mean length: `183.0` tuning / `265.5` holdout
|
| 36 |
+
|
| 37 |
+
It is cleaner against repetition but produces shorter, more conservative answers
|
| 38 |
+
and remains behind `step_34200 + creative` on the holdout score.
|
| 39 |
+
|
| 40 |
+
The behavior champion `step_34800` is not promoted. Its tuning winner is `creative`,
|
| 41 |
+
but holdout selects `balanced`; balanced is very short (`141.8` tokens mean) and
|
| 42 |
+
therefore is not rewarded as a final choice merely for stopping early. `step_34800`
|
| 43 |
+
does not provide a robust behavior advantage over `step_34200` under this 1000-token
|
| 44 |
+
comparison.
|
| 45 |
+
|
| 46 |
+
## Experimental controls
|
| 47 |
+
|
| 48 |
+
- Checkpoints: `step_34000`, `step_34200`, `step_34800`
|
| 49 |
+
- Presets: `anti_loop_conservative`, `anti_loop`, `balanced`, `creative`
|
| 50 |
+
- `max_new_tokens`: `1000` for every preset
|
| 51 |
+
- Tuning prompts: 7
|
| 52 |
+
- Holdout prompts: 4, disjoint from tuning
|
| 53 |
+
- Seed: `1337`
|
| 54 |
+
- Tokenizer: `/mnt/apps/llm-nanochat/tokenizers/tokenizer_20260515_en50it50_webwiki_stratified_500M`
|
| 55 |
+
- Device/dtype: CUDA / `bf16`
|
| 56 |
+
- Generation count: 7 per preset on tuning and 4 per preset on holdout, one seed
|
| 57 |
+
- Early stopping: only the model EOS path; no artificial stop was introduced
|
| 58 |
+
- Holdout coverage: all four presets were evaluated, not only the tuning top-k
|
| 59 |
+
|
| 60 |
+
The repo runner does not serialize an explicit `terminated_with_eos` boolean. Since
|
| 61 |
+
the generator has only two exits — EOS or the `max_new_tokens` loop limit — this
|
| 62 |
+
report derives EOS/truncation as follows:
|
| 63 |
+
|
| 64 |
+
- `num_generated_tokens < 1000`: EOS termination
|
| 65 |
+
- `num_generated_tokens == 1000`: truncation at the configured limit
|
| 66 |
+
|
| 67 |
+
## Complete tuning table
|
| 68 |
+
|
| 69 |
+
`rep` is repeated-4gram rate; `loop` is the stricter repeated-4gram loop rate.
|
| 70 |
+
Higher EOS, distinct-1/2 and language consistency are better; lower rep/loop and
|
| 71 |
+
switch rates are better.
|
| 72 |
+
|
| 73 |
+
| checkpoint | preset | score | EOS | trunc. | mean | median | distinct-1 | distinct-2 | rep | loop | lang. consistency |
|
| 74 |
+
|---|---|---:|---:|---:|---:|---:|---:|---:|---:|---:|---:|
|
| 75 |
+
| 34000 | anti_loop_conservative | 2.9462 | 71.4% | 28.6% | 351.0 | 125.0 | 0.4763 | 0.8471 | 42.9% | 0% | 0.9848 |
|
| 76 |
+
| 34000 | anti_loop | **3.4540** | 100% | 0% | 183.0 | 183.0 | 0.5750 | 0.9567 | 0% | 0% | 0.9262 |
|
| 77 |
+
| 34000 | balanced | 2.0965 | 100% | 0% | 312.1 | 256.0 | 0.4833 | 0.8582 | 71.4% | 14.3% | 0.9286 |
|
| 78 |
+
| 34000 | creative | 2.3089 | 85.7% | 14.3% | 299.4 | 220.0 | 0.5312 | 0.9237 | 28.6% | 14.3% | 0.9203 |
|
| 79 |
+
| 34200 | anti_loop_conservative | 3.0936 | 85.7% | 14.3% | 265.9 | 66.0 | 0.4779 | 0.8545 | 14.3% | 0% | 0.7850 |
|
| 80 |
+
| 34200 | anti_loop | 3.0177 | 100% | 0% | 268.0 | 243.0 | 0.5552 | 0.9439 | 0% | 0% | 0.9259 |
|
| 81 |
+
| 34200 | balanced | 2.5360 | 100% | 0% | 202.7 | 146.0 | 0.5922 | 0.9508 | 28.6% | 0% | 0.9286 |
|
| 82 |
+
| 34200 | creative | **3.1683** | 100% | 0% | 410.6 | 392.0 | 0.5119 | 0.9531 | 0% | 0% | 0.9339 |
|
| 83 |
+
| 34800 | anti_loop_conservative | 2.5619 | 85.7% | 14.3% | 279.3 | 130.0 | 0.5378 | 0.7822 | 28.6% | 14.3% | 0.8571 |
|
| 84 |
+
| 34800 | anti_loop | 2.5392 | 85.7% | 14.3% | 258.9 | 133.0 | 0.5580 | 0.9134 | 28.6% | 0% | 0.9259 |
|
| 85 |
+
| 34800 | balanced | 2.6047 | 100% | 0% | 98.1 | 57.0 | 0.5764 | 0.9290 | 14.3% | 0% | 0.9286 |
|
| 86 |
+
| 34800 | creative | **2.8813** | 100% | 0% | 323.4 | 95.0 | 0.5315 | **0.9591** | 14.3% | 0% | 0.9263 |
|
| 87 |
+
|
| 88 |
+
Tuning winners:
|
| 89 |
+
|
| 90 |
+
- `step_34000`: `anti_loop`
|
| 91 |
+
- `step_34200`: `creative`
|
| 92 |
+
- `step_34800`: `creative`
|
| 93 |
+
|
| 94 |
+
## Complete holdout table
|
| 95 |
+
|
| 96 |
+
| checkpoint | preset | score | EOS | trunc. | mean | median | distinct-1 | distinct-2 | rep | loop | lang. consistency |
|
| 97 |
+
|---|---|---:|---:|---:|---:|---:|---:|---:|---:|---:|---:|
|
| 98 |
+
| 34000 | anti_loop_conservative | 3.4012 | 100% | 0% | 129.5 | 110.5 | 0.6005 | 0.9024 | 25% | 0% | 1.0000 |
|
| 99 |
+
| 34000 | anti_loop | **3.6036** | 100% | 0% | 265.5 | 199.5 | 0.6262 | 0.9524 | 25% | 0% | 1.0000 |
|
| 100 |
+
| 34000 | balanced | 3.1137 | 100% | 0% | 205.0 | 195.0 | 0.5928 | 0.9180 | 50% | 0% | 0.9886 |
|
| 101 |
+
| 34000 | creative | 3.3935 | 100% | 0% | 322.0 | 358.0 | 0.6184 | **0.9644** | 0% | 0% | 1.0000 |
|
| 102 |
+
| 34200 | anti_loop_conservative | 3.0267 | 100% | 0% | 142.0 | 127.5 | 0.6136 | 0.8899 | 50% | 0% | 1.0000 |
|
| 103 |
+
| 34200 | anti_loop | 3.5983 | 100% | 0% | 285.0 | 351.5 | 0.6158 | 0.9389 | 25% | 0% | 0.9931 |
|
| 104 |
+
| 34200 | balanced | 2.5511 | 100% | 0% | 157.5 | 112.0 | **0.6856** | 0.9550 | 0% | 0% | 1.0000 |
|
| 105 |
+
| 34200 | creative | **3.8405** | 100% | 0% | **494.8** | **582.5** | 0.5777 | 0.9536 | 25% | 0% | 1.0000 |
|
| 106 |
+
| 34800 | anti_loop_conservative | 3.5655 | 75% | 25% | 348.0 | 192.0 | 0.5101 | 0.8564 | 25% | 0% | 0.9975 |
|
| 107 |
+
| 34800 | anti_loop | 3.5889 | 100% | 0% | 224.0 | 184.0 | 0.6499 | 0.9696 | 25% | 0% | 1.0000 |
|
| 108 |
+
| 34800 | balanced | **3.8743** | 100% | 0% | 141.8 | 149.5 | 0.6645 | 0.9621 | 0% | 0% | 1.0000 |
|
| 109 |
+
| 34800 | creative | 2.8716 | 100% | 0% | 179.0 | 159.0 | **0.6790** | 0.9591 | 25% | 0% | 1.0000 |
|
| 110 |
+
|
| 111 |
+
Holdout winners by checkpoint:
|
| 112 |
+
|
| 113 |
+
- `step_34000`: `anti_loop`
|
| 114 |
+
- `step_34200`: `creative`
|
| 115 |
+
- `step_34800`: `balanced`
|
| 116 |
+
|
| 117 |
+
The `step_34200` tuning winner is confirmed by holdout. The `step_34800` tuning
|
| 118 |
+
winner is not confirmed: holdout prefers `balanced`, but that preset terminates at
|
| 119 |
+
only 141.8 tokens on average. That shortness is treated as a weakness, not a bonus.
|
| 120 |
+
|
| 121 |
+
## First degeneration / loop analysis
|
| 122 |
+
|
| 123 |
+
The first-loop metric is conservative: it reports the first generated word position
|
| 124 |
+
where a 4-gram has appeared three times. When no such event occurs, the value is
|
| 125 |
+
`none`; first repeated-4gram position is also tracked separately.
|
| 126 |
+
|
| 127 |
+
### Tuning observations
|
| 128 |
+
|
| 129 |
+
- `step_34000 + anti_loop`: no repeated 4-gram and no loop across all 7 samples.
|
| 130 |
+
- `step_34200 + creative`: no repeated 4-gram and no loop across all 7 samples.
|
| 131 |
+
- `step_34800 + creative`: one repeated 4-gram sample, but no strict loop.
|
| 132 |
+
- `step_34000 + balanced`: first strict loop at token 41 in one sample; repeated-4gram rate 71.4%.
|
| 133 |
+
- `step_34000 + creative`: first strict loop at mean token 142 in one sample.
|
| 134 |
+
- `step_34800 + anti_loop_conservative`: one strict loop, first occurring at token 248.
|
| 135 |
+
|
| 136 |
+
### Holdout observations
|
| 137 |
+
|
| 138 |
+
No holdout configuration produced a strict loop (`loop_rate=0%`). Repeated 4-grams
|
| 139 |
+
remain in several cases, especially `step_34200 + creative` and the anti-loop
|
| 140 |
+
variants, but they occur without reaching the stricter three-repetition threshold.
|
| 141 |
+
|
| 142 |
+
## Qualitative inspection
|
| 143 |
+
|
| 144 |
+
Representative long generations were inspected for factuality, relevance, language
|
| 145 |
+
stability and late degeneration.
|
| 146 |
+
|
| 147 |
+
- `step_34000 + anti_loop` is the most controlled: it reaches EOS consistently and
|
| 148 |
+
avoids strict loops, but often produces conservative encyclopedic continuations
|
| 149 |
+
with factual drift (for example, Paris geography and historical details).
|
| 150 |
+
- `step_34200 + creative` produces the longest useful continuations. It stays in the
|
| 151 |
+
requested language and avoids strict loops, but factual/semantic drift appears in
|
| 152 |
+
long completions. The issue is quality drift, not a decoding collapse.
|
| 153 |
+
- `step_34800 + creative` is lively and diverse, but is less stable as a checkpoint
|
| 154 |
+
choice: tuning and holdout select different presets, and the median tuning length
|
| 155 |
+
is only 95 tokens despite a 1000-token allowance.
|
| 156 |
+
- `balanced` on `step_34800` wins the raw holdout score mainly with short, clean
|
| 157 |
+
completions. It is rejected as the final preset because early EOS must not be
|
| 158 |
+
mistaken for superior long-form behavior.
|
| 159 |
+
|
| 160 |
+
No preset systematically truncates on the selected final pair `step_34200 + creative`.
|
| 161 |
+
The main remaining limitation is factual/semantic degradation in long text, not
|
| 162 |
+
EOS handling, language switching or strict repetition loops.
|
| 163 |
+
|
| 164 |
+
## Final operational recommendation
|
| 165 |
+
|
| 166 |
+
### Definitive candidate
|
| 167 |
+
|
| 168 |
+
Keep and use:
|
| 169 |
+
|
| 170 |
+
```text
|
| 171 |
+
checkpoint: /mnt/apps/llm-nanochat/checkpoints/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki/step_34200.pt
|
| 172 |
+
preset: creative
|
| 173 |
+
```
|
| 174 |
+
|
| 175 |
+
Reason: tuning winner confirmed by holdout, zero truncation, zero strict loops,
|
| 176 |
+
longest useful completions, high distinct-2, and stable EN/IT language behavior.
|
| 177 |
+
|
| 178 |
+
### Behavior-oriented alternative
|
| 179 |
+
|
| 180 |
+
Keep as a conservative fallback:
|
| 181 |
+
|
| 182 |
+
```text
|
| 183 |
+
checkpoint: /mnt/apps/llm-nanochat/checkpoints/20260703_continual-pretraining-gpt2medium-gpt2preln-k20-step14700-lr5e5-w500-s18500-d2000-final1e5-webwiki/step_34000.pt
|
| 184 |
+
preset: anti_loop
|
| 185 |
+
```
|
| 186 |
+
|
| 187 |
+
This pair is the most robust against repetition and is confirmed by holdout, at the
|
| 188 |
+
cost of shorter and less expressive completions.
|
| 189 |
+
|
| 190 |
+
### Retention and deletion candidates
|
| 191 |
+
|
| 192 |
+
Retain now:
|
| 193 |
+
|
| 194 |
+
1. `step_34200.pt` — definitive candidate with `creative`
|
| 195 |
+
2. `step_34000.pt` — parent/reference and conservative fallback with `anti_loop`
|
| 196 |
+
3. `step_34800.pt` — behavior experiment retained until the final release decision
|
| 197 |
+
|
| 198 |
+
Potentially eliminable only after explicit confirmation:
|
| 199 |
+
|
| 200 |
+
- `step_34800.pt`, if the project keeps only the definitive candidate plus parent
|
| 201 |
+
reference.
|
| 202 |
+
|
| 203 |
+
No checkpoint was deleted by this operation. The other 34k-tail checkpoints were
|
| 204 |
+
not part of this three-candidate comparison and are outside this cleanup decision.
|
| 205 |
+
|
| 206 |
+
## Raw artifacts
|
| 207 |
+
|
| 208 |
+
- Config:
|
| 209 |
+
`configs/eval/20260716_medium_checkpoint_decoding_grid_1000.yaml`
|
| 210 |
+
- Output root:
|
| 211 |
+
`/mnt/apps/llm-nanochat/evals/20260716_medium_checkpoint_decoding_grid_1000`
|
| 212 |
+
- Parent output:
|
| 213 |
+
`/mnt/apps/llm-nanochat/evals/20260716_medium_checkpoint_decoding_grid_1000/parent_step34000`
|
| 214 |
+
- Scalar output:
|
| 215 |
+
`/mnt/apps/llm-nanochat/evals/20260716_medium_checkpoint_decoding_grid_1000/scalar_step34200`
|
| 216 |
+
- Behavior output:
|
| 217 |
+
`/mnt/apps/llm-nanochat/evals/20260716_medium_checkpoint_decoding_grid_1000/behavior_step34800`
|
| 218 |
+
- Launch log:
|
| 219 |
+
`/mnt/apps/llm-nanochat/launch_logs/20260716_135423_decoding_grid_medium_three_checkpoints_1000.log`
|
export_command.json
ADDED
|
@@ -0,0 +1,519 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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 7 |
+
0.95
|
| 8 |
+
],
|
| 9 |
+
"adamw_eps": 1e-08,
|
| 10 |
+
"architecture": "gpt2",
|
| 11 |
+
"attention_kernel_policy": "auto",
|
| 12 |
+
"batch_size": 2,
|
| 13 |
+
"benchmark": {
|
| 14 |
+
"enable_central_tensorboard": true,
|
| 15 |
+
"enable_local_tensorboard": true,
|
| 16 |
+
"enabled": false,
|
| 17 |
+
"output_path": "/mnt/apps/llm-nanochat/artifacts/runs/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki/throughput_benchmark.json",
|
| 18 |
+
"warmup_steps": 0
|
| 19 |
+
},
|
| 20 |
+
"bias": true,
|
| 21 |
+
"block_type": "gpt2_prelayernorm",
|
| 22 |
+
"causal_mask_mode": "buffered_upper_triangular",
|
| 23 |
+
"checkpoint_dir": "/mnt/apps/llm-nanochat/checkpoints/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki",
|
| 24 |
+
"clip_grad_norm": 1.0,
|
| 25 |
+
"compile": {
|
| 26 |
+
"backend": null,
|
| 27 |
+
"compile_setup_sec": 0.0,
|
| 28 |
+
"diagnostic": null,
|
| 29 |
+
"dynamic": false,
|
| 30 |
+
"enabled": false,
|
| 31 |
+
"error_policy": "raise",
|
| 32 |
+
"fullgraph": false,
|
| 33 |
+
"mode": null,
|
| 34 |
+
"requested": false,
|
| 35 |
+
"status": "disabled"
|
| 36 |
+
},
|
| 37 |
+
"dataset": {
|
| 38 |
+
"storage_mode": "indexed_jsonl"
|
| 39 |
+
},
|
| 40 |
+
"dataset_dir": "/mnt/apps/llm-nanochat/datasets/202605141153_fineweb50_wiki50_50en_50it_score100_2500context_5Btokens_tok_20260515_en50it50_webwiki_stratified_500M",
|
| 41 |
+
"decay_shape": "inverse_proportional",
|
| 42 |
+
"decay_steps": 1700,
|
| 43 |
+
"decay_steps_source": "explicit",
|
| 44 |
+
"deterministic_algorithms": false,
|
| 45 |
+
"device": "cuda",
|
| 46 |
+
"dim": 1024,
|
| 47 |
+
"dropout": 0.0,
|
| 48 |
+
"effective_global_step": 34200,
|
| 49 |
+
"effective_layer_count": 24,
|
| 50 |
+
"effective_learning_rate": 3.309994670030697e-05,
|
| 51 |
+
"final_lr": 1e-05,
|
| 52 |
+
"final_lr_source": "explicit",
|
| 53 |
+
"fp8_backend": null,
|
| 54 |
+
"grad_accum_steps": 48,
|
| 55 |
+
"init_from": "/mnt/apps/llm-nanochat/checkpoints/20260703_continual-pretraining-gpt2medium-gpt2preln-k20-step14700-lr5e5-w500-s18500-d2000-final1e5-webwiki/step_34000.pt",
|
| 56 |
+
"init_strategy": "gpt2_std_0.02_residual_scale",
|
| 57 |
+
"learning_rate": 4.7832243797285384e-05,
|
| 58 |
+
"local_max_steps": 35700,
|
| 59 |
+
"local_step": 200,
|
| 60 |
+
"logging": {
|
| 61 |
+
"enable_central_tensorboard": true,
|
| 62 |
+
"enable_local_tensorboard": true,
|
| 63 |
+
"metrics_flush_every_steps": 1,
|
| 64 |
+
"metrics_writer": "persistent_jsonl_handle"
|
| 65 |
+
},
|
| 66 |
+
"lr": 4.7832243797285384e-05,
|
| 67 |
+
"lr_schedule": "wsd-decay-only",
|
| 68 |
+
"max_seq_len": 2500,
|
| 69 |
+
"max_steps": 35700,
|
| 70 |
+
"n_heads": 16,
|
| 71 |
+
"n_layers": 24,
|
| 72 |
+
"norm_order": "preln",
|
| 73 |
+
"norm_type": "layernorm",
|
| 74 |
+
"optimizer": {
|
| 75 |
+
"backend": "torch",
|
| 76 |
+
"betas": [
|
| 77 |
+
0.9,
|
| 78 |
+
0.95
|
| 79 |
+
],
|
| 80 |
+
"eps": 1e-08,
|
| 81 |
+
"implementation": "torch.optim.AdamW",
|
| 82 |
+
"learning_rate": 4.7832243797285384e-05,
|
| 83 |
+
"state_precision": "full_precision",
|
| 84 |
+
"type": "adamw",
|
| 85 |
+
"weight_decay": 0.1
|
| 86 |
+
},
|
| 87 |
+
"optimizer_backend": "torch",
|
| 88 |
+
"optimizer_implementation": "torch.optim.AdamW",
|
| 89 |
+
"optimizer_reset": false,
|
| 90 |
+
"optimizer_state_precision": "full_precision",
|
| 91 |
+
"optimizer_type": "adamw",
|
| 92 |
+
"peak_lr": 4.7832243797285384e-05,
|
| 93 |
+
"positional_encoding": "learned_absolute",
|
| 94 |
+
"repro": {
|
| 95 |
+
"attention_kernel_policy": "auto",
|
| 96 |
+
"cublas_workspace_config": null,
|
| 97 |
+
"cudnn_benchmark": true,
|
| 98 |
+
"cudnn_deterministic": false,
|
| 99 |
+
"deterministic_algorithms": false,
|
| 100 |
+
"flash_sdp_enabled": true,
|
| 101 |
+
"math_sdp_enabled": true,
|
| 102 |
+
"mem_efficient_sdp_enabled": true,
|
| 103 |
+
"pythonhashseed": "1337",
|
| 104 |
+
"seed": 1337
|
| 105 |
+
},
|
| 106 |
+
"requested_precision": "bf16",
|
| 107 |
+
"resume_checkpoint_step": 34000,
|
| 108 |
+
"resume_from": "/mnt/apps/llm-nanochat/checkpoints/20260703_continual-pretraining-gpt2medium-gpt2preln-k20-step14700-lr5e5-w500-s18500-d2000-final1e5-webwiki/step_34000.pt",
|
| 109 |
+
"resume_mode": "optimizer_only",
|
| 110 |
+
"resume_step": 34000,
|
| 111 |
+
"save_every_steps": 100,
|
| 112 |
+
"save_final_checkpoint": true,
|
| 113 |
+
"schedule_total_steps": 35700,
|
| 114 |
+
"scheduler": {
|
| 115 |
+
"decay_shape": "inverse_proportional",
|
| 116 |
+
"decay_steps": 1700,
|
| 117 |
+
"decay_steps_source": "explicit",
|
| 118 |
+
"final_lr": 1e-05,
|
| 119 |
+
"final_lr_source": "explicit",
|
| 120 |
+
"peak_lr": 4.7832243797285384e-05,
|
| 121 |
+
"resume_step": 34000,
|
| 122 |
+
"schedule_type": "wsd-decay-only",
|
| 123 |
+
"stable_steps": 0,
|
| 124 |
+
"target_final_step": 35700,
|
| 125 |
+
"total_steps": 35700,
|
| 126 |
+
"warmup_steps": 0
|
| 127 |
+
},
|
| 128 |
+
"scheduler_reset": true,
|
| 129 |
+
"seed": 1337,
|
| 130 |
+
"source_global_step": 34000,
|
| 131 |
+
"stable_steps": 0,
|
| 132 |
+
"target_final_step": 35700,
|
| 133 |
+
"target_global_step": 35700,
|
| 134 |
+
"tie_word_embeddings": true,
|
| 135 |
+
"train_cache_ram_bytes": 1073741824,
|
| 136 |
+
"train_cache_ram_mb": 1024,
|
| 137 |
+
"vocab_size": 32000,
|
| 138 |
+
"warmup_steps": 0,
|
| 139 |
+
"weight_decay": 0.1
|
| 140 |
+
},
|
| 141 |
+
"checkpoint_path": "/mnt/apps/llm-nanochat/checkpoints/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki/step_34200.pt",
|
| 142 |
+
"config_path": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/config.json",
|
| 143 |
+
"exported_at": "2026-07-16T13:41:05.693620+00:00",
|
| 144 |
+
"format": "llm-nanochat-safetensors-export",
|
| 145 |
+
"global_step": 34200,
|
| 146 |
+
"metadata_path": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/step_34200.safetensors.json",
|
| 147 |
+
"model_config": {
|
| 148 |
+
"activation": "gelu",
|
| 149 |
+
"architecture": "gpt2",
|
| 150 |
+
"bias": true,
|
| 151 |
+
"block_type": "gpt2_prelayernorm",
|
| 152 |
+
"causal_mask_mode": "buffered_upper_triangular",
|
| 153 |
+
"dim": 1024,
|
| 154 |
+
"dropout": 0.0,
|
| 155 |
+
"init_strategy": "gpt2_std_0.02_residual_scale",
|
| 156 |
+
"max_seq_len": 2500,
|
| 157 |
+
"n_heads": 16,
|
| 158 |
+
"n_layers": 24,
|
| 159 |
+
"norm_order": "preln",
|
| 160 |
+
"norm_type": "layernorm",
|
| 161 |
+
"positional_encoding": "learned_absolute",
|
| 162 |
+
"tie_word_embeddings": true,
|
| 163 |
+
"vocab_size": 32000
|
| 164 |
+
},
|
| 165 |
+
"num_parameters": 370439424,
|
| 166 |
+
"num_tensors": 294,
|
| 167 |
+
"provenance": {
|
| 168 |
+
"checkpoint_dir": "/mnt/apps/llm-nanochat/checkpoints/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki",
|
| 169 |
+
"checkpoint_name": "step_34200.pt",
|
| 170 |
+
"checkpoint_path": "/mnt/apps/llm-nanochat/checkpoints/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki/step_34200.pt",
|
| 171 |
+
"global_step": 34200,
|
| 172 |
+
"packed_dataset_config_path": null,
|
| 173 |
+
"run_dir": "/mnt/apps/llm-nanochat/checkpoints",
|
| 174 |
+
"tokenizer_dir": "/mnt/apps/llm-nanochat/tokenizers/tokenizer_20260515_en50it50_webwiki_stratified_500M",
|
| 175 |
+
"training_config_path": null
|
| 176 |
+
},
|
| 177 |
+
"safetensors_path": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/step_34200.safetensors",
|
| 178 |
+
"source_checkpoint_path": "/mnt/apps/llm-nanochat/checkpoints/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki/step_34200.pt",
|
| 179 |
+
"source_global_step": 34200,
|
| 180 |
+
"tensor_names": [
|
| 181 |
+
"token_emb.weight",
|
| 182 |
+
"pos_emb.weight",
|
| 183 |
+
"blocks.0.ln_1.weight",
|
| 184 |
+
"blocks.0.ln_1.bias",
|
| 185 |
+
"blocks.0.ln_2.weight",
|
| 186 |
+
"blocks.0.ln_2.bias",
|
| 187 |
+
"blocks.0.attn.qkv.weight",
|
| 188 |
+
"blocks.0.attn.qkv.bias",
|
| 189 |
+
"blocks.0.attn.out_proj.weight",
|
| 190 |
+
"blocks.0.attn.out_proj.bias",
|
| 191 |
+
"blocks.0.mlp.fc.weight",
|
| 192 |
+
"blocks.0.mlp.fc.bias",
|
| 193 |
+
"blocks.0.mlp.proj.weight",
|
| 194 |
+
"blocks.0.mlp.proj.bias",
|
| 195 |
+
"blocks.1.ln_1.weight",
|
| 196 |
+
"blocks.1.ln_1.bias",
|
| 197 |
+
"blocks.1.ln_2.weight",
|
| 198 |
+
"blocks.1.ln_2.bias",
|
| 199 |
+
"blocks.1.attn.qkv.weight",
|
| 200 |
+
"blocks.1.attn.qkv.bias",
|
| 201 |
+
"blocks.1.attn.out_proj.weight",
|
| 202 |
+
"blocks.1.attn.out_proj.bias",
|
| 203 |
+
"blocks.1.mlp.fc.weight",
|
| 204 |
+
"blocks.1.mlp.fc.bias",
|
| 205 |
+
"blocks.1.mlp.proj.weight",
|
| 206 |
+
"blocks.1.mlp.proj.bias",
|
| 207 |
+
"blocks.2.ln_1.weight",
|
| 208 |
+
"blocks.2.ln_1.bias",
|
| 209 |
+
"blocks.2.ln_2.weight",
|
| 210 |
+
"blocks.2.ln_2.bias",
|
| 211 |
+
"blocks.2.attn.qkv.weight",
|
| 212 |
+
"blocks.2.attn.qkv.bias",
|
| 213 |
+
"blocks.2.attn.out_proj.weight",
|
| 214 |
+
"blocks.2.attn.out_proj.bias",
|
| 215 |
+
"blocks.2.mlp.fc.weight",
|
| 216 |
+
"blocks.2.mlp.fc.bias",
|
| 217 |
+
"blocks.2.mlp.proj.weight",
|
| 218 |
+
"blocks.2.mlp.proj.bias",
|
| 219 |
+
"blocks.3.ln_1.weight",
|
| 220 |
+
"blocks.3.ln_1.bias",
|
| 221 |
+
"blocks.3.ln_2.weight",
|
| 222 |
+
"blocks.3.ln_2.bias",
|
| 223 |
+
"blocks.3.attn.qkv.weight",
|
| 224 |
+
"blocks.3.attn.qkv.bias",
|
| 225 |
+
"blocks.3.attn.out_proj.weight",
|
| 226 |
+
"blocks.3.attn.out_proj.bias",
|
| 227 |
+
"blocks.3.mlp.fc.weight",
|
| 228 |
+
"blocks.3.mlp.fc.bias",
|
| 229 |
+
"blocks.3.mlp.proj.weight",
|
| 230 |
+
"blocks.3.mlp.proj.bias",
|
| 231 |
+
"blocks.4.ln_1.weight",
|
| 232 |
+
"blocks.4.ln_1.bias",
|
| 233 |
+
"blocks.4.ln_2.weight",
|
| 234 |
+
"blocks.4.ln_2.bias",
|
| 235 |
+
"blocks.4.attn.qkv.weight",
|
| 236 |
+
"blocks.4.attn.qkv.bias",
|
| 237 |
+
"blocks.4.attn.out_proj.weight",
|
| 238 |
+
"blocks.4.attn.out_proj.bias",
|
| 239 |
+
"blocks.4.mlp.fc.weight",
|
| 240 |
+
"blocks.4.mlp.fc.bias",
|
| 241 |
+
"blocks.4.mlp.proj.weight",
|
| 242 |
+
"blocks.4.mlp.proj.bias",
|
| 243 |
+
"blocks.5.ln_1.weight",
|
| 244 |
+
"blocks.5.ln_1.bias",
|
| 245 |
+
"blocks.5.ln_2.weight",
|
| 246 |
+
"blocks.5.ln_2.bias",
|
| 247 |
+
"blocks.5.attn.qkv.weight",
|
| 248 |
+
"blocks.5.attn.qkv.bias",
|
| 249 |
+
"blocks.5.attn.out_proj.weight",
|
| 250 |
+
"blocks.5.attn.out_proj.bias",
|
| 251 |
+
"blocks.5.mlp.fc.weight",
|
| 252 |
+
"blocks.5.mlp.fc.bias",
|
| 253 |
+
"blocks.5.mlp.proj.weight",
|
| 254 |
+
"blocks.5.mlp.proj.bias",
|
| 255 |
+
"blocks.6.ln_1.weight",
|
| 256 |
+
"blocks.6.ln_1.bias",
|
| 257 |
+
"blocks.6.ln_2.weight",
|
| 258 |
+
"blocks.6.ln_2.bias",
|
| 259 |
+
"blocks.6.attn.qkv.weight",
|
| 260 |
+
"blocks.6.attn.qkv.bias",
|
| 261 |
+
"blocks.6.attn.out_proj.weight",
|
| 262 |
+
"blocks.6.attn.out_proj.bias",
|
| 263 |
+
"blocks.6.mlp.fc.weight",
|
| 264 |
+
"blocks.6.mlp.fc.bias",
|
| 265 |
+
"blocks.6.mlp.proj.weight",
|
| 266 |
+
"blocks.6.mlp.proj.bias",
|
| 267 |
+
"blocks.7.ln_1.weight",
|
| 268 |
+
"blocks.7.ln_1.bias",
|
| 269 |
+
"blocks.7.ln_2.weight",
|
| 270 |
+
"blocks.7.ln_2.bias",
|
| 271 |
+
"blocks.7.attn.qkv.weight",
|
| 272 |
+
"blocks.7.attn.qkv.bias",
|
| 273 |
+
"blocks.7.attn.out_proj.weight",
|
| 274 |
+
"blocks.7.attn.out_proj.bias",
|
| 275 |
+
"blocks.7.mlp.fc.weight",
|
| 276 |
+
"blocks.7.mlp.fc.bias",
|
| 277 |
+
"blocks.7.mlp.proj.weight",
|
| 278 |
+
"blocks.7.mlp.proj.bias",
|
| 279 |
+
"blocks.8.ln_1.weight",
|
| 280 |
+
"blocks.8.ln_1.bias",
|
| 281 |
+
"blocks.8.ln_2.weight",
|
| 282 |
+
"blocks.8.ln_2.bias",
|
| 283 |
+
"blocks.8.attn.qkv.weight",
|
| 284 |
+
"blocks.8.attn.qkv.bias",
|
| 285 |
+
"blocks.8.attn.out_proj.weight",
|
| 286 |
+
"blocks.8.attn.out_proj.bias",
|
| 287 |
+
"blocks.8.mlp.fc.weight",
|
| 288 |
+
"blocks.8.mlp.fc.bias",
|
| 289 |
+
"blocks.8.mlp.proj.weight",
|
| 290 |
+
"blocks.8.mlp.proj.bias",
|
| 291 |
+
"blocks.9.ln_1.weight",
|
| 292 |
+
"blocks.9.ln_1.bias",
|
| 293 |
+
"blocks.9.ln_2.weight",
|
| 294 |
+
"blocks.9.ln_2.bias",
|
| 295 |
+
"blocks.9.attn.qkv.weight",
|
| 296 |
+
"blocks.9.attn.qkv.bias",
|
| 297 |
+
"blocks.9.attn.out_proj.weight",
|
| 298 |
+
"blocks.9.attn.out_proj.bias",
|
| 299 |
+
"blocks.9.mlp.fc.weight",
|
| 300 |
+
"blocks.9.mlp.fc.bias",
|
| 301 |
+
"blocks.9.mlp.proj.weight",
|
| 302 |
+
"blocks.9.mlp.proj.bias",
|
| 303 |
+
"blocks.10.ln_1.weight",
|
| 304 |
+
"blocks.10.ln_1.bias",
|
| 305 |
+
"blocks.10.ln_2.weight",
|
| 306 |
+
"blocks.10.ln_2.bias",
|
| 307 |
+
"blocks.10.attn.qkv.weight",
|
| 308 |
+
"blocks.10.attn.qkv.bias",
|
| 309 |
+
"blocks.10.attn.out_proj.weight",
|
| 310 |
+
"blocks.10.attn.out_proj.bias",
|
| 311 |
+
"blocks.10.mlp.fc.weight",
|
| 312 |
+
"blocks.10.mlp.fc.bias",
|
| 313 |
+
"blocks.10.mlp.proj.weight",
|
| 314 |
+
"blocks.10.mlp.proj.bias",
|
| 315 |
+
"blocks.11.ln_1.weight",
|
| 316 |
+
"blocks.11.ln_1.bias",
|
| 317 |
+
"blocks.11.ln_2.weight",
|
| 318 |
+
"blocks.11.ln_2.bias",
|
| 319 |
+
"blocks.11.attn.qkv.weight",
|
| 320 |
+
"blocks.11.attn.qkv.bias",
|
| 321 |
+
"blocks.11.attn.out_proj.weight",
|
| 322 |
+
"blocks.11.attn.out_proj.bias",
|
| 323 |
+
"blocks.11.mlp.fc.weight",
|
| 324 |
+
"blocks.11.mlp.fc.bias",
|
| 325 |
+
"blocks.11.mlp.proj.weight",
|
| 326 |
+
"blocks.11.mlp.proj.bias",
|
| 327 |
+
"blocks.12.ln_1.weight",
|
| 328 |
+
"blocks.12.ln_1.bias",
|
| 329 |
+
"blocks.12.ln_2.weight",
|
| 330 |
+
"blocks.12.ln_2.bias",
|
| 331 |
+
"blocks.12.attn.qkv.weight",
|
| 332 |
+
"blocks.12.attn.qkv.bias",
|
| 333 |
+
"blocks.12.attn.out_proj.weight",
|
| 334 |
+
"blocks.12.attn.out_proj.bias",
|
| 335 |
+
"blocks.12.mlp.fc.weight",
|
| 336 |
+
"blocks.12.mlp.fc.bias",
|
| 337 |
+
"blocks.12.mlp.proj.weight",
|
| 338 |
+
"blocks.12.mlp.proj.bias",
|
| 339 |
+
"blocks.13.ln_1.weight",
|
| 340 |
+
"blocks.13.ln_1.bias",
|
| 341 |
+
"blocks.13.ln_2.weight",
|
| 342 |
+
"blocks.13.ln_2.bias",
|
| 343 |
+
"blocks.13.attn.qkv.weight",
|
| 344 |
+
"blocks.13.attn.qkv.bias",
|
| 345 |
+
"blocks.13.attn.out_proj.weight",
|
| 346 |
+
"blocks.13.attn.out_proj.bias",
|
| 347 |
+
"blocks.13.mlp.fc.weight",
|
| 348 |
+
"blocks.13.mlp.fc.bias",
|
| 349 |
+
"blocks.13.mlp.proj.weight",
|
| 350 |
+
"blocks.13.mlp.proj.bias",
|
| 351 |
+
"blocks.14.ln_1.weight",
|
| 352 |
+
"blocks.14.ln_1.bias",
|
| 353 |
+
"blocks.14.ln_2.weight",
|
| 354 |
+
"blocks.14.ln_2.bias",
|
| 355 |
+
"blocks.14.attn.qkv.weight",
|
| 356 |
+
"blocks.14.attn.qkv.bias",
|
| 357 |
+
"blocks.14.attn.out_proj.weight",
|
| 358 |
+
"blocks.14.attn.out_proj.bias",
|
| 359 |
+
"blocks.14.mlp.fc.weight",
|
| 360 |
+
"blocks.14.mlp.fc.bias",
|
| 361 |
+
"blocks.14.mlp.proj.weight",
|
| 362 |
+
"blocks.14.mlp.proj.bias",
|
| 363 |
+
"blocks.15.ln_1.weight",
|
| 364 |
+
"blocks.15.ln_1.bias",
|
| 365 |
+
"blocks.15.ln_2.weight",
|
| 366 |
+
"blocks.15.ln_2.bias",
|
| 367 |
+
"blocks.15.attn.qkv.weight",
|
| 368 |
+
"blocks.15.attn.qkv.bias",
|
| 369 |
+
"blocks.15.attn.out_proj.weight",
|
| 370 |
+
"blocks.15.attn.out_proj.bias",
|
| 371 |
+
"blocks.15.mlp.fc.weight",
|
| 372 |
+
"blocks.15.mlp.fc.bias",
|
| 373 |
+
"blocks.15.mlp.proj.weight",
|
| 374 |
+
"blocks.15.mlp.proj.bias",
|
| 375 |
+
"blocks.16.ln_1.weight",
|
| 376 |
+
"blocks.16.ln_1.bias",
|
| 377 |
+
"blocks.16.ln_2.weight",
|
| 378 |
+
"blocks.16.ln_2.bias",
|
| 379 |
+
"blocks.16.attn.qkv.weight",
|
| 380 |
+
"blocks.16.attn.qkv.bias",
|
| 381 |
+
"blocks.16.attn.out_proj.weight",
|
| 382 |
+
"blocks.16.attn.out_proj.bias",
|
| 383 |
+
"blocks.16.mlp.fc.weight",
|
| 384 |
+
"blocks.16.mlp.fc.bias",
|
| 385 |
+
"blocks.16.mlp.proj.weight",
|
| 386 |
+
"blocks.16.mlp.proj.bias",
|
| 387 |
+
"blocks.17.ln_1.weight",
|
| 388 |
+
"blocks.17.ln_1.bias",
|
| 389 |
+
"blocks.17.ln_2.weight",
|
| 390 |
+
"blocks.17.ln_2.bias",
|
| 391 |
+
"blocks.17.attn.qkv.weight",
|
| 392 |
+
"blocks.17.attn.qkv.bias",
|
| 393 |
+
"blocks.17.attn.out_proj.weight",
|
| 394 |
+
"blocks.17.attn.out_proj.bias",
|
| 395 |
+
"blocks.17.mlp.fc.weight",
|
| 396 |
+
"blocks.17.mlp.fc.bias",
|
| 397 |
+
"blocks.17.mlp.proj.weight",
|
| 398 |
+
"blocks.17.mlp.proj.bias",
|
| 399 |
+
"blocks.18.ln_1.weight",
|
| 400 |
+
"blocks.18.ln_1.bias",
|
| 401 |
+
"blocks.18.ln_2.weight",
|
| 402 |
+
"blocks.18.ln_2.bias",
|
| 403 |
+
"blocks.18.attn.qkv.weight",
|
| 404 |
+
"blocks.18.attn.qkv.bias",
|
| 405 |
+
"blocks.18.attn.out_proj.weight",
|
| 406 |
+
"blocks.18.attn.out_proj.bias",
|
| 407 |
+
"blocks.18.mlp.fc.weight",
|
| 408 |
+
"blocks.18.mlp.fc.bias",
|
| 409 |
+
"blocks.18.mlp.proj.weight",
|
| 410 |
+
"blocks.18.mlp.proj.bias",
|
| 411 |
+
"blocks.19.ln_1.weight",
|
| 412 |
+
"blocks.19.ln_1.bias",
|
| 413 |
+
"blocks.19.ln_2.weight",
|
| 414 |
+
"blocks.19.ln_2.bias",
|
| 415 |
+
"blocks.19.attn.qkv.weight",
|
| 416 |
+
"blocks.19.attn.qkv.bias",
|
| 417 |
+
"blocks.19.attn.out_proj.weight",
|
| 418 |
+
"blocks.19.attn.out_proj.bias",
|
| 419 |
+
"blocks.19.mlp.fc.weight",
|
| 420 |
+
"blocks.19.mlp.fc.bias",
|
| 421 |
+
"blocks.19.mlp.proj.weight",
|
| 422 |
+
"blocks.19.mlp.proj.bias",
|
| 423 |
+
"blocks.20.ln_1.weight",
|
| 424 |
+
"blocks.20.ln_1.bias",
|
| 425 |
+
"blocks.20.ln_2.weight",
|
| 426 |
+
"blocks.20.ln_2.bias",
|
| 427 |
+
"blocks.20.attn.qkv.weight",
|
| 428 |
+
"blocks.20.attn.qkv.bias",
|
| 429 |
+
"blocks.20.attn.out_proj.weight",
|
| 430 |
+
"blocks.20.attn.out_proj.bias",
|
| 431 |
+
"blocks.20.mlp.fc.weight",
|
| 432 |
+
"blocks.20.mlp.fc.bias",
|
| 433 |
+
"blocks.20.mlp.proj.weight",
|
| 434 |
+
"blocks.20.mlp.proj.bias",
|
| 435 |
+
"blocks.21.ln_1.weight",
|
| 436 |
+
"blocks.21.ln_1.bias",
|
| 437 |
+
"blocks.21.ln_2.weight",
|
| 438 |
+
"blocks.21.ln_2.bias",
|
| 439 |
+
"blocks.21.attn.qkv.weight",
|
| 440 |
+
"blocks.21.attn.qkv.bias",
|
| 441 |
+
"blocks.21.attn.out_proj.weight",
|
| 442 |
+
"blocks.21.attn.out_proj.bias",
|
| 443 |
+
"blocks.21.mlp.fc.weight",
|
| 444 |
+
"blocks.21.mlp.fc.bias",
|
| 445 |
+
"blocks.21.mlp.proj.weight",
|
| 446 |
+
"blocks.21.mlp.proj.bias",
|
| 447 |
+
"blocks.22.ln_1.weight",
|
| 448 |
+
"blocks.22.ln_1.bias",
|
| 449 |
+
"blocks.22.ln_2.weight",
|
| 450 |
+
"blocks.22.ln_2.bias",
|
| 451 |
+
"blocks.22.attn.qkv.weight",
|
| 452 |
+
"blocks.22.attn.qkv.bias",
|
| 453 |
+
"blocks.22.attn.out_proj.weight",
|
| 454 |
+
"blocks.22.attn.out_proj.bias",
|
| 455 |
+
"blocks.22.mlp.fc.weight",
|
| 456 |
+
"blocks.22.mlp.fc.bias",
|
| 457 |
+
"blocks.22.mlp.proj.weight",
|
| 458 |
+
"blocks.22.mlp.proj.bias",
|
| 459 |
+
"blocks.23.ln_1.weight",
|
| 460 |
+
"blocks.23.ln_1.bias",
|
| 461 |
+
"blocks.23.ln_2.weight",
|
| 462 |
+
"blocks.23.ln_2.bias",
|
| 463 |
+
"blocks.23.attn.qkv.weight",
|
| 464 |
+
"blocks.23.attn.qkv.bias",
|
| 465 |
+
"blocks.23.attn.out_proj.weight",
|
| 466 |
+
"blocks.23.attn.out_proj.bias",
|
| 467 |
+
"blocks.23.mlp.fc.weight",
|
| 468 |
+
"blocks.23.mlp.fc.bias",
|
| 469 |
+
"blocks.23.mlp.proj.weight",
|
| 470 |
+
"blocks.23.mlp.proj.bias",
|
| 471 |
+
"ln_f.weight",
|
| 472 |
+
"ln_f.bias",
|
| 473 |
+
"head.weight",
|
| 474 |
+
"head.bias"
|
| 475 |
+
],
|
| 476 |
+
"tokenizer_bundle": {
|
| 477 |
+
"special_tokens_map.json": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/special_tokens_map.json",
|
| 478 |
+
"tokenizer.json": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/tokenizer.json",
|
| 479 |
+
"tokenizer_config.json": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/tokenizer_config.json",
|
| 480 |
+
"tokenizer_meta.json": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/tokenizer_meta.json"
|
| 481 |
+
},
|
| 482 |
+
"tokenizer_reference": {
|
| 483 |
+
"packed_dataset_config_path": null,
|
| 484 |
+
"tokenizer_dir": "/mnt/apps/llm-nanochat/tokenizers/tokenizer_20260515_en50it50_webwiki_stratified_500M",
|
| 485 |
+
"training_config_path": null
|
| 486 |
+
},
|
| 487 |
+
"transformers_config": {
|
| 488 |
+
"activation_function": "gelu",
|
| 489 |
+
"architecture": "gpt2",
|
| 490 |
+
"architectures": [
|
| 491 |
+
"GPT2LMHeadModel"
|
| 492 |
+
],
|
| 493 |
+
"attn_pdrop": 0.0,
|
| 494 |
+
"block_type": "gpt2_prelayernorm",
|
| 495 |
+
"causal_mask_mode": "buffered_upper_triangular",
|
| 496 |
+
"embd_pdrop": 0.0,
|
| 497 |
+
"init_strategy": "gpt2_std_0.02_residual_scale",
|
| 498 |
+
"layer_norm_epsilon": 1e-05,
|
| 499 |
+
"model_type": "gpt2",
|
| 500 |
+
"n_ctx": 2500,
|
| 501 |
+
"n_embd": 1024,
|
| 502 |
+
"n_head": 16,
|
| 503 |
+
"n_layer": 24,
|
| 504 |
+
"n_positions": 2500,
|
| 505 |
+
"norm_order": "preln",
|
| 506 |
+
"norm_type": "layernorm",
|
| 507 |
+
"positional_encoding": "learned_absolute",
|
| 508 |
+
"resid_pdrop": 0.0,
|
| 509 |
+
"tie_word_embeddings": true,
|
| 510 |
+
"use_cache": true,
|
| 511 |
+
"vocab_size": 32000
|
| 512 |
+
},
|
| 513 |
+
"transformers_export_notes": {
|
| 514 |
+
"dropped_lm_head_bias_for_gpt2_compat": true,
|
| 515 |
+
"dropped_lm_head_bias_max_abs": 1.3327739238739014,
|
| 516 |
+
"dropped_lm_head_bias_mean_abs": 0.046846117824316025
|
| 517 |
+
},
|
| 518 |
+
"transformers_safetensors_path": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/model.safetensors"
|
| 519 |
+
}
|
generation_config.json
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"bos_token_id": 1,
|
| 3 |
+
"eos_token_id": 2,
|
| 4 |
+
"pad_token_id": 0,
|
| 5 |
+
"do_sample": true,
|
| 6 |
+
"max_new_tokens": 1000,
|
| 7 |
+
"temperature": 1.0,
|
| 8 |
+
"top_k": 100,
|
| 9 |
+
"top_p": 0.95,
|
| 10 |
+
"repetition_penalty": 1.1,
|
| 11 |
+
"no_repeat_ngram_size": 0
|
| 12 |
+
}
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:e654d2b995c4a2cd293f4d55d7a6147351537298ba5109525e979ef8484e75d2
|
| 3 |
+
size 1350587904
|
recommended_decoding_params.json
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"checkpoint": "step_34200",
|
| 3 |
+
"preset": "creative",
|
| 4 |
+
"max_new_tokens": 1000,
|
| 5 |
+
"temperature": 1.0,
|
| 6 |
+
"top_k": 100,
|
| 7 |
+
"top_p": 0.95,
|
| 8 |
+
"repetition_penalty": 1.1,
|
| 9 |
+
"no_repeat_ngram_size": 0,
|
| 10 |
+
"eos_token_id": 2,
|
| 11 |
+
"pad_token_id": 0,
|
| 12 |
+
"evidence": {
|
| 13 |
+
"tuning_score": 3.1683,
|
| 14 |
+
"holdout_score": 3.8405,
|
| 15 |
+
"eos_rate_tuning": 1.0,
|
| 16 |
+
"eos_rate_holdout": 1.0,
|
| 17 |
+
"strict_loop_rate_tuning": 0.0,
|
| 18 |
+
"strict_loop_rate_holdout": 0.0
|
| 19 |
+
}
|
| 20 |
+
}
|
release_note.md
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
This is the definitive official `1gpu-llm-medium-v2` release.
|
| 2 |
+
|
| 3 |
+
It promotes checkpoint `step_34200` from the optimizer-preserving decay-only
|
| 4 |
+
continuation of the main medium CPT checkpoint `step_34000`.
|
| 5 |
+
|
| 6 |
+
The release was selected by the complete 1000-token tuning/holdout decoding
|
| 7 |
+
grid and is published with the official 1gpu-llm card image.
|
special_tokens_map.json
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"bos_token": "<bos>",
|
| 3 |
+
"eos_token": "<eos>",
|
| 4 |
+
"pad_token": "<pad>",
|
| 5 |
+
"unk_token": "<unk>"
|
| 6 |
+
}
|
step_34200.pt
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:aef70a6e99512059ed203375f82608083f2ce657b1f57f70e2cb06f055d28182
|
| 3 |
+
size 4052410819
|
step_34200.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:c5d59935e646531d069bce475d4220b0a82c28a7d0f1636c01b0d0db6441947a
|
| 3 |
+
size 1481791640
|
step_34200.safetensors.json
ADDED
|
@@ -0,0 +1,519 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
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|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"checkpoint_config": {
|
| 3 |
+
"activation": "gelu",
|
| 4 |
+
"actual_precision": "bf16",
|
| 5 |
+
"adamw_betas": [
|
| 6 |
+
0.9,
|
| 7 |
+
0.95
|
| 8 |
+
],
|
| 9 |
+
"adamw_eps": 1e-08,
|
| 10 |
+
"architecture": "gpt2",
|
| 11 |
+
"attention_kernel_policy": "auto",
|
| 12 |
+
"batch_size": 2,
|
| 13 |
+
"benchmark": {
|
| 14 |
+
"enable_central_tensorboard": true,
|
| 15 |
+
"enable_local_tensorboard": true,
|
| 16 |
+
"enabled": false,
|
| 17 |
+
"output_path": "/mnt/apps/llm-nanochat/artifacts/runs/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki/throughput_benchmark.json",
|
| 18 |
+
"warmup_steps": 0
|
| 19 |
+
},
|
| 20 |
+
"bias": true,
|
| 21 |
+
"block_type": "gpt2_prelayernorm",
|
| 22 |
+
"causal_mask_mode": "buffered_upper_triangular",
|
| 23 |
+
"checkpoint_dir": "/mnt/apps/llm-nanochat/checkpoints/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki",
|
| 24 |
+
"clip_grad_norm": 1.0,
|
| 25 |
+
"compile": {
|
| 26 |
+
"backend": null,
|
| 27 |
+
"compile_setup_sec": 0.0,
|
| 28 |
+
"diagnostic": null,
|
| 29 |
+
"dynamic": false,
|
| 30 |
+
"enabled": false,
|
| 31 |
+
"error_policy": "raise",
|
| 32 |
+
"fullgraph": false,
|
| 33 |
+
"mode": null,
|
| 34 |
+
"requested": false,
|
| 35 |
+
"status": "disabled"
|
| 36 |
+
},
|
| 37 |
+
"dataset": {
|
| 38 |
+
"storage_mode": "indexed_jsonl"
|
| 39 |
+
},
|
| 40 |
+
"dataset_dir": "/mnt/apps/llm-nanochat/datasets/202605141153_fineweb50_wiki50_50en_50it_score100_2500context_5Btokens_tok_20260515_en50it50_webwiki_stratified_500M",
|
| 41 |
+
"decay_shape": "inverse_proportional",
|
| 42 |
+
"decay_steps": 1700,
|
| 43 |
+
"decay_steps_source": "explicit",
|
| 44 |
+
"deterministic_algorithms": false,
|
| 45 |
+
"device": "cuda",
|
| 46 |
+
"dim": 1024,
|
| 47 |
+
"dropout": 0.0,
|
| 48 |
+
"effective_global_step": 34200,
|
| 49 |
+
"effective_layer_count": 24,
|
| 50 |
+
"effective_learning_rate": 3.309994670030697e-05,
|
| 51 |
+
"final_lr": 1e-05,
|
| 52 |
+
"final_lr_source": "explicit",
|
| 53 |
+
"fp8_backend": null,
|
| 54 |
+
"grad_accum_steps": 48,
|
| 55 |
+
"init_from": "/mnt/apps/llm-nanochat/checkpoints/20260703_continual-pretraining-gpt2medium-gpt2preln-k20-step14700-lr5e5-w500-s18500-d2000-final1e5-webwiki/step_34000.pt",
|
| 56 |
+
"init_strategy": "gpt2_std_0.02_residual_scale",
|
| 57 |
+
"learning_rate": 4.7832243797285384e-05,
|
| 58 |
+
"local_max_steps": 35700,
|
| 59 |
+
"local_step": 200,
|
| 60 |
+
"logging": {
|
| 61 |
+
"enable_central_tensorboard": true,
|
| 62 |
+
"enable_local_tensorboard": true,
|
| 63 |
+
"metrics_flush_every_steps": 1,
|
| 64 |
+
"metrics_writer": "persistent_jsonl_handle"
|
| 65 |
+
},
|
| 66 |
+
"lr": 4.7832243797285384e-05,
|
| 67 |
+
"lr_schedule": "wsd-decay-only",
|
| 68 |
+
"max_seq_len": 2500,
|
| 69 |
+
"max_steps": 35700,
|
| 70 |
+
"n_heads": 16,
|
| 71 |
+
"n_layers": 24,
|
| 72 |
+
"norm_order": "preln",
|
| 73 |
+
"norm_type": "layernorm",
|
| 74 |
+
"optimizer": {
|
| 75 |
+
"backend": "torch",
|
| 76 |
+
"betas": [
|
| 77 |
+
0.9,
|
| 78 |
+
0.95
|
| 79 |
+
],
|
| 80 |
+
"eps": 1e-08,
|
| 81 |
+
"implementation": "torch.optim.AdamW",
|
| 82 |
+
"learning_rate": 4.7832243797285384e-05,
|
| 83 |
+
"state_precision": "full_precision",
|
| 84 |
+
"type": "adamw",
|
| 85 |
+
"weight_decay": 0.1
|
| 86 |
+
},
|
| 87 |
+
"optimizer_backend": "torch",
|
| 88 |
+
"optimizer_implementation": "torch.optim.AdamW",
|
| 89 |
+
"optimizer_reset": false,
|
| 90 |
+
"optimizer_state_precision": "full_precision",
|
| 91 |
+
"optimizer_type": "adamw",
|
| 92 |
+
"peak_lr": 4.7832243797285384e-05,
|
| 93 |
+
"positional_encoding": "learned_absolute",
|
| 94 |
+
"repro": {
|
| 95 |
+
"attention_kernel_policy": "auto",
|
| 96 |
+
"cublas_workspace_config": null,
|
| 97 |
+
"cudnn_benchmark": true,
|
| 98 |
+
"cudnn_deterministic": false,
|
| 99 |
+
"deterministic_algorithms": false,
|
| 100 |
+
"flash_sdp_enabled": true,
|
| 101 |
+
"math_sdp_enabled": true,
|
| 102 |
+
"mem_efficient_sdp_enabled": true,
|
| 103 |
+
"pythonhashseed": "1337",
|
| 104 |
+
"seed": 1337
|
| 105 |
+
},
|
| 106 |
+
"requested_precision": "bf16",
|
| 107 |
+
"resume_checkpoint_step": 34000,
|
| 108 |
+
"resume_from": "/mnt/apps/llm-nanochat/checkpoints/20260703_continual-pretraining-gpt2medium-gpt2preln-k20-step14700-lr5e5-w500-s18500-d2000-final1e5-webwiki/step_34000.pt",
|
| 109 |
+
"resume_mode": "optimizer_only",
|
| 110 |
+
"resume_step": 34000,
|
| 111 |
+
"save_every_steps": 100,
|
| 112 |
+
"save_final_checkpoint": true,
|
| 113 |
+
"schedule_total_steps": 35700,
|
| 114 |
+
"scheduler": {
|
| 115 |
+
"decay_shape": "inverse_proportional",
|
| 116 |
+
"decay_steps": 1700,
|
| 117 |
+
"decay_steps_source": "explicit",
|
| 118 |
+
"final_lr": 1e-05,
|
| 119 |
+
"final_lr_source": "explicit",
|
| 120 |
+
"peak_lr": 4.7832243797285384e-05,
|
| 121 |
+
"resume_step": 34000,
|
| 122 |
+
"schedule_type": "wsd-decay-only",
|
| 123 |
+
"stable_steps": 0,
|
| 124 |
+
"target_final_step": 35700,
|
| 125 |
+
"total_steps": 35700,
|
| 126 |
+
"warmup_steps": 0
|
| 127 |
+
},
|
| 128 |
+
"scheduler_reset": true,
|
| 129 |
+
"seed": 1337,
|
| 130 |
+
"source_global_step": 34000,
|
| 131 |
+
"stable_steps": 0,
|
| 132 |
+
"target_final_step": 35700,
|
| 133 |
+
"target_global_step": 35700,
|
| 134 |
+
"tie_word_embeddings": true,
|
| 135 |
+
"train_cache_ram_bytes": 1073741824,
|
| 136 |
+
"train_cache_ram_mb": 1024,
|
| 137 |
+
"vocab_size": 32000,
|
| 138 |
+
"warmup_steps": 0,
|
| 139 |
+
"weight_decay": 0.1
|
| 140 |
+
},
|
| 141 |
+
"checkpoint_path": "/mnt/apps/llm-nanochat/checkpoints/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki/step_34200.pt",
|
| 142 |
+
"config_path": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/config.json",
|
| 143 |
+
"exported_at": "2026-07-16T13:41:05.693620+00:00",
|
| 144 |
+
"format": "llm-nanochat-safetensors-export",
|
| 145 |
+
"global_step": 34200,
|
| 146 |
+
"metadata_path": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/step_34200.safetensors.json",
|
| 147 |
+
"model_config": {
|
| 148 |
+
"activation": "gelu",
|
| 149 |
+
"architecture": "gpt2",
|
| 150 |
+
"bias": true,
|
| 151 |
+
"block_type": "gpt2_prelayernorm",
|
| 152 |
+
"causal_mask_mode": "buffered_upper_triangular",
|
| 153 |
+
"dim": 1024,
|
| 154 |
+
"dropout": 0.0,
|
| 155 |
+
"init_strategy": "gpt2_std_0.02_residual_scale",
|
| 156 |
+
"max_seq_len": 2500,
|
| 157 |
+
"n_heads": 16,
|
| 158 |
+
"n_layers": 24,
|
| 159 |
+
"norm_order": "preln",
|
| 160 |
+
"norm_type": "layernorm",
|
| 161 |
+
"positional_encoding": "learned_absolute",
|
| 162 |
+
"tie_word_embeddings": true,
|
| 163 |
+
"vocab_size": 32000
|
| 164 |
+
},
|
| 165 |
+
"num_parameters": 370439424,
|
| 166 |
+
"num_tensors": 294,
|
| 167 |
+
"provenance": {
|
| 168 |
+
"checkpoint_dir": "/mnt/apps/llm-nanochat/checkpoints/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki",
|
| 169 |
+
"checkpoint_name": "step_34200.pt",
|
| 170 |
+
"checkpoint_path": "/mnt/apps/llm-nanochat/checkpoints/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki/step_34200.pt",
|
| 171 |
+
"global_step": 34200,
|
| 172 |
+
"packed_dataset_config_path": null,
|
| 173 |
+
"run_dir": "/mnt/apps/llm-nanochat/checkpoints",
|
| 174 |
+
"tokenizer_dir": "/mnt/apps/llm-nanochat/tokenizers/tokenizer_20260515_en50it50_webwiki_stratified_500M",
|
| 175 |
+
"training_config_path": null
|
| 176 |
+
},
|
| 177 |
+
"safetensors_path": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/step_34200.safetensors",
|
| 178 |
+
"source_checkpoint_path": "/mnt/apps/llm-nanochat/checkpoints/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki/step_34200.pt",
|
| 179 |
+
"source_global_step": 34200,
|
| 180 |
+
"tensor_names": [
|
| 181 |
+
"token_emb.weight",
|
| 182 |
+
"pos_emb.weight",
|
| 183 |
+
"blocks.0.ln_1.weight",
|
| 184 |
+
"blocks.0.ln_1.bias",
|
| 185 |
+
"blocks.0.ln_2.weight",
|
| 186 |
+
"blocks.0.ln_2.bias",
|
| 187 |
+
"blocks.0.attn.qkv.weight",
|
| 188 |
+
"blocks.0.attn.qkv.bias",
|
| 189 |
+
"blocks.0.attn.out_proj.weight",
|
| 190 |
+
"blocks.0.attn.out_proj.bias",
|
| 191 |
+
"blocks.0.mlp.fc.weight",
|
| 192 |
+
"blocks.0.mlp.fc.bias",
|
| 193 |
+
"blocks.0.mlp.proj.weight",
|
| 194 |
+
"blocks.0.mlp.proj.bias",
|
| 195 |
+
"blocks.1.ln_1.weight",
|
| 196 |
+
"blocks.1.ln_1.bias",
|
| 197 |
+
"blocks.1.ln_2.weight",
|
| 198 |
+
"blocks.1.ln_2.bias",
|
| 199 |
+
"blocks.1.attn.qkv.weight",
|
| 200 |
+
"blocks.1.attn.qkv.bias",
|
| 201 |
+
"blocks.1.attn.out_proj.weight",
|
| 202 |
+
"blocks.1.attn.out_proj.bias",
|
| 203 |
+
"blocks.1.mlp.fc.weight",
|
| 204 |
+
"blocks.1.mlp.fc.bias",
|
| 205 |
+
"blocks.1.mlp.proj.weight",
|
| 206 |
+
"blocks.1.mlp.proj.bias",
|
| 207 |
+
"blocks.2.ln_1.weight",
|
| 208 |
+
"blocks.2.ln_1.bias",
|
| 209 |
+
"blocks.2.ln_2.weight",
|
| 210 |
+
"blocks.2.ln_2.bias",
|
| 211 |
+
"blocks.2.attn.qkv.weight",
|
| 212 |
+
"blocks.2.attn.qkv.bias",
|
| 213 |
+
"blocks.2.attn.out_proj.weight",
|
| 214 |
+
"blocks.2.attn.out_proj.bias",
|
| 215 |
+
"blocks.2.mlp.fc.weight",
|
| 216 |
+
"blocks.2.mlp.fc.bias",
|
| 217 |
+
"blocks.2.mlp.proj.weight",
|
| 218 |
+
"blocks.2.mlp.proj.bias",
|
| 219 |
+
"blocks.3.ln_1.weight",
|
| 220 |
+
"blocks.3.ln_1.bias",
|
| 221 |
+
"blocks.3.ln_2.weight",
|
| 222 |
+
"blocks.3.ln_2.bias",
|
| 223 |
+
"blocks.3.attn.qkv.weight",
|
| 224 |
+
"blocks.3.attn.qkv.bias",
|
| 225 |
+
"blocks.3.attn.out_proj.weight",
|
| 226 |
+
"blocks.3.attn.out_proj.bias",
|
| 227 |
+
"blocks.3.mlp.fc.weight",
|
| 228 |
+
"blocks.3.mlp.fc.bias",
|
| 229 |
+
"blocks.3.mlp.proj.weight",
|
| 230 |
+
"blocks.3.mlp.proj.bias",
|
| 231 |
+
"blocks.4.ln_1.weight",
|
| 232 |
+
"blocks.4.ln_1.bias",
|
| 233 |
+
"blocks.4.ln_2.weight",
|
| 234 |
+
"blocks.4.ln_2.bias",
|
| 235 |
+
"blocks.4.attn.qkv.weight",
|
| 236 |
+
"blocks.4.attn.qkv.bias",
|
| 237 |
+
"blocks.4.attn.out_proj.weight",
|
| 238 |
+
"blocks.4.attn.out_proj.bias",
|
| 239 |
+
"blocks.4.mlp.fc.weight",
|
| 240 |
+
"blocks.4.mlp.fc.bias",
|
| 241 |
+
"blocks.4.mlp.proj.weight",
|
| 242 |
+
"blocks.4.mlp.proj.bias",
|
| 243 |
+
"blocks.5.ln_1.weight",
|
| 244 |
+
"blocks.5.ln_1.bias",
|
| 245 |
+
"blocks.5.ln_2.weight",
|
| 246 |
+
"blocks.5.ln_2.bias",
|
| 247 |
+
"blocks.5.attn.qkv.weight",
|
| 248 |
+
"blocks.5.attn.qkv.bias",
|
| 249 |
+
"blocks.5.attn.out_proj.weight",
|
| 250 |
+
"blocks.5.attn.out_proj.bias",
|
| 251 |
+
"blocks.5.mlp.fc.weight",
|
| 252 |
+
"blocks.5.mlp.fc.bias",
|
| 253 |
+
"blocks.5.mlp.proj.weight",
|
| 254 |
+
"blocks.5.mlp.proj.bias",
|
| 255 |
+
"blocks.6.ln_1.weight",
|
| 256 |
+
"blocks.6.ln_1.bias",
|
| 257 |
+
"blocks.6.ln_2.weight",
|
| 258 |
+
"blocks.6.ln_2.bias",
|
| 259 |
+
"blocks.6.attn.qkv.weight",
|
| 260 |
+
"blocks.6.attn.qkv.bias",
|
| 261 |
+
"blocks.6.attn.out_proj.weight",
|
| 262 |
+
"blocks.6.attn.out_proj.bias",
|
| 263 |
+
"blocks.6.mlp.fc.weight",
|
| 264 |
+
"blocks.6.mlp.fc.bias",
|
| 265 |
+
"blocks.6.mlp.proj.weight",
|
| 266 |
+
"blocks.6.mlp.proj.bias",
|
| 267 |
+
"blocks.7.ln_1.weight",
|
| 268 |
+
"blocks.7.ln_1.bias",
|
| 269 |
+
"blocks.7.ln_2.weight",
|
| 270 |
+
"blocks.7.ln_2.bias",
|
| 271 |
+
"blocks.7.attn.qkv.weight",
|
| 272 |
+
"blocks.7.attn.qkv.bias",
|
| 273 |
+
"blocks.7.attn.out_proj.weight",
|
| 274 |
+
"blocks.7.attn.out_proj.bias",
|
| 275 |
+
"blocks.7.mlp.fc.weight",
|
| 276 |
+
"blocks.7.mlp.fc.bias",
|
| 277 |
+
"blocks.7.mlp.proj.weight",
|
| 278 |
+
"blocks.7.mlp.proj.bias",
|
| 279 |
+
"blocks.8.ln_1.weight",
|
| 280 |
+
"blocks.8.ln_1.bias",
|
| 281 |
+
"blocks.8.ln_2.weight",
|
| 282 |
+
"blocks.8.ln_2.bias",
|
| 283 |
+
"blocks.8.attn.qkv.weight",
|
| 284 |
+
"blocks.8.attn.qkv.bias",
|
| 285 |
+
"blocks.8.attn.out_proj.weight",
|
| 286 |
+
"blocks.8.attn.out_proj.bias",
|
| 287 |
+
"blocks.8.mlp.fc.weight",
|
| 288 |
+
"blocks.8.mlp.fc.bias",
|
| 289 |
+
"blocks.8.mlp.proj.weight",
|
| 290 |
+
"blocks.8.mlp.proj.bias",
|
| 291 |
+
"blocks.9.ln_1.weight",
|
| 292 |
+
"blocks.9.ln_1.bias",
|
| 293 |
+
"blocks.9.ln_2.weight",
|
| 294 |
+
"blocks.9.ln_2.bias",
|
| 295 |
+
"blocks.9.attn.qkv.weight",
|
| 296 |
+
"blocks.9.attn.qkv.bias",
|
| 297 |
+
"blocks.9.attn.out_proj.weight",
|
| 298 |
+
"blocks.9.attn.out_proj.bias",
|
| 299 |
+
"blocks.9.mlp.fc.weight",
|
| 300 |
+
"blocks.9.mlp.fc.bias",
|
| 301 |
+
"blocks.9.mlp.proj.weight",
|
| 302 |
+
"blocks.9.mlp.proj.bias",
|
| 303 |
+
"blocks.10.ln_1.weight",
|
| 304 |
+
"blocks.10.ln_1.bias",
|
| 305 |
+
"blocks.10.ln_2.weight",
|
| 306 |
+
"blocks.10.ln_2.bias",
|
| 307 |
+
"blocks.10.attn.qkv.weight",
|
| 308 |
+
"blocks.10.attn.qkv.bias",
|
| 309 |
+
"blocks.10.attn.out_proj.weight",
|
| 310 |
+
"blocks.10.attn.out_proj.bias",
|
| 311 |
+
"blocks.10.mlp.fc.weight",
|
| 312 |
+
"blocks.10.mlp.fc.bias",
|
| 313 |
+
"blocks.10.mlp.proj.weight",
|
| 314 |
+
"blocks.10.mlp.proj.bias",
|
| 315 |
+
"blocks.11.ln_1.weight",
|
| 316 |
+
"blocks.11.ln_1.bias",
|
| 317 |
+
"blocks.11.ln_2.weight",
|
| 318 |
+
"blocks.11.ln_2.bias",
|
| 319 |
+
"blocks.11.attn.qkv.weight",
|
| 320 |
+
"blocks.11.attn.qkv.bias",
|
| 321 |
+
"blocks.11.attn.out_proj.weight",
|
| 322 |
+
"blocks.11.attn.out_proj.bias",
|
| 323 |
+
"blocks.11.mlp.fc.weight",
|
| 324 |
+
"blocks.11.mlp.fc.bias",
|
| 325 |
+
"blocks.11.mlp.proj.weight",
|
| 326 |
+
"blocks.11.mlp.proj.bias",
|
| 327 |
+
"blocks.12.ln_1.weight",
|
| 328 |
+
"blocks.12.ln_1.bias",
|
| 329 |
+
"blocks.12.ln_2.weight",
|
| 330 |
+
"blocks.12.ln_2.bias",
|
| 331 |
+
"blocks.12.attn.qkv.weight",
|
| 332 |
+
"blocks.12.attn.qkv.bias",
|
| 333 |
+
"blocks.12.attn.out_proj.weight",
|
| 334 |
+
"blocks.12.attn.out_proj.bias",
|
| 335 |
+
"blocks.12.mlp.fc.weight",
|
| 336 |
+
"blocks.12.mlp.fc.bias",
|
| 337 |
+
"blocks.12.mlp.proj.weight",
|
| 338 |
+
"blocks.12.mlp.proj.bias",
|
| 339 |
+
"blocks.13.ln_1.weight",
|
| 340 |
+
"blocks.13.ln_1.bias",
|
| 341 |
+
"blocks.13.ln_2.weight",
|
| 342 |
+
"blocks.13.ln_2.bias",
|
| 343 |
+
"blocks.13.attn.qkv.weight",
|
| 344 |
+
"blocks.13.attn.qkv.bias",
|
| 345 |
+
"blocks.13.attn.out_proj.weight",
|
| 346 |
+
"blocks.13.attn.out_proj.bias",
|
| 347 |
+
"blocks.13.mlp.fc.weight",
|
| 348 |
+
"blocks.13.mlp.fc.bias",
|
| 349 |
+
"blocks.13.mlp.proj.weight",
|
| 350 |
+
"blocks.13.mlp.proj.bias",
|
| 351 |
+
"blocks.14.ln_1.weight",
|
| 352 |
+
"blocks.14.ln_1.bias",
|
| 353 |
+
"blocks.14.ln_2.weight",
|
| 354 |
+
"blocks.14.ln_2.bias",
|
| 355 |
+
"blocks.14.attn.qkv.weight",
|
| 356 |
+
"blocks.14.attn.qkv.bias",
|
| 357 |
+
"blocks.14.attn.out_proj.weight",
|
| 358 |
+
"blocks.14.attn.out_proj.bias",
|
| 359 |
+
"blocks.14.mlp.fc.weight",
|
| 360 |
+
"blocks.14.mlp.fc.bias",
|
| 361 |
+
"blocks.14.mlp.proj.weight",
|
| 362 |
+
"blocks.14.mlp.proj.bias",
|
| 363 |
+
"blocks.15.ln_1.weight",
|
| 364 |
+
"blocks.15.ln_1.bias",
|
| 365 |
+
"blocks.15.ln_2.weight",
|
| 366 |
+
"blocks.15.ln_2.bias",
|
| 367 |
+
"blocks.15.attn.qkv.weight",
|
| 368 |
+
"blocks.15.attn.qkv.bias",
|
| 369 |
+
"blocks.15.attn.out_proj.weight",
|
| 370 |
+
"blocks.15.attn.out_proj.bias",
|
| 371 |
+
"blocks.15.mlp.fc.weight",
|
| 372 |
+
"blocks.15.mlp.fc.bias",
|
| 373 |
+
"blocks.15.mlp.proj.weight",
|
| 374 |
+
"blocks.15.mlp.proj.bias",
|
| 375 |
+
"blocks.16.ln_1.weight",
|
| 376 |
+
"blocks.16.ln_1.bias",
|
| 377 |
+
"blocks.16.ln_2.weight",
|
| 378 |
+
"blocks.16.ln_2.bias",
|
| 379 |
+
"blocks.16.attn.qkv.weight",
|
| 380 |
+
"blocks.16.attn.qkv.bias",
|
| 381 |
+
"blocks.16.attn.out_proj.weight",
|
| 382 |
+
"blocks.16.attn.out_proj.bias",
|
| 383 |
+
"blocks.16.mlp.fc.weight",
|
| 384 |
+
"blocks.16.mlp.fc.bias",
|
| 385 |
+
"blocks.16.mlp.proj.weight",
|
| 386 |
+
"blocks.16.mlp.proj.bias",
|
| 387 |
+
"blocks.17.ln_1.weight",
|
| 388 |
+
"blocks.17.ln_1.bias",
|
| 389 |
+
"blocks.17.ln_2.weight",
|
| 390 |
+
"blocks.17.ln_2.bias",
|
| 391 |
+
"blocks.17.attn.qkv.weight",
|
| 392 |
+
"blocks.17.attn.qkv.bias",
|
| 393 |
+
"blocks.17.attn.out_proj.weight",
|
| 394 |
+
"blocks.17.attn.out_proj.bias",
|
| 395 |
+
"blocks.17.mlp.fc.weight",
|
| 396 |
+
"blocks.17.mlp.fc.bias",
|
| 397 |
+
"blocks.17.mlp.proj.weight",
|
| 398 |
+
"blocks.17.mlp.proj.bias",
|
| 399 |
+
"blocks.18.ln_1.weight",
|
| 400 |
+
"blocks.18.ln_1.bias",
|
| 401 |
+
"blocks.18.ln_2.weight",
|
| 402 |
+
"blocks.18.ln_2.bias",
|
| 403 |
+
"blocks.18.attn.qkv.weight",
|
| 404 |
+
"blocks.18.attn.qkv.bias",
|
| 405 |
+
"blocks.18.attn.out_proj.weight",
|
| 406 |
+
"blocks.18.attn.out_proj.bias",
|
| 407 |
+
"blocks.18.mlp.fc.weight",
|
| 408 |
+
"blocks.18.mlp.fc.bias",
|
| 409 |
+
"blocks.18.mlp.proj.weight",
|
| 410 |
+
"blocks.18.mlp.proj.bias",
|
| 411 |
+
"blocks.19.ln_1.weight",
|
| 412 |
+
"blocks.19.ln_1.bias",
|
| 413 |
+
"blocks.19.ln_2.weight",
|
| 414 |
+
"blocks.19.ln_2.bias",
|
| 415 |
+
"blocks.19.attn.qkv.weight",
|
| 416 |
+
"blocks.19.attn.qkv.bias",
|
| 417 |
+
"blocks.19.attn.out_proj.weight",
|
| 418 |
+
"blocks.19.attn.out_proj.bias",
|
| 419 |
+
"blocks.19.mlp.fc.weight",
|
| 420 |
+
"blocks.19.mlp.fc.bias",
|
| 421 |
+
"blocks.19.mlp.proj.weight",
|
| 422 |
+
"blocks.19.mlp.proj.bias",
|
| 423 |
+
"blocks.20.ln_1.weight",
|
| 424 |
+
"blocks.20.ln_1.bias",
|
| 425 |
+
"blocks.20.ln_2.weight",
|
| 426 |
+
"blocks.20.ln_2.bias",
|
| 427 |
+
"blocks.20.attn.qkv.weight",
|
| 428 |
+
"blocks.20.attn.qkv.bias",
|
| 429 |
+
"blocks.20.attn.out_proj.weight",
|
| 430 |
+
"blocks.20.attn.out_proj.bias",
|
| 431 |
+
"blocks.20.mlp.fc.weight",
|
| 432 |
+
"blocks.20.mlp.fc.bias",
|
| 433 |
+
"blocks.20.mlp.proj.weight",
|
| 434 |
+
"blocks.20.mlp.proj.bias",
|
| 435 |
+
"blocks.21.ln_1.weight",
|
| 436 |
+
"blocks.21.ln_1.bias",
|
| 437 |
+
"blocks.21.ln_2.weight",
|
| 438 |
+
"blocks.21.ln_2.bias",
|
| 439 |
+
"blocks.21.attn.qkv.weight",
|
| 440 |
+
"blocks.21.attn.qkv.bias",
|
| 441 |
+
"blocks.21.attn.out_proj.weight",
|
| 442 |
+
"blocks.21.attn.out_proj.bias",
|
| 443 |
+
"blocks.21.mlp.fc.weight",
|
| 444 |
+
"blocks.21.mlp.fc.bias",
|
| 445 |
+
"blocks.21.mlp.proj.weight",
|
| 446 |
+
"blocks.21.mlp.proj.bias",
|
| 447 |
+
"blocks.22.ln_1.weight",
|
| 448 |
+
"blocks.22.ln_1.bias",
|
| 449 |
+
"blocks.22.ln_2.weight",
|
| 450 |
+
"blocks.22.ln_2.bias",
|
| 451 |
+
"blocks.22.attn.qkv.weight",
|
| 452 |
+
"blocks.22.attn.qkv.bias",
|
| 453 |
+
"blocks.22.attn.out_proj.weight",
|
| 454 |
+
"blocks.22.attn.out_proj.bias",
|
| 455 |
+
"blocks.22.mlp.fc.weight",
|
| 456 |
+
"blocks.22.mlp.fc.bias",
|
| 457 |
+
"blocks.22.mlp.proj.weight",
|
| 458 |
+
"blocks.22.mlp.proj.bias",
|
| 459 |
+
"blocks.23.ln_1.weight",
|
| 460 |
+
"blocks.23.ln_1.bias",
|
| 461 |
+
"blocks.23.ln_2.weight",
|
| 462 |
+
"blocks.23.ln_2.bias",
|
| 463 |
+
"blocks.23.attn.qkv.weight",
|
| 464 |
+
"blocks.23.attn.qkv.bias",
|
| 465 |
+
"blocks.23.attn.out_proj.weight",
|
| 466 |
+
"blocks.23.attn.out_proj.bias",
|
| 467 |
+
"blocks.23.mlp.fc.weight",
|
| 468 |
+
"blocks.23.mlp.fc.bias",
|
| 469 |
+
"blocks.23.mlp.proj.weight",
|
| 470 |
+
"blocks.23.mlp.proj.bias",
|
| 471 |
+
"ln_f.weight",
|
| 472 |
+
"ln_f.bias",
|
| 473 |
+
"head.weight",
|
| 474 |
+
"head.bias"
|
| 475 |
+
],
|
| 476 |
+
"tokenizer_bundle": {
|
| 477 |
+
"special_tokens_map.json": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/special_tokens_map.json",
|
| 478 |
+
"tokenizer.json": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/tokenizer.json",
|
| 479 |
+
"tokenizer_config.json": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/tokenizer_config.json",
|
| 480 |
+
"tokenizer_meta.json": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/tokenizer_meta.json"
|
| 481 |
+
},
|
| 482 |
+
"tokenizer_reference": {
|
| 483 |
+
"packed_dataset_config_path": null,
|
| 484 |
+
"tokenizer_dir": "/mnt/apps/llm-nanochat/tokenizers/tokenizer_20260515_en50it50_webwiki_stratified_500M",
|
| 485 |
+
"training_config_path": null
|
| 486 |
+
},
|
| 487 |
+
"transformers_config": {
|
| 488 |
+
"activation_function": "gelu",
|
| 489 |
+
"architecture": "gpt2",
|
| 490 |
+
"architectures": [
|
| 491 |
+
"GPT2LMHeadModel"
|
| 492 |
+
],
|
| 493 |
+
"attn_pdrop": 0.0,
|
| 494 |
+
"block_type": "gpt2_prelayernorm",
|
| 495 |
+
"causal_mask_mode": "buffered_upper_triangular",
|
| 496 |
+
"embd_pdrop": 0.0,
|
| 497 |
+
"init_strategy": "gpt2_std_0.02_residual_scale",
|
| 498 |
+
"layer_norm_epsilon": 1e-05,
|
| 499 |
+
"model_type": "gpt2",
|
| 500 |
+
"n_ctx": 2500,
|
| 501 |
+
"n_embd": 1024,
|
| 502 |
+
"n_head": 16,
|
| 503 |
+
"n_layer": 24,
|
| 504 |
+
"n_positions": 2500,
|
| 505 |
+
"norm_order": "preln",
|
| 506 |
+
"norm_type": "layernorm",
|
| 507 |
+
"positional_encoding": "learned_absolute",
|
| 508 |
+
"resid_pdrop": 0.0,
|
| 509 |
+
"tie_word_embeddings": true,
|
| 510 |
+
"use_cache": true,
|
| 511 |
+
"vocab_size": 32000
|
| 512 |
+
},
|
| 513 |
+
"transformers_export_notes": {
|
| 514 |
+
"dropped_lm_head_bias_for_gpt2_compat": true,
|
| 515 |
+
"dropped_lm_head_bias_max_abs": 1.3327739238739014,
|
| 516 |
+
"dropped_lm_head_bias_mean_abs": 0.046846117824316025
|
| 517 |
+
},
|
| 518 |
+
"transformers_safetensors_path": "/mnt/apps/llm-nanochat/hf_exports/1gpu-llm-medium-v2/model.safetensors"
|
| 519 |
+
}
|
tokenizer.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
tokenizer_config.json
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"bos_token": "<bos>",
|
| 3 |
+
"clean_up_tokenization_spaces": false,
|
| 4 |
+
"eos_token": "<eos>",
|
| 5 |
+
"model_max_length": 2500,
|
| 6 |
+
"pad_token": "<pad>",
|
| 7 |
+
"tokenizer_class": "PreTrainedTokenizerFast",
|
| 8 |
+
"unk_token": "<unk>"
|
| 9 |
+
}
|
tokenizer_meta.json
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"vocab_size_requested": 32000,
|
| 3 |
+
"vocab_size_actual": 32000,
|
| 4 |
+
"special_tokens": [
|
| 5 |
+
"<pad>",
|
| 6 |
+
"<bos>",
|
| 7 |
+
"<eos>",
|
| 8 |
+
"<unk>"
|
| 9 |
+
]
|
| 10 |
+
}
|
training_config.yaml
ADDED
|
@@ -0,0 +1,66 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Optimizer-preserving decay-only continuation for the benchmark-winning medium CPT checkpoint at step_34000.
|
| 2 |
+
# Launch with --resume-mode optimizer_only so the checkpoint model + optimizer state are restored,
|
| 3 |
+
# while the configured local wsd-decay-only scheduler is initialized from this config instead of
|
| 4 |
+
# reusing the checkpoint scheduler state.
|
| 5 |
+
# Target window: global step 34000 -> 35700.
|
| 6 |
+
|
| 7 |
+
resume_from: /mnt/apps/llm-nanochat/checkpoints/20260703_continual-pretraining-gpt2medium-gpt2preln-k20-step14700-lr5e5-w500-s18500-d2000-final1e5-webwiki/step_34000.pt
|
| 8 |
+
dataset_dir: /mnt/apps/llm-nanochat/datasets/202605141153_fineweb50_wiki50_50en_50it_score100_2500context_5Btokens_tok_20260515_en50it50_webwiki_stratified_500M
|
| 9 |
+
output_dir: /mnt/apps/llm-nanochat/artifacts/runs/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki
|
| 10 |
+
tokenizer_dir: /mnt/apps/llm-nanochat/tokenizers/tokenizer_20260515_en50it50_webwiki_stratified_500M
|
| 11 |
+
seed: 1337
|
| 12 |
+
|
| 13 |
+
model:
|
| 14 |
+
architecture: gpt2
|
| 15 |
+
block_type: gpt2_prelayernorm
|
| 16 |
+
tie_word_embeddings: true
|
| 17 |
+
vocab_size: 32000
|
| 18 |
+
dim: 1024
|
| 19 |
+
n_layers: 24
|
| 20 |
+
n_heads: 16
|
| 21 |
+
|
| 22 |
+
training:
|
| 23 |
+
sequence_length: 2500
|
| 24 |
+
max_steps: 35700
|
| 25 |
+
batch_size: 2
|
| 26 |
+
grad_accum_steps: 48
|
| 27 |
+
|
| 28 |
+
learning_rate: 4.7832243797285384e-05
|
| 29 |
+
peak_lr: 4.7832243797285384e-05
|
| 30 |
+
lr_schedule: wsd-decay-only
|
| 31 |
+
|
| 32 |
+
warmup_steps: 0
|
| 33 |
+
stable_steps: 0
|
| 34 |
+
decay_steps: 1700
|
| 35 |
+
final_lr: 1.0e-05
|
| 36 |
+
decay_shape: inverse_proportional
|
| 37 |
+
|
| 38 |
+
adamw_betas:
|
| 39 |
+
- 0.9
|
| 40 |
+
- 0.95
|
| 41 |
+
adamw_eps: 1.0e-08
|
| 42 |
+
weight_decay: 0.1
|
| 43 |
+
clip_grad_norm: 1.0
|
| 44 |
+
|
| 45 |
+
save_every_steps: 100
|
| 46 |
+
save_final_checkpoint: true
|
| 47 |
+
checkpoint_dir: /mnt/apps/llm-nanochat/checkpoints/20260715_resume-gpt2medium-gpt2preln-k20-optimizeronly-cpt14700-step34000-d1700-webwiki
|
| 48 |
+
precision: bf16
|
| 49 |
+
|
| 50 |
+
evaluation:
|
| 51 |
+
validation_every_steps: 100
|
| 52 |
+
validation_max_batches: 128
|
| 53 |
+
probe_every_steps: 500
|
| 54 |
+
probe_tokenizer_dir: /mnt/apps/llm-nanochat/tokenizers/tokenizer_20260515_en50it50_webwiki_stratified_500M
|
| 55 |
+
probe_max_new_tokens: 32
|
| 56 |
+
probe_prompts:
|
| 57 |
+
en:
|
| 58 |
+
- prompt: "The capital of Italy is"
|
| 59 |
+
expected_next_text: " Rome"
|
| 60 |
+
- prompt: "A small language model should"
|
| 61 |
+
expected_next_text: " be"
|
| 62 |
+
it:
|
| 63 |
+
- prompt: "La capitale d'Italia è"
|
| 64 |
+
expected_next_text: " Roma"
|
| 65 |
+
- prompt: "Un piccolo modello linguistico dovrebbe"
|
| 66 |
+
expected_next_text: " essere"
|