1 """ 2 hair: tiny AI, explained. This file is the traffic cop: it loads 3 the parts (lib, data, dist, tree, stats), holds the settings and 4 the tests. The eg*.py files are short demos that import it. 5 (c) 2026, Tim Menzies <timm@ieee.org>, MIT license 6 7 USAGE: python3 hair.py [--key=val ...] [test ...] 8 python3 hair.py all # run every test 9 10 OPTIONS: 11 --dir data directory = $MOOT/optimize 12 --file file(s)|all|fast = fast 13 --seed random seed = 1234567891 14 --k most neighbours = 5 15 --eval score metric = rae 16 --test rows to guess = 100 17 --pool known rows, cap = 1000 18 --runs repeats = 5 19 --val random evals = 10 20 --few pool rows tried = 32 21 --temp start temp = 0.2 22 --cool cooling rate = 0.9 23 --leaf tree min leaf = 3 24 --maxd tree max depth = 8 25 --eps cohen: small d = 0.35 26 --jobs cpus, 0 for all = 0 27 28 TESTS: run any by name, e.g. "python3 hair.py tab tree". 29 """ 30 from .lib import settings 31 the = settings(__doc__) # one config, shared by all parts 32