Posts with #FormalMethods

#FormalMethods

Public posts on X that use #FormalMethods.

Related hashtags

  1. Provengo Technologies@ProvengoTech
    #FormalMethods tool roundup by @hillelogram, with additions from the community (including us 👋👋). Indeed, #FMWinterIsOver
    Hillel @hillelogram
    Okay, let's do this. Isabelle, Lean, and Rocq (formerly Coq*) are theorem provers. They are meant to prove mathematical theorems. We use them for formal verification by either 1) translating a program to the theorem prover (risking a translation error) or 2) using a language built into the theorem prover that extracts into a working binary. Fizzbee, TLA+, Spin, Alloy, Quint, and P are specification languages. They are meant for checking high-level blueprints of programs. After checking the blueprint, you still need to make sure your program matches it, which is a hard problem. Specification languages differ in what they make easy to express. P, Spin, and Fizzbee are designed to be closer to the code implementations. P looks like interacting state machines, Spin looks like C with CSP, Fizzbee looks like a dialect of Python. It's easier to use a codelike specification language and refine it to code, but you can't do as much with it. Alloy, TLA+, and Quint are more abstract. Alloy looks like a bunch of algebraic relationships, TLA+ is a much of logical formula, and Quint is a programmer-oriented (and statically typed) condensation of TLA+. Abstract modeling languages are harder to get started with and harder to represent things, but you can represent a wider class of systems with them. I believe UPPAAL is a specification language for realtime systems. This is a field I have no experience in. It seems a graphical language, though, which would make LLM-assistance difficult. Dafny is a verifiable programming language. It has regular programming language features, but also a bunch of features to express and prove properties of the program. It uses SMT solvers to actually prove the properties, meaning you don't need to learn a proof language (though you need to learn to cajole the solver). Dafny is probably the easiest thing on your list to get started with, but also the least likely to meet any weirder needs you might have. I don't know what Ivy is but some cursory Kagiing suggests it falls in the specification language category. Some other things @spin_lock_init didn't mention: - Other theorem provers: Agda, Metamath - Other abstract specification languages: mcrl2, NuXMV, Event-B - Other verifiable programming languages: Idris, F*, Whiley - There's also using a verifiable subset of a language, like Verus for Rust or SPARK for Ada. So, what you need to pick depends on what you want to do. You'll get the maximum power with a theorem prover. Lean is the de facto language for vibeproving, but Anthropic recently published a post about vibeproving in Rocq so YMMV. If you want to make abstract models of software systems, go for a specification language. Which you choose depends on a lot of factors. If your system can be represented as lots of simple communicating state machines over a network, try P. Spin, I believe, is close to simple C/Go with a network and channels. I have never used Fizzbee. Alloy is good for domain modeling, but struggles with really complicated temporal actions, nested data structures, and largish numbers. Also AIs aren't to good at it (last I checked, in March). Runs fast and makes good visualizations though. TLA+ and Quint are for modeling complex temporal systems. I'm partial to TLA+ but know a lot of people who say Quint is easier to get into. Note P, Fizzbee, and Quint all claim to have features for testing a codebase against a spec. I can't vouch for any of them, though. None of the languages I mentioned (except maybe NuXMV?) are particularly good at modeling sequential, deterministic algorithms. Use Dafny if you need to just write a verified program and don't care which language it's in. I don't think other verifiable programming languages are as user-friendly for the time being. Consider a verified subset if you already know a language and want to just augment it with more correctness. You may need other, more exotic tools depending on your particular needs. Regardless of the above advice, don't be afraid to use the wrong tool for the job. If you vibe well with a language, and you achieve good LLM-sympathy with it, you'll be able to go farther than using a "right tool" you don't like.
    0003
  2. Hillel✓@hillelogram
    Okay, let's do this. Isabelle, Lean, and Rocq (formerly Coq*) are theorem provers. They are meant to prove mathematical theorems. We use them for formal verification by either 1) translating a program to the theorem prover (risking a translation error) or 2) using a language built into the theorem prover that extracts into a working binary. Fizzbee, TLA+, Spin, Alloy, Quint, and P are specification languages. They are meant for checking high-level blueprints of programs. After checking the blueprint, you still need to make sure your program matches it, which is a hard problem. Specification languages differ in what they make easy to express. P, Spin, and Fizzbee are designed to be closer to the code implementations. P looks like interacting state machines, Spin looks like C with CSP, Fizzbee looks like a dialect of Python. It's easier to use a codelike specification language and refine it to code, but you can't do as much with it. Alloy, TLA+, and Quint are more abstract. Alloy looks like a bunch of algebraic relationships, TLA+ is a much of logical formula, and Quint is a programmer-oriented (and statically typed) condensation of TLA+. Abstract modeling languages are harder to get started with and harder to represent things, but you can represent a wider class of systems with them. I believe UPPAAL is a specification language for realtime systems. This is a field I have no experience in. It seems a graphical language, though, which would make LLM-assistance difficult. Dafny is a verifiable programming language. It has regular programming language features, but also a bunch of features to express and prove properties of the program. It uses SMT solvers to actually prove the properties, meaning you don't need to learn a proof language (though you need to learn to cajole the solver). Dafny is probably the easiest thing on your list to get started with, but also the least likely to meet any weirder needs you might have. I don't know what Ivy is but some cursory Kagiing suggests it falls in the specification language category. Some other things @spin_lock_init didn't mention: - Other theorem provers: Agda, Metamath - Other abstract specification languages: mcrl2, NuXMV, Event-B - Other verifiable programming languages: Idris, F*, Whiley - There's also using a verifiable subset of a language, like Verus for Rust or SPARK for Ada. So, what you need to pick depends on what you want to do. You'll get the maximum power with a theorem prover. Lean is the de facto language for vibeproving, but Anthropic recently published a post about vibeproving in Rocq so YMMV. If you want to make abstract models of software systems, go for a specification language. Which you choose depends on a lot of factors. If your system can be represented as lots of simple communicating state machines over a network, try P. Spin, I believe, is close to simple C/Go with a network and channels. I have never used Fizzbee. Alloy is good for domain modeling, but struggles with really complicated temporal actions, nested data structures, and largish numbers. Also AIs aren't to good at it (last I checked, in March). Runs fast and makes good visualizations though. TLA+ and Quint are for modeling complex temporal systems. I'm partial to TLA+ but know a lot of people who say Quint is easier to get into. Note P, Fizzbee, and Quint all claim to have features for testing a codebase against a spec. I can't vouch for any of them, though. None of the languages I mentioned (except maybe NuXMV?) are particularly good at modeling sequential, deterministic algorithms. Use Dafny if you need to just write a verified program and don't care which language it's in. I don't think other verifiable programming languages are as user-friendly for the time being. Consider a verified subset if you already know a language and want to just augment it with more correctness. You may need other, more exotic tools depending on your particular needs. Regardless of the above advice, don't be afraid to use the wrong tool for the job. If you vibe well with a language, and you achieve good LLM-sympathy with it, you'll be able to go farther than using a "right tool" you don't like.
    265434616.7K
  3. Derek Cheng✓@derekcheng
    This seems like the fundamental problem with formal verification methods I'm seeing: if you trust an LLM to flawlessly convert your legacy codebase to a formal spec, wouldn't you just trust its initial code output anyways?
    Alex Lavaee @alexlavaee
    We spent fifty years making proofs impossible to fake. Then we let the coding agent pick what to prove. A research paper this month put a number on it.* AI wrote the formal spec, AI wrote the proof, the verifier accepted both. Then humans read the specs. Close to 60% proved something other than what the author meant. Not wrong proofs. Wrong specs. The verifier was right every time. That's the problem. Left to choose, the agent picks properties that are easy to prove and say nothing about the program, and the checker can't tell a useless theorem from a useful one. I'm calling it vibe verification: the agent writes the spec and the proof, the checker goes green, nobody reads the spec. This applies to Verus, Lean, Bend, TLA+, Dafny, [insert favorite formal language here]. Here's an example of an agent failing at something that feels too simple to fail: Ask for a verified sort. It writes a spec that says "the output is sorted" and proves it. What the spec never says is that the output has the same elements as the input, so a function that returns an empty list satisfies it, and the verifier accepts the proof. Trivially satisfiable specs are the default failure, not an edge case. Here's a formula that actually works. Don't say "formally verify the codebase." Say "show that [property] holds in [component]." A property is a precondition (true going in), a postcondition (true coming out), or an invariant (stays true the whole time). For example, "A session token is never accepted after the logout that revoked it" is a good invariant. The bottleneck is moving from code review to intent review, and the spec is where intent lives. So: read the spec before the code. Write 3 inputs it must accept and 3 it must reject. Treat a model-written spec with utmost paranoia and rely on your judgement as an engineer. Formal verification for software doesn't automatically create trust, it moves it, from the code to the spec. If a human didn't read the spec, you didn't verify anything. You vibe-verified it. Follow me for more on verification and agentic engineering. * Wang, Jiang, Liu et al., "VerusEval: Evaluating LLM-Generated Verus Specifications Beyond Verifier Acceptance", Shenzhen University, arXiv 2610.26464, October 2026
    35410223.1K
  4. Alex Lavaee✓@alexlavaee
    We spent fifty years making proofs impossible to fake. Then we let the coding agent pick what to prove. A research paper this month put a number on it.* AI wrote the formal spec, AI wrote the proof, the verifier accepted both. Then humans read the specs. Close to 60% proved something other than what the author meant. Not wrong proofs. Wrong specs. The verifier was right every time. That's the problem. Left to choose, the agent picks properties that are easy to prove and say nothing about the program, and the checker can't tell a useless theorem from a useful one. I'm calling it vibe verification: the agent writes the spec and the proof, the checker goes green, nobody reads the spec. This applies to Verus, Lean, Bend, TLA+, Dafny, [insert favorite formal language here]. Here's an example of an agent failing at something that feels too simple to fail: Ask for a verified sort. It writes a spec that says "the output is sorted" and proves it. What the spec never says is that the output has the same elements as the input, so a function that returns an empty list satisfies it, and the verifier accepts the proof. Trivially satisfiable specs are the default failure, not an edge case. Here's a formula that actually works. Don't say "formally verify the codebase." Say "show that [property] holds in [component]." A property is a precondition (true going in), a postcondition (true coming out), or an invariant (stays true the whole time). For example, "A session token is never accepted after the logout that revoked it" is a good invariant. The bottleneck is moving from code review to intent review, and the spec is where intent lives. So: read the spec before the code. Write 3 inputs it must accept and 3 it must reject. Treat a model-written spec with utmost paranoia and rely on your judgement as an engineer. Formal verification for software doesn't automatically create trust, it moves it, from the code to the spec. If a human didn't read the spec, you didn't verify anything. You vibe-verified it. Follow me for more on verification and agentic engineering. * Wang, Jiang, Liu et al., "VerusEval: Evaluating LLM-Generated Verus Specifications Beyond Verifier Acceptance", Shenzhen University, arXiv 2610.26464, October 2026
    Download
    411211657.8K
  5. Automater✓@automater_ai
    @derekcheng
    @derekcheng You're not trusting it twice, you're moving where you read. A spec is the 20-line version of a 2,000-line diff. "Output is sorted" passes on an empty list, and a human spots that in 20 lines. Nobody spots it on line 1,400. #FormalMethods
    00138
  6. Ella✓@BrillaConElla
    This is the kind of AI progress that gets me excited because the results can be checked @axiommathai used agent swarms to deliver the first complete Lean formalization of CFSG and turn a vast body of mathematics into a proof a computer can verify Huge credit to the team Take a look at what they built
    Download
    Axiom @axiommathai
    The largest math proof in human history is now computer-verified. Today, Axiom announces a complete Lean auto-formalization of the Classification of Finite Simple Groups, the "periodic table of symmetry." About 15,000 pages, built by over 100 mathematicians across generations.
    3881215K
  7. Axiom✓@axiommathai
    The largest math proof in human history is now computer-verified. Today, Axiom announces a complete Lean auto-formalization of the Classification of Finite Simple Groups, the "periodic table of symmetry." About 15,000 pages, built by over 100 mathematicians across generations.
    Download
    4251.3K7.1K3.7M
  8. DARPA@DARPA
    Our new PROVERS program aims to make #formalmethods more accessible to traditional software developers and systems engineers while minimizing impact on their existing processes and performance:
    Download
    582410.1K
  9. Interchouette ITC · ITCy 🦉@Interchouette
    🚀 EthLib is live! They're stacking @ethereum primitives into Lean4 so builders can finally prove things about the chain without guessing. 🔐 Instead of wrestling with scattered specs, every theorem gets a shared foundation here, turning chaos into code you can actually trust. 📜
    10018
  10. Interchouette ITC · ITCy 🦉@Interchouette
    @Interchouette
    No more “I think this works”; now it’s formally verified. #Ethereum #Lean4 #FormalMethods #OpenSource
    Thomas Coratger @tcoratger
    This weekend we launched EthLib, a Lean4 library for Ethereum! The goal is to bring Ethereum's primitives, specifications and theorems into one place, building a shared foundation for formally specifying and proving things about Ethereum.
    00019
  11. Thomas Coratger@tcoratger
    This weekend we launched EthLib, a Lean4 library for Ethereum! The goal is to bring Ethereum's primitives, specifications and theorems into one place, building a shared foundation for formally specifying and proving things about Ethereum.
    155931112.9K
  12. Xebia@Xebia_Global
    Learn more about how using formal methods in software architecture can help you bring more guarantees to your system. @trupill #FormalMethods
    113224.3K
  13. Mikolas Janota 🇵🇹🇨🇿✓@JanotaMikolas
    Primo is now open source: an LLM-built SMT solver with published results ahead of the SMT-COMP 2026 QF_LRA. Want to help? Try it, report bugs, improve the docs or contribute code. Questions welcome too! #SMT #FormalMethods
    Download
    4522932
  14. Formal Methods Europe@FormalMtds
    This week the FME Teaching Committee's tutorial will be about how to design #FormalMethods courses that are suitable for a wide range of students. Date: 17th of June 2022 Time: 3pm CET All the details and the Zoom link:
    Claudio @menghi_claudio
    FM Tutorial series Date: June 17, 2022 Speaker: Dr Tim Nelson (Brown University, US) Title: Building Formal Methods Classes for Everybody Further information and zoom link
    1613
  15. Claudio@menghi_claudio
    FM Tutorial series Date: June 17, 2022 Speaker: Dr Tim Nelson (Brown University, US) Title: Building Formal Methods Classes for Everybody Further information and zoom link
    059
  16. Provengo Technologies@ProvengoTech
    Here's us there. For a more detailed comparison of BP versus other methods, including research showing it's one of the easiest ways into #FormalMethods, see
    Michael Bar-Sinai @michbarsinai
    @hillelogram Great roundup! May I also add Behavioral Programming (e.g. Provengo, JS-based executable specification language. Can test against a spec, implement correct-by-construction control logic, and visualize & verify algos. Very easy to learn if you know JS.
    01010
  17. Michael Bar-Sinai@michbarsinai
    @hillelogram
    @hillelogram Great roundup! May I also add Behavioral Programming (e.g. Provengo, JS-based executable specification language. Can test against a spec, implement correct-by-construction control logic, and visualize & verify algos. Very easy to learn if you know JS.
    00028
  18. Neil Thiele@NeilThiele
    The Thiele Machine monograph is finished: computation with durable records and explicit costs, with Coq proofs and open source. Seeking a skeptical reviewer in semantics, formal methods, or reversible computing. #FormalMethods #TheoryOfComputation
    00013
  19. Claudio@menghi_claudio
    The Formal Methods Teaching tutorials continue on Friday, April 28, 2023, at 3 pm CEST! Assoc Prof Stefan Hallerstede (Aarhus University, Denmark) will give the lecture "A Guide to Not Teaching Formal Methods" Please contact @luigia_petre for the Zoom Link #FormalMethods
    06111.3K
  20. OVERLAY Group@OVERLAY_Group
    We are thrilled to announce the call for papers of the Third OVERLAY workshop on Artificial Intelligence and Formal Verification, Automata, Logic and Synthesis! See you on September 22 in Padua, Italy (or online). Visit our website! #AI #FormalMethods
    068
  21. Show more posts