Initial K3 snapshot: 0.5B KDA/MLA/MoE train path
Standalone tree split from LLMRL/projects/kda. Includes Triton dt_bias backward fix, train_k3 --preset 0.5b, SFT, Docker runtime, and tests.
This commit is contained in:
@@ -0,0 +1,43 @@
|
||||
"""Default container command: print usage and refuse to start a silent toy run."""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
HELP = """kda image: one GPU runtime for train / monitor / eval.
|
||||
|
||||
Do not docker run without a command — toy overfit is not the default.
|
||||
|
||||
Volumes (host → container):
|
||||
./ckpts → /workspace/kda/ckpts
|
||||
pretrain corpus → /data/pretrain (ro)
|
||||
SFT bitext → /data/sft (ro)
|
||||
frozen eval → /data/eval (ro)
|
||||
HF tokenizer cache → /cache/huggingface
|
||||
SWANLAB_API_KEY via -e (never COPY into the image)
|
||||
|
||||
Examples:
|
||||
docker run --rm --gpus all kda:<tag> python train.py
|
||||
docker run --rm --gpus all -e SWANLAB_API_KEY \\
|
||||
-v "$PWD/ckpts:/workspace/kda/ckpts" \\
|
||||
kda:<tag> python train_k3.py --preset toy --attnres off
|
||||
docker run --rm --gpus all kda:<tag> swanlab ping
|
||||
docker run --rm --gpus all \\
|
||||
-v "$PWD/ckpts:/workspace/kda/ckpts" -v "$PWD/data/eval:/data/eval:ro" \\
|
||||
kda:<tag> python -m kda.training.eval_mt \\
|
||||
--ckpt /workspace/kda/ckpts/k3_wiki.pt \\
|
||||
--src /data/eval/zh2en.src.txt --ref /data/eval/zh2en.ref.txt \\
|
||||
--target-lang en
|
||||
docker run --rm --gpus all \\
|
||||
-v "$PWD/ckpts:/workspace/kda/ckpts" -v "$PWD/data/sft:/data/sft:ro" \\
|
||||
kda:<tag> python train_sft.py --ckpt /workspace/kda/ckpts/k3_wiki.pt \\
|
||||
--data /data/sft/toy.jsonl
|
||||
docker run --rm --gpus all kda:<tag> python -m pytest -q
|
||||
"""
|
||||
|
||||
|
||||
def main() -> None:
|
||||
print(HELP)
|
||||
raise SystemExit(2)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
Reference in New Issue
Block a user