Formally verified 3D CSG mesh intersection: trust 93 lines of spec, not AI code

A new project, verified-3d-mesh-intersection, implements a formally verified 3D constructive solid geometry (CSG) mesh intersection in Lean 4. The key idea: trust only 93 lines of formal specification, not the 1000+ lines of AI-written implementation code. The AI automatically wrote over 60,000 lines of Lean proofs, which never need human review — the Lean checker guarantees correctness at compile time.
How it works
The specification pins down the exact surface of the resulting mesh and guarantees well-formedness conditions on the triangulation. The core identity:
solid (meshIntersect M1 M2) = solid M1 ∩ solid M2where solid represents the infinite set of points inside a mesh. Lean can reason about these infinite sets and prove the equality exactly.
Key details
- Language: Lean 4, compiled to WebAssembly via
emcc-wasm.sh. - Performance: 24 seconds to intersect two 70k-triangle Stanford bunny meshes. Slow but prioritizes verification over speed.
- Web demo: Runs the verified kernel in-browser at schildep.github.io/verified-3d-mesh-intersection. Supports STL import. No data sent to server.
- Human review: Only the 93-line spec needs reading. The 1000+ lines of AI implementation and 60k+ lines of AI proofs are treated as black boxes.
- Well-formedness: If inputs are not well-formed (e.g., non-closed or self-intersecting), the algorithm must detect and report correctly — formalized in the spec.
Who it's for
Developers working with 3D geometry, CSG operations, or formal verification, especially those skeptical of trusting AI-generated code without guarantees.
Architecture
The repository contains the Lean kernel (CSG/), a C wrapper (wrapper.c), and web glue code (web/). Build commands are provided via lakefile.lean, emcc-wasm.sh, and build_web_demo.sh. The UI and glue code are not formally verified.
📖 Read the full source: HN LLM Tools
👀 See Also

Claude App Store Rankings Across 7 Countries
Claude ranked #1 in the US and Canada, #3 in France and Germany, #4 in the UK, #8 in Italy, and #22 in Japan in App Store free app rankings captured simultaneously on March 1, 2026 at 09:00 UTC.

Mercury 2: Diffusion-Based Model for Real-Time AI Coding
Mercury 2 uses diffusion-based generation instead of sequential token-by-token decoding, generates tokens in parallel and refines them over steps, and claims 1,009 tokens/sec on NVIDIA Blackwell GPUs with pricing at $0.25/1M input tokens and $0.75/1M output tokens.

Claude Code v2.1.37 Released
Anthropic releases a new version of Claude Code with improvements and bug fixes.

Claude-Code v2.1.33: Enhancing Automation with Precision
The latest release of Claude-Code v2.1.33 introduces key features that further revolutionize AI coding agents, boosting both efficiency and accuracy.