Philip Zucker

@sandmouth.bsky.social

Computer Friend, Not a Bird www.philipzucker.com

A new blog post "An Intuitionistic Micro Proof Assistant" www.philipzucker.com/kd_intu/ The basics to wrap an automated theorem prover (here intuitionistic FOL nanocopi) to make an embedded interactive theorem proving system. Reading Bell's smooth infinitesimals #python

An Intuitionistic Micro Proof Assistant

I’ve been tinkering on a solver-oriented interactive proof assistant as a library called Knuckledragger https://github.com/philzook58/knuckledragger .

philipzucker.com

A new blog post "Making TLA+ and x86 Kiss Via Z3Py" www.philipzucker.com/kissin_tla/ Basically, I'm type inferring on tla2tools.jar xml output to convert to z3py expressions, then using knuckledragger z3py stuff to talk to ghidra assembly semantics. Is this a useful direction?

Making TLA+ and x86 Kiss Via Z3Py

I’ve been trying my hand at translating a reasonable subset of TLA+ into z3py for the purposes of connecting specs to Verus, CBMC, and my assembly checker and also for maybe a little interactive theor...

philipzucker.com

Checking Equality-Saturation Merge and Extraction Certificates AF Ramos et al Equality-saturation engines maintain equalities in an e-graph and later extract a representative from an e-class. We verify an executable checker. For extraction a finite e-graph is represented as an ordered e-class DAG.

Checking Equality-Saturation Merge and Extraction Certificates

Checking Equality-Saturation Merge and Extraction Certificates in the Archive of Formal Proofs

isa-afp.org

A new blog post "A Theory of Arrays (ToA) Union Find" www.philipzucker.com/toa_unionfind/ Another non group union find inspired by semi-persistent arrays. You can support "store" annotations on edges if you swap data out of the "lattice" on the root when you reroot.

A Theory of Arrays (ToA) Union Find

One thing I’ve been discussing with Rudi, Michel and Max is union find annotations. Union find enhancements that still feel like union finds.

philipzucker.com

Z3! You're on WATCH! Latest update to lean.py is a drop in replacement for Z3! Everyone's trying to put SMT solvers in their theorem prover, how about putting a theorem prover in your SMT solver? and here's the crazy thing: One click install, if you know Z3, you KNOW lean.py. You are not ready.

A Z3-like reasoning API for Python, backed by Lean 4



Lean 4 is a general-purpose symbolic reasoning engine. Its tactic library covers linear arithmetic (omega), congruence closure with E-matching (grind), propositional decidability (decide), and rewriting (simp), and the system is designed to be extended with new sorts, constructors, and decision procedures. Every proof is independently checked by a small trusted kernel, so the Python side never needs to trust the automation; it trusts the checker. The overhead of learning Lean’s type theory and build system has kept most of this machinery out of reach for Python programmers.

lean_py.z3 wraps Lean’s tactic engine in the z3py API. Propositions are written in the familiar Int, Bool, Function, ForAll vocabulary. Under the hood, each expression compiles to a Lean 4 term, gets dispatched to the tactic engine, and the resulting proof is kernel-checked.

uv pip install "lean_py @ git+https://github.com/BasisResearch/lean.py"

You need elan so that lean is on your PATH. Then open Python.

from lean_py.z3 import *

x, y = Ints('x y')
prove(Implies(And(x > 0, y > 0), x + y > 0))
# proved

On the first run the library builds and caches a managed Lake project under ~/.lean_py/managed/, which takes a minute or two. Every subsequent run picks up the cache and starts instantly.
Kiran@kirancodes.me · 3mo ago

ML researchers know Python. Proof engineers know Lean. Never the two should meet.. Until now! Announcing Lean.py, effortless Lean to Python and Python to Lean bindings! - Write Lean tactics in Python - Access the Python ecosystem in Lean github.com/kiranandcode...

scheme-rs 0.2 has been released! Lots of new features but my favorite is the params system which allows you to share rust mutable variables over a scheme delimited continuation. This solves the “how do I share this mutable reference with my scripting language” problem github.com/maplant/sche...

Release Version 0.2.0 · maplant/scheme-rs

Added Added import restrictions system via allowlists (thanks @wizzeh!). Added automatically importing (rnrs (6)) if no imports are present in a scheme program. Added Basic threading library (thr...

github.com