Repository navigation
trainlint 0.1.0
First release.
trainlint checks Python training and evaluation code for ML bugs that do not crash, and ships
agent skills that steer coding agents away from the same bugs.
- 12 rules, TL001 to TL012: leakage before splits, eval mode and
no_grad, seeding, mixed
precision, checkpoints, loss inputs, gradient clearing, tensor accumulation, metric misuse and
evaluation loaders. Examples for each are indocs/rules.md. trainlint checkwith text and JSON output,--select,--ignore,--exit-zero,
--color, and# trainlint: ignore[RULE]comments.- Four Agent Skills and
trainlint skills install. - A regression corpus of 18 buggy scripts with fixed twins (
python -m bench) and a spot check on
93 files of pytorch/examples, described in the README.
It matches names and reads one file at a time, so expect some false positives. Please report them.