ROLL: forth_roll_def implemented a third, invented convention matching neither the theory's own test lemma nor the real C stack_word_roll(). Traced the actual C source (src/word_source/stack_words.c:287-320) and its passing tests (stack_words_test.c roll_1/roll_2) to the real semantics -- ROLL is 1-indexed from the BOTTOM of the stack, not top-indexed as the old definition assumed. Rewrote forth_roll_def to match, replaced the false roll_one_nop/roll_two_is_rot with lemmas verified against the actual test vectors. PICK: forth_pick_def indexed into the pre-pop stack (still containing the count n as its own head) instead of the post-pop stack, off by one position, plus a bound check one too permissive. Fixed against src/word_source/ stack_words.c:265-282 and its pick_0/pick_1/pick_2 test vectors. pm_wf: pm_record_hit_preserves_wf/pm_record_miss_preserves_wf were oops-flagged as a genuine invariant gap. Fixed with the minimal added hypothesis (pm_last_accuracy_den pm > 0), matching this session's established discipline. Also documents a deeper finding: pm_last_accuracy_num/den don't correspond to any field in the real PipelineGlobalMetrics C struct (which has a single "double last_checked_accuracy", not a fraction) -- flagged for a separate field-level audit, not attempted here. All 23 theory files verify with zero errors.
proof/
Isabelle/HOL theory files providing machine-checkable proofs of determinism and correctness for StarForth. 24 theory files covering all 7 feedback loops, core word categories, and the word-level ACL system.
Running proofs
isabelle build -D proof/
Requires an Isabelle installation. See docs/01-getting-started/DEVELOPER.md.
Theory files
Foundations
| File | Covers |
|---|---|
StarForth_Base.thy |
Base definitions and type system |
StarForth_Correctness.thy |
Overall correctness |
StarForth_Transition.thy |
State transitions |
StarForth_Concurrent.thy |
Concurrency properties |
StarForth_Mutex.thy |
Mutual exclusion |
Physics loops (1–7)
| File | Loop |
|---|---|
StarForth_Loop1_Heat.thy |
Execution heat tracking |
StarForth_Loop2_Window.thy |
Rolling window of truth |
StarForth_Loop3_Decay.thy |
Linear decay |
StarForth_Loop4_Pipeline.thy |
Word transition prediction |
StarForth_Loop5_WinInf.thy |
Window width inference |
StarForth_Loop6_DecayInf.thy |
Decay slope inference |
StarForth_Loop7_Heartrate.thy |
Adaptive heartrate |
Word categories
StarForth_Arithmetic_Words.thy, StarForth_Stack_Words.thy,
StarForth_Logical_Words.thy, StarForth_Memory_Words.thy,
StarForth_Return_Stack_Words.thy, StarForth_Q48_16.thy
ACL system (Phase 6)
| File | Property |
|---|---|
ACL_Pin_Monotone.thy |
Pin is one-way |
ACL_Inherit_Clears_Pin.thy |
Inheritance clears pin |
ACL_TTL_Bounded.thy |
TTL stays within bounds |
ACL_Emergency_Bypass.thy |
Emergency console bypass |
ACL_No_Escalation.thy |
No privilege escalation |
See also
ROOT— Isabelle project manifest- Project root