Notes
Longer form
The experiments, edge cases, and machinery behind the package.
The docs tell you what GLRMask is. These pieces keep the messier path: why the architecture exists, where it is fast or slow, what breaks at lexer boundaries, and how the supporting data structures work.
Aug 15, 2026 llguidance HATES This One Weird Grammar (Well-behaved grammars) A tiny counterexample, a debugger, and a simple rule for avoiding awkward greedy-lexer boundaries. Aug 14, 2026 Where constrained decoding time goes GLRMask vs llguidance, token by token Aug 1, 2026 Life after ~~parsing~~ grammar constrained generation Why I spent years building a general grammar-constrained decoder when most people needed JSON. Aug 1, 2026 Why llguidance is fast llguidance skips dead token-trie subtrees and fills broad lexer regions with precomputed token slices. Jul 31, 2026 GLRMask Constrained Decoding with Weighted Automata Jul 30, 2026 (archived) The 112-hyphen token Why one model token can hide a long lexer and parser execution, and how GLRMask compiles that work into a weighted automaton over GLR stacks. Jul 26, 2026 Building a mini llguidance Rebuilding llguidance's token-trie, lexer, and Earley-parser loop in miniature. Jul 26, 2026 llguidance HATES This One Weird Grammar How llguidance's one-byte lexer lookahead can lose a valid token boundary. Jul 25, 2026 A weighted graph-structured stack A persistent compressed map from stacks to weights, extracted from glrmask. Jun 27, 2026 A grammar-constrained model in your browser TinyStories-1M runs locally; glrmask WebAssembly applies an exact JSON mask to its BPE logits before sampling.