Skip to content

Configuration

Sudhanshu edited this page Nov 11, 2026 · 1 revision

CLI Configuration Reference

Flag Default Description
--model tiny tiny (from scratch) or qwen (pretrained LoRA)
--cpu false Force CPU training
--corpus-file built-in examples Path to UTF-8, one example per line
--batch-size 2 Per-rank batch size
--seq-len 64 Maximum sequence length (at least 4)
--epochs 1 Number of full training epochs
--max-steps 4 Maximum optimizer steps per rank per epoch; 0 means all batches
--lr tiny 3e-4, Qwen 2e-4 Optional learning-rate override
--repeat 4 Corpus repetition multiplier
--save-dir ddp_example_output Folder for resulting artifacts

Distributed environment variables normally supplied by torchrun: WORLD_SIZE, RANK, and LOCAL_RANK. Use --standalone --nproc_per_node=N for a local single-node demonstration.

Not implemented: gradient accumulation, an LR scheduler, mixed-precision autocast configuration, DeepSpeed, model-parallel tensor partitioning, or evaluation flags.

Clone this wiki locally