Lean Kernel Arena / eink0rn

Checker "eink0rn"

Version: 1.1.6 · 📄 Declaration · 🔗 Source

eink0rn — a Lean 4 kernel in Haskell, written clean-room, that normalises the surface language away before checking anything.

  • One inductive type, one recursor. Nested inductives are compiled to mutual blocks and every mutual block is then flattened to a single indexed family, so the core never sees a nested occurrence or a mutual one.
  • Recursors are derived, not believed. The eliminator and its iota rules are rebuilt from the inductive specification and the exported ones must match, so no export can smuggle in an unwarranted large elimination or an extra reduction rule.
  • Clean room. No Lean kernel source of any kind was read — not lean4, not lean4lean, not trepplein, not nanoda. The references were Carneiro's The Type Theory of Lean, the NDJSON format specification, and this arena's verdicts.

The type theory it does implement is written down normatively in SPEC.md, and every place it knowingly departs from official Lean is argued in §12 — including the one --enforce-mutual-univ turns off below, so that the language scored here is the language every other checker is scored on. Nothing is declined; the largest export peaks around eight gigabytes.

Soundness (rightfully rejected tests)

80 ✅ 0 ❌ 0 🚫

Completeness (rightfully accepted tests)

138 ✅ 0 ❌ 0 🚫

Corner cases (no outcome prescribed)

28 ✅ 2 🚫

Test Expected Result ⏱️ 🧠
cedar 👍 👍 1.97 min (-16%) 2.5 GB (+86%)
con-leche 👍 👍 9.58 min (×5.2) 6.0 GB (×7.2)
cslib 👍 👍 6.08 min (-30%) 5.8 GB (+69%)
init 👍 👍 47.7 s (-28%) 1.1 GB (+90%)
init-prelude 👍 👍 232 ms (-36%) 266.0 MB (×3.6)
mathlib 👍 👍 28.3 min (-12%) 11.1 GB (+12%)
navier-stokes-euler 👍 👍 11.5 min (+3%) 4.3 GB (+74%)
reachability 👍 👍 22.4 s (-5%) 4.0 GB (×2.5)
std 👍 👍 89.1 s (-21%) 2.0 GB (×2.2)
26 90.3 ms 31.4 MB
closure-level-subst ✋ ✋ 1.44 ms 11.7 MB
constlevels ✋ ✋ 1.83 ms 12.4 MB
ctor-num-fields ✋ ✋ 2.16 ms 12.4 MB
eta-ctor-alias ✋ ✋ 1.53 ms 11.6 MB
forged-quot-ind ✋ ✋ 1.68 ms 12.3 MB
k-rec-conv ✋ ✋ 1.75 ms 12.2 MB
large-elim-param ✋ ✋ 1.54 ms 11.7 MB
large-elim-prop-bool ✋ ✋ 1.95 ms 12.5 MB
level-imax-leq ✋ ✋ 1.43 ms 11.5 MB
level-imax-normalization ✋ ✋ 1.56 ms 11.9 MB
loose-bvar-value ✋ ✋ 1.29 ms 11.3 MB
nat-rec-k-lie ✋ ✋ 1.41 ms 11.7 MB
nat-rec-rules ✋ ✋ 1.52 ms 11.5 MB
nested-name-capture ✋ ✋ 2.66 ms 14.5 MB
nested-rec-rule-nfields ✋ ✋ 3.02 ms 14.8 MB
nested-unused-param ✋ ✋ 4.26 ms 17.1 MB
orphan-rec ✋ ✋ 1.25 ms 11.0 MB
pi-closure-context ✋ ✋ 1.31 ms 11.5 MB
proj-non-structure ✋ ✋ 1.42 ms 11.5 MB
proj-of-imax-prop ✋ ✋ 2.16 ms 13.4 MB
proj-of-stuck-prop ✋ ✋ 12.4 ms 29.6 MB
proj-of-subst-prop ✋ ✋ 12.4 ms 30.0 MB
rec-k-lie ✋ ✋ 1.36 ms 11.3 MB
rec-missing-ih ✋ ✋ 12.6 ms 29.9 MB
rec-of-subst-prop ✋ ✋ 13.0 ms 31.4 MB
unit-rec-rule ✋ ✋ 1.33 ms 11.4 MB
1 25.1 s 3.7 GB
alg-conv-trans-acc 🤷 ✋ 4.43 ms 17.5 MB
alg-conv-trans-acc-left 🤷 👍 4.33 ms 16.9 MB
alg-conv-trans-acc-right 🤷 👍 4.38 ms 17.0 MB
alg-conv-trans-quot 🤷 ✋ 1.64 ms 12.2 MB
alg-conv-trans-quot-left 🤷 ✋ 1.66 ms 12.3 MB
alg-conv-trans-quot-left-def 🤷 👍 1.66 ms 12.0 MB
alg-conv-trans-quot-right 🤷 👍 1.58 ms 11.7 MB
eta-ctor 🤷 ✋ 1.62 ms 12.0 MB
eta-rec-struct 🤷 ✋ 1.66 ms 12.0 MB
eta-rule-k 🤷 ✋ 1.53 ms 12.0 MB
eta-struct-major-and 🤷 👍 1.59 ms 11.9 MB
eta-struct-major-and-no-whnf 🤷 🚫 12.5 s 3.7 GB
eta-struct-major-no-whnf 🤷 🚫 12.5 s 3.6 GB
eta-unit-like-nested 🤷 ✋ 1.96 ms 12.8 MB
eta-unit-like-pi 🤷 ✋ 1.49 ms 11.9 MB
eta-unit-like-proof-field 🤷 ✋ 1.50 ms 11.8 MB
eta-unit-like-struct 🤷 ✋ 1.52 ms 11.8 MB
imax-nested-absorption 🤷 👍 1.26 ms 11.0 MB
imax-right-successor 🤷 👍 1.26 ms 11.3 MB
large-elim-maybe-prop 🤷 ✋ 1.30 ms 11.6 MB
let-value-type-mismatch 🤷 ✋ 1.24 ms 11.3 MB
nested-nonuniform-param 🤷 👍 1.89 ms 12.9 MB
nested-redex-aux 🤷 👍 5.51 ms 20.0 MB
positivity-whnf 🤷 👍 1.42 ms 11.7 MB
proj-maybe-prop 🤷 👍 1.56 ms 12.0 MB
proj-maybe-prop-past 🤷 👍 1.56 ms 11.8 MB
proof-param-ok 👍 👍 1.32 ms 11.5 MB
proof-param-swap 🤷 ✋ 1.28 ms 11.4 MB
subject-reduction-redex 🤷 ✋ 4.34 ms 17.0 MB
subject-reduction-reduct 🤷 ✋ 4.29 ms 16.7 MB
vanishing-occurrence 🤷 ✋ 1.46 ms 11.7 MB
10 17.3 ms 13.8 MB
extra-rec ✋ ✋ 1.24 ms 11.2 MB
inductive-undeclared-universe ✋ ✋ 1.31 ms 11.3 MB
level-index-out-of-order 👍 👍 1.21 ms 11.3 MB
nat-lit-add 👍 👍 2.35 ms 13.5 MB
nat-lit-add-bad ✋ ✋ 2.39 ms 13.8 MB
nat-lit-ble 👍 👍 2.48 ms 13.8 MB
nat-lit-sub 👍 👍 2.51 ms 13.6 MB
orphan-ctor ✋ ✋ 1.24 ms 10.9 MB
proj-of-prop ✋ ✋ 1.40 ms 11.7 MB
sparse-name-index 👍 👍 1.21 ms 10.8 MB
31 90.7 s (+12%) 8.9 GB
app-lam 👍 👍 54.0 ms (÷90) 62.4 MB (÷23)
args-before-unfold 👍 👍 4.26 ms (÷8.4) 16.1 MB (÷4.1)
beta-ladder 👍 👍 686 ms (÷2.4) 100.7 MB (÷5.0)
church-numerals 👍 👍 8.71 ms (÷5.4) 25.9 MB (÷3.0)
discarded-argument 👍 👍 89.6 ms (-46%) 48.5 MB (-26%)
discarded-argument-match 👍 👍 117 ms (-18%) 145.6 MB (×2.1)
folded-constant-first 👍 👍 5.76 ms (÷7.1) 18.0 MB (÷3.8)
folded-constant-last 👍 👍 5.75 ms (÷7.1) 17.9 MB (÷3.8)
fueled-chain 👍 👍 10.1 s (×80) 676.3 MB (×8.9)
grind-ring-5 👍 👍 1.29 s (-40%) 368.7 MB (+62%)
identical-nesting 👍 👍 1.58 ms (÷18) 11.9 MB (÷5.5)
irrelevance-before-evaluation 👍 👍 1.78 ms (÷16) 12.3 MB (÷5.3)
irrelevance-refutes 👍 👍 1.74 ms (÷16) 12.4 MB (÷5.4)
let-fold 👍 👍 1.18 s (×20) 492.2 MB (×7.4)
let-ladder 👍 👍 1.63 s (+61%) 552.4 MB (+73%)
magma-list-deep-n21 👍 👍 1.91 s (-29%) 706.1 MB (+6%)
magma-list-deep-n36 👍 👍 38.1 s (+8%) 8.9 GB (+13%)
magma-list-pair-n21 👍 👍 25.0 s (+36%) 5.0 GB (+25%)
magma-list-pair-n7 👍 👍 1.70 s (+1%) 798.7 MB (+88%)
magma-string-n4 👍 👍 2.38 s (-33%) 401.0 MB (×3.3)
magma-string-pair-n9 👍 👍 5.99 s (-27%) 1.0 GB (+6%)
proj-cheap-struct 👍 👍 4.94 ms (÷7.0) 18.2 MB (÷3.6)
proj-lazy-struct 👍 👍 145 ms (×4.7) 90.7 MB (+38%)
proj-stuck-struct 👍 👍 3.41 ms (÷9.3) 15.2 MB (÷4.3)
prop-struct-projections 👍 👍 64.3 ms (-35%) 115.4 MB (+65%)
refute-cheap-first ✋ ✋ 2.74 ms (÷15) 16.8 MB (÷4.1)
refute-cheap-last ✋ ✋ 96.6 ms (-46%) 56.9 MB (-18%)
repeated-subproblem 👍 👍 2.76 ms (÷10) 12.2 MB (÷5.4)
shared-subterm 👍 👍 43.5 ms (-25%) 27.1 MB (÷2.7)
shift-cascade 👍 👍 11.2 ms (÷4.1) 26.4 MB (÷2.6)
unroll-versus-evaluate 👍 👍 2.39 ms (÷13) 13.5 MB (÷4.9)
141 198 ms 14.3 MB
001_basicDef 👍 👍 1.23 ms 10.9 MB
002_badDef ✋ ✋ 1.23 ms 11.2 MB
003_arrowType 👍 👍 1.23 ms 11.4 MB
004_dependentType 👍 👍 1.23 ms 10.8 MB
005_constType 👍 👍 1.23 ms 11.1 MB
006_betaReduction 👍 👍 1.26 ms 11.1 MB
007_betaReduction2 👍 👍 1.26 ms 11.0 MB
008_forallSortWhnf 👍 👍 1.26 ms 11.2 MB
009_forallSortBad ✋ ✋ 1.26 ms 11.0 MB
010_nonTypeType ✋ ✋ 1.26 ms 10.9 MB
011_nonTypeAxiom ✋ ✋ 1.24 ms 11.1 MB
012_nonPropThm ✋ ✋ 1.22 ms 10.8 MB
013_thmProof 👍 👍 1.26 ms 11.0 MB
014_selfProof ✋ ✋ 1.23 ms 10.9 MB
015_levelComp1 👍 👍 1.22 ms 11.2 MB
016_levelComp2 👍 👍 1.23 ms 10.9 MB
017_levelComp3 👍 👍 1.23 ms 10.9 MB
018_levelParams 👍 👍 1.26 ms 11.3 MB
019_tut06_bad01 ✋ ✋ 1.21 ms 10.8 MB
020_levelComp4 👍 👍 1.23 ms 11.1 MB
021_levelComp5 👍 👍 1.22 ms 10.9 MB
022_imax1 👍 👍 1.23 ms 10.9 MB
023_imax2 👍 👍 1.23 ms 11.2 MB
024_levelMaxComm 👍 👍 1.23 ms 11.3 MB
025_levelMaxAssoc 👍 👍 1.24 ms 11.3 MB
026_levelMaxIdem 👍 👍 1.23 ms 11.1 MB
027_levelMaxAbsorb 👍 👍 1.24 ms 10.8 MB
028_inferVar 👍 👍 1.23 ms 11.0 MB
029_defEqLambda 👍 👍 1.25 ms 11.3 MB
030_peano1 👍 👍 1.37 ms 11.3 MB
031_peano2 👍 👍 1.43 ms 11.5 MB
032_peano3 👍 👍 1.50 ms 11.7 MB
033_letType 👍 👍 1.24 ms 11.0 MB
034_letTypeDep 👍 👍 1.25 ms 11.0 MB
035_letRed 👍 👍 1.23 ms 11.0 MB
036_empty 👍 👍 1.28 ms 11.4 MB
037_boolType 👍 👍 1.32 ms 11.4 MB
038_twoBool 👍 👍 1.39 ms 11.6 MB
039_andType 👍 👍 1.34 ms 11.5 MB
040_prodType 👍 👍 1.38 ms 11.5 MB
041_pprodType 👍 👍 1.39 ms 11.5 MB
042_pUnitType 👍 👍 1.30 ms 11.2 MB
043_eqType 👍 👍 1.36 ms 11.5 MB
044_natDef 👍 👍 1.34 ms 11.4 MB
045_rbTreeDef 👍 👍 2.02 ms 12.5 MB
046_inductBadNonSort ✋ ✋ 1.25 ms 11.1 MB
047_inductBadNonSort2 ✋ ✋ 1.22 ms 11.1 MB
048_inductLevelParam ✋ ✋ 1.21 ms 10.7 MB
049_inductTooFewParams ✋ ✋ 1.22 ms 10.7 MB
050_inductWrongCtorParams ✋ ✋ 1.26 ms 11.2 MB
051_inductWrongCtorResParams ✋ ✋ 1.26 ms 11.5 MB
052_inductWrongCtorResLevel ✋ ✋ 1.26 ms 11.4 MB
053_inductInIndex ✋ ✋ 1.25 ms 11.2 MB
054_indNeg ✋ ✋ 1.24 ms 11.0 MB
055_reduceCtorParam.mk 👍 👍 1.38 ms 11.6 MB
056_reduceCtorType.mk ✋ ✋ 1.29 ms 11.4 MB
057_indNegReducible ✋ ✋ 1.31 ms 11.4 MB
058_predWithTypeField 👍 👍 1.29 ms 11.4 MB
059_typeWithTypeField 👍 👍 1.30 ms 11.3 MB
060_typeWithTypeFieldPoly 👍 👍 1.31 ms 11.4 MB
061_typeWithTooHighTypeField.mk ✋ ✋ 1.24 ms 11.1 MB
062_emptyRec 👍 👍 1.28 ms 11.0 MB
063_boolRec 👍 👍 1.35 ms 11.5 MB
064_twoBoolRec 👍 👍 1.40 ms 11.7 MB
065_andRec 👍 👍 1.37 ms 11.6 MB
066_prodRec 👍 👍 1.40 ms 11.6 MB
067_pprodRec 👍 👍 1.42 ms 11.5 MB
068_punitRec 👍 👍 1.31 ms 11.5 MB
069_eqRec 👍 👍 1.38 ms 11.5 MB
070_nRec 👍 👍 1.36 ms 11.8 MB
071_rbTreeRef 👍 👍 2.13 ms 12.8 MB
072_boolPropRec 👍 👍 1.31 ms 11.1 MB
073_BogusRecursor ✋ ✋ 1.31 ms 11.2 MB
074_existsRec 👍 👍 1.38 ms 11.4 MB
075_typeSingletonRecReduction 👍 👍 1.54 ms 11.7 MB
076_sortElimPropRec 👍 👍 1.47 ms 11.6 MB
077_sortElimProp2Rec 👍 👍 1.49 ms 11.6 MB
078_boolRecEqns 👍 👍 1.61 ms 11.8 MB
079_prodRecEqns 👍 👍 1.60 ms 11.8 MB
080_nRecReduction 👍 👍 1.70 ms 12.0 MB
081_listRecReduction 👍 👍 1.95 ms 12.5 MB
082_RBTree.id_spec 👍 👍 3.37 ms 14.3 MB
083_And.right 👍 👍 1.38 ms 11.6 MB
084_Prod.snd 👍 👍 1.43 ms 11.5 MB
085_PProd.snd 👍 👍 1.45 ms 11.6 MB
086_PSigma.snd 👍 👍 1.49 ms 11.8 MB
087_projOutOfRange ✋ ✋ 1.36 ms 11.5 MB
088_projNotStruct ✋ ✋ 1.35 ms 11.4 MB
089_projProp1 👍 👍 1.54 ms 11.8 MB
090_projProp2 ✋ ✋ 1.55 ms 12.0 MB
091_projProp3 👍 👍 1.54 ms 12.1 MB
092_projProp4 ✋ ✋ 1.55 ms 12.1 MB
093_projProp5 ✋ ✋ 1.56 ms 11.7 MB
094_projProp6 ✋ ✋ 1.55 ms 11.8 MB
095_projDataIndexRec 👍 👍 1.49 ms 11.9 MB
096_projIndexData ✋ ✋ 1.80 ms 12.4 MB
097_projIndexData2 ✋ ✋ 1.79 ms 12.2 MB
098_projRed 👍 👍 1.65 ms 12.1 MB
099_ruleK 👍 👍 1.46 ms 11.7 MB
100_ruleKbad ✋ ✋ 1.51 ms 11.9 MB
101_ruleKAcc ✋ ✋ 1.81 ms 12.4 MB
102_aNatLit 👍 👍 1.34 ms 11.2 MB
103_natLitEq 👍 👍 1.47 ms 11.7 MB
104_proofIrrelevance 👍 👍 1.40 ms 11.6 MB
105_proofIrrelevanceBad ✋ ✋ 1.42 ms 11.8 MB
106_proofIrrelevanceWhnf 👍 👍 1.43 ms 11.7 MB
107_proofIrrelevanceUnderBinder 👍 👍 1.28 ms 11.2 MB
108_unitEta1 👍 👍 1.47 ms 11.7 MB
109_unitEta2 👍 👍 1.45 ms 11.7 MB
110_unitEta3 👍 👍 1.45 ms 11.6 MB
111_indexedUnitEta ✋ ✋ 1.54 ms 11.9 MB
112_structEta 👍 👍 1.77 ms 12.3 MB
113_indexedStructEta ✋ ✋ 1.60 ms 11.8 MB
114_funEta 👍 👍 1.41 ms 11.3 MB
115_funEtaDep 👍 👍 1.41 ms 11.7 MB
116_funEtaBad ✋ ✋ 1.45 ms 11.8 MB
117_reflOccLeft ✋ ✋ 1.36 ms 11.5 MB
118_reflOccInIndex ✋ ✋ 1.37 ms 11.6 MB
119_reduceCtorParamRefl.mk 👍 👍 1.40 ms 11.8 MB
120_reduceCtorParamRefl2.mk 👍 👍 1.41 ms 11.6 MB
121_rTreeRec 👍 👍 1.45 ms 11.7 MB
122_rtreeRecReduction 👍 👍 1.64 ms 11.9 MB
123_accRecType 👍 👍 1.56 ms 11.6 MB
124_accRecReduction 👍 👍 1.78 ms 12.1 MB
125_accRecNoEta ✋ ✋ 1.82 ms 12.5 MB
126_quotMkType 👍 👍 1.48 ms 11.6 MB
127_quotIndType 👍 👍 1.49 ms 11.7 MB
128_quotLiftType 👍 👍 1.50 ms 11.7 MB
129_quotSoundType 👍 👍 1.52 ms 11.8 MB
130_quotLiftReduction 👍 👍 1.54 ms 11.9 MB
131_quotIndReduction 👍 👍 1.54 ms 11.8 MB
132_dup_defs ✋ ✋ 1.24 ms 10.9 MB
133_dup_ind_def ✋ ✋ 1.27 ms 11.4 MB
134_dup_ctor_def ✋ ✋ 1.27 ms 11.3 MB
135_dup_rec_def ✋ ✋ 1.29 ms 11.4 MB
136_misnamed_rec_user ✋ ✋ 1.26 ms 11.1 MB
137_dup_rec_def2 ✋ ✋ 1.27 ms 11.2 MB
138_dup_ctor_rec ✋ ✋ 1.27 ms 11.5 MB
139_DupConCon ✋ ✋ 1.25 ms 10.9 MB
140_falseFromUnsafe ✋ ✋ 1.28 ms 11.4 MB
141_falseFromPartial ✋ ✋ 1.27 ms 11.5 MB