Build tables for positions [0, maxCtx) and head-dim headDim
(must be even). base is the geometric-progression base for the
frequency schedule (10000 for GPT-NeoX / Pythia; the same in
LLaMA/Mistral). rotaryDim defaults to the full headDim;
pass a smaller even number to only rotate a prefix of each
head (GPT-NeoX rotary_pct convention).
Number of leading dimensions of each head that receive RoPE.
For GPT-NeoX / Pythia this is headDim * rotary_pct (0.25 for
160m / 410m; 1.0 for LLaMA-style full rotation).