Skip to main content
Op Specs live in TheFormalEra.Ops (specs/TheFormalEra/Ops/). Each is a noncomputable def over Mathlib’s ℝ. Model Specs instantiate them with constants; a node’s op field names the Op Spec it uses.

Scalar functions

Normalisation

The row index type ι is arbitrary: tokens Fin T for a hidden-state norm, or (token, head) pairs for a per-head norm.

Linear maps and feed-forward

Attention

The sliding-window decode nodes of Gemma 4 and Muse Glimmer are labelled slidingDecodeGQA in the compute graph: decode attention over the last w cached positions. In spec 1.0 that label has no Lean definition of its own. The window semantics are defined by slidingGQA, and the conformance oracle evaluates them, but the engine has no Op Spec to prove a sliding-window decode kernel against. Those kernels are UNKNOWN.

Rotary embeddings

rope θ rot denom active rotates pairs (i, i + rot/2) for i < rot/2 by pos · invFreq i, and leaves coordinates ≥ rot unchanged. That one definition covers every variant in the supported models:

Gated DeltaNet

High-performance kernels use the chunk-parallel (WY) form, which looks nothing like this recurrence. chunkDeltaRule_eq proves in Lean that the chunked form equals the recurrence, for every chunk size.