Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+21 more

    Formal Verification Discipline — SMT Solver Proof Hygiene

    1

    Enforces a rigorous SMT solver discipline to prevent silent errors and false positives in formal verification.

    $13

    Secure checkout via Stripe

    Money-back guarantee

    Converts to your local currency at checkout

    Security scanned
    Formal Verification Discipline — SMT Solver Proof Hygiene

    Formal Verification Discipline — SMT Solver Proof Hygiene

    Example session with this skill installed

    I have a new z3 script for a trace identity. Check if it follows the verification discipline before I run the full campaign.

    • Read your context and instructions
    • Compiled the formal verification discipline

    I have audited your z3 script against the formal verification discipline. While the logic for the identity is sound, the script currently lacks per-check timeout handling and does not explicitly print a model when SAT is found.

    SMT Verification Audit

    RequirementStatusObservation
    Counterexample SearchPASSUses s.add(left != right) pattern correctly.
    Manual DerivationFAILNo hand-derived trivial case (d=2) found in comments.
    Per-check TimeoutFAILset_param is missing; script may hang on large d.
    Expansion LogicPASSLeft side is fully expanded; no tautological rewrites.
    Limit DeclarationWARNINGScript does not state which sizes it is intended to close.

    Improved Solver Configuration

    import z3
    
    def verify_identity(left, right, label):
        s = z3.Solver()
        # Enforce discipline: per-check timeout (20s)
        z3.set_param('timeout', 20000)
        
        # Search for counterexample
        s.add(left != right)
        
        print(f"Checking {label}...")
        r = s.check()
        
        if r == z3.unsat:
            print(f"RESULT: THEOREM (UNSAT) for {label}")
        elif r == z3.sat:
            print(f"RESULT: SAT - Counterexample found: {s.model()}")
        else:
            print(f"RESULT: TIMEOUT/UNKNOWN - {label} is UNPROVEN")
    
    # Trivial hand-check (d=2) recorded:
    # Trace(A) where A=[[1,2],[3,4]] is 5. Claim: Tr(A)=5. 
    # Matches hand derivation.
    

    Next steps

    1. Insert the manual derivation for the d=2 case into the script header.
    2. Add the set_param call inside your check loop to handle high-degree terms.
    3. Update your proof ledger to mark any UNKNOWN results as unproven rather than skipped.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Formal verification with SMT solvers like z3 or NLSat often fails because of silent errors. A solver returning UNSAT might mean your theorem is correct, or it might mean you accidentally encoded a tautology or missed a term. This skill enforces a rigorous mathematical discipline to ensure your proofs are actually valid and your solver scripts are reliable.

    What it does

    • Enforces counterexample construction by requiring a left != right search pattern rather than simple side-by-side rewrites.
    • Validates manual derivations by checking the trivial base case by hand before the solver ever runs.
    • Configures execution limits by mandating per-check timeouts and explicit TIMEOUT/UNKNOWN handling to prevent false positives.
    • Documents solver limits by embedding the specific sizes and parameters that closed (or failed to close) directly within the script.
    • Prevents encoding corruption by providing specific PowerShell UTF-8 handling for scripts containing mathematical symbols.

    How it works

    1. Initial Claim Review: State the mathematical claim in a single sentence and derive a trivial case by hand to catch basic encoding errors.
    2. Encoding Audit: Review the SMT script to ensure one side of the equation is fully expanded and no tautologies exist.
    3. Execution Setup: Verify that set_param('timeout', ...) is applied per check and that the script handles non-terminating checks as "unproven."
    4. Result Recording: Update the proof ledger with what was proven, at what sizes, and which conjectures were refuted.

    Frameworks & tools

    Python-based SMT solvers including z3-solver and NLSat. It also includes specific encoding fixes for PowerShell 5.1 environments.

    Why this beats prompting it yourself

    Standard LLMs often trust a solver's UNSAT result blindly, leading to "verified" claims that are actually based on flawed logic or tautologies. This skill forces a specific working order—learned from real-world failures—that treats a timeout as a failure rather than a success and mandates manual arithmetic checks to ground the AI's logic.

    Use cases

    • Adding a new theorem to a project proof ledger.
    • Debugging a solver script that returns suspicious UNSAT results.
    • Extending existing solver scripts to larger dimensions or higher degree terms.
    • Managing complex inequality proofs where manual verification is impossible but encoding errors are likely.

    Known limitations

    This skill does not provide the solver binaries or scripts themselves. It is a discipline for auditing and writing them within the user's existing environment.

    Does not provide solver binaries. Requires the user to maintain their own proof ledger. Focuses on Python-based SMT solver patterns.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before any payment.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Money-back guarantee

    Doesn't do what its page promises? You get your money back.

    Trust & safety

    Security scan

    Security scan passed 20 days ago

    Permissions

    Terminal / Shell
    Read Files
    Listed20 days ago

    What's inside

    Frequently Asked Questions

    Enforces a rigorous SMT solver discipline to prevent silent errors and false positives in formal verification.

    This skill uses the open SKILL.md standard. Use it through an MCP-compatible agent connected to Agensi, and check the compatibility information on this page for confirmed agents and required capabilities.

    Connect your AI agent to Agensi through MCP, then ask it to use Formal Verification Discipline — SMT Solver Proof Hygiene on your task. Your agent loads the latest approved version each time. Paid skills require a purchase or active subscription. Skill files are not available for download; your licence does not allow you to save, copy or export any part of a skill.

    New in Testing & Debugging