← All papers
First page of Proving at Scale for Universal Algebra

Proving at Scale for Universal Algebra

João Araújo, Jan Hůla, Mikoláš Janota, Edmond W. H. Lee, Bartosz Naskręcki

cs.LO Oct 1, 2026 · v1 math.GR
Lean 4 kernel-checks finite identity bases, or proofs of non-finite-basability, for all semigroups of order at most 6, produced by LLM agents.
We introduce SemiBase, a project that computes and formally certifies finite identity bases for small semigroups. Deciding finite basability is undecidable for finite algebras and remains open for finite semigroups. The task requires a proof that a candidate basis is complete, or a proof that none exists, rather than a single first-order validity query. LLM-guided agents search for these proofs; a referee agent rebuilds them from source, and the Lean kernel checks the resulting corpus in a final audit. Humans choose targets and approve final outcomes. We certify every semigroup of order at most 6: all 1309 semigroups of order at most 5 and all 15973 of order 6, including proofs that the four known nonfinitely based semigroups have no finite basis. The bases for order 6 define 505 distinct varieties, whose inclusion order Vampire determines except for four pairs. The resulting catalogue is a machine-checked account of results scattered across the literature and a tested foundation for order 7.

Deciding whether a finite semigroup has a finite identity basis is an open problem; for finite algebras in general it is undecidable. No machine-checked catalogue settles finite basability for small semigroups.

SemiBase uses LLM agents to propose candidate bases, search for counter-models and write completeness proofs. Codex agents act as workers and coordinator, and a Claude agent acts as referee. A deterministic scripted pipeline, written by the agents, settled the bulk of the classes. Agents then handled the remaining hard cases individually, and a final Lean 4 kernel audit checks the whole corpus.

All 1,309 semigroups of order at most 5 and all 15,973 of order 6 carry Lean certificates, including non-finite-basability proofs for the four known nonfinitely based semigroups of order 6. The order-6 bases define 505 varieties, and Vampire determines their inclusion order except for four pairs.

OrderSemigroupsNilpotent
412610
51,16093
615,9732,813
7836,021616,830
Number of distinct semigroups per order (selected rows)