Skip to main content
M

Midspiral

Midspiral provides open‑source tools that add mathematical verification to AI‑generated code, ensuring the software behaves as specified. Their npm package LemmaFit lets an AI write code alongside a formal proof, which an external verifier checks, and their TypeScript verification toolchain translates specification comments into Lean 4 or Dafny for provable correctness.

CambridgeFounded 20252100+ followers
Updated 1 month ago

Funding

Funding not disclosed

Funding rounds are not available yet.

Founders

Founder details are not available yet.

Product

Problem

AI-generated code can contain subtle logical errors that are difficult to detect with testing alone, leading to unreliable software and costly debugging. Developers lack tools that can automatically verify that such code conforms to its intended specifications before deployment.

Solution

Midspiral offers open‑source tools that integrate formal verification into AI‑assisted coding workflows. The npm package LemmaFit enables an AI agent to produce both implementation code and a machine‑checked proof, rejecting any code that cannot be proven correct. Their TypeScript verification toolchain, LemmaScript, lets developers annotate ordinary TypeScript with specification comments (preconditions, postconditions, invariants) which are compiled into Lean 4 or Dafny for automated proof checking. A VSCode extension provides the underlying verification engine, managing proof orchestration and communication with external verifiers. By embedding these verification steps directly into the development loop, Midspiral ensures that AI‑generated code is mathematically guaranteed to meet its specifications before it is compiled.

Target Audience

Primary users are software engineers and development teams that employ AI code generation tools and need formal guarantees of correctness for TypeScript applications, particularly in safety‑critical or high‑reliability domains.

Features

  • LemmaFit npm package that couples AI code generation with automatic generation and validation of formal proofs
  • LemmaScript toolchain that translates TypeScript specification comments into Lean 4 or Dafny verification targets
  • Support for both new (greenfield) and existing TypeScript codebases without requiring major refactoring
  • VSCode extension that orchestrates proof checking, manages verification daemons, and bridges AI agents with external provers
  • Open‑source licensing, allowing developers to adopt and extend the verification stack freely
  • Planned verified kernels for common web‑app state management patterns, compiled to JavaScript
This profile is AI-generated and may contain inaccuracies.