← All engines

RUST ENGINE / verify_policy

Business rule and policy verification

Check discount stacks, tax brackets or access rules written as bounded linear rules: each stated limit holds over every allowed input, or a re-checked counterexample is returned.

In short. verify_policy is a ScoreCompute MCP tool computed in Rust (Rule verification). Provide spec, 5 to 16,384 characters: an optional mode line (policy sequential or policy first_match), bounded int and real inputs, bool and enum inputs (2 to 16 values), outputs with a starting value, assume, rule (=, +=, -=, *= by a constant) and assert statements, at most 48 variables and 64 rules. The verdicts cover the declared model only, not whether it matches the real rules, a contract or the law. It is callable at https://scorecompute.com/mcp over MCP Streamable HTTP, without an API key for bounded public access.

Open the verify_policy demonstration ↗Try the live calculation ↗Connect an AI assistant →

What does a real call return?

For a sequential discount policy with 4 bounded inputs and 2 additive rules, the assert cap40 ((discount <= 40)) returned violated: the input age = 65, amount = 100, vip = true, tier = pro fires senior and vip_perk and gives discount = 45. The counterexample was re-checked by the separate exact evaluator. The overall status is issues_found, with 0 conflicting rule pairs and 0 dead rules. Coverage is gap_found: some inputs fire no rule, for example age = 0, amount = 0, vip = true, tier = free, which keeps discount = 0. The run took 5 SMT queries in exact rational arithmetic.

Recorded on 26 November 2026 through the public MCP endpoint, service release 0.20.0. Inputs and full responses, response SHA-256 41fb8cbee83c…. Verdict values are the literal values the tool returns. Run the same inputs yourself to compare; elapsed times vary, and a new release may change the figures.

Checked against

Recorded on release 0.22.0. These checks cover the listed cases, not every input. Evidence cards.

How it works

The specification is parsed into bounded inputs, outputs, assumptions, rules and asserts. Each rule is encoded in static single assignment form (in order for sequential policies; with the earlier guards negated for first_match tables) and the formula is converted to clauses. A CDCL(T) SMT solver written in Rust (two-watched literals, conflict learning) works with a general Simplex over exact rationals with infinitesimals for strict inequalities (Dutertre and de Moura, Bland’s rule) and branch-and-bound for integer and enum variables. For each assert it searches for an allowed input where the limit fails; it also checks that the domain is not empty, which rules can fire, which pairs of direct assignments overlap with different values and whether some input fires no rule. Every witness is evaluated again by a separate exact interpreter before it is returned. No floating-point number is used in the solver or the re-check.

Inputs and units

Provide spec, 5 to 16,384 characters: an optional mode line (policy sequential or policy first_match), bounded int and real inputs, bool and enum inputs (2 to 16 values), outputs with a starting value, assume, rule (=, +=, -=, *= by a constant) and assert statements, at most 48 variables and 64 rules. Optional fields choose the checks and the level of detail.

What the result contains

overall_status (verified_clean, issues_found, domain_unsatisfiable or inconclusive), domain_status, each assert with its status (holds, violated, vacuous or inconclusive) and its counterexample, dead rules, conflicting rule pairs with a witness, coverage, counts, the solver work report with the limits reached, a SHA-256 digest of the canonical specification and verdicts, assumptions and limitations.

Example MCP call

{
  "name": "verify_policy",
  "arguments": {
    "spec": "policy sequential; int age 0..120; real amount 0..100000; bool vip; enum tier {free, pro}; real discount = 0; rule senior: age >= 65 & amount >= 100 => discount += 20; rule vip_perk: vip & tier == pro => discount += 25; assert cap40: discount <= 40;"
  }
}

Send this tool name and arguments through a connected MCP client. Discover the authoritative input schema with tools/list.

Call this engine in one command

Node.js 20+ and npm. This downloads a small remote MCP client; it does not install the engine locally.

npx --yes --package https://scorecompute.com/downloads/scorecompute-call-0.14.2.tgz scorecompute-call verify_policy --arguments '{"spec":"policy sequential; int age 0..120; real amount 0..100000; bool vip; enum tier {free, pro}; real discount = 0; rule senior: age >= 65 & amount >= 100 => discount += 20; rule vip_perk: vip & tier == pro => discount += 25; assert cap40: discount <= 40;"}'

Client download, PowerShell input and verification →

Direct MCP access

verify_policy is independently callable. It is deliberately not connected to the automatic planner, so nothing passes its results to another engine for you. Two tools returning similar JSON fields does not mean their results are compatible.

Cite this engine

Version 0.1.0, source SHA-256 ce7be7e92946…. Evidence recorded on release 0.22.0; the public service currently runs 0.22.0. Replace the access date when you cite it.

ScoreCompute. Business rule and policy verification (verify_policy), version 0.1.0, source SHA-256 ce7be7e929466f1e689a113e083ee8b7ae4029bb12565336b1cfac03aed9f69c. Evidence release 0.22.0, service release 0.22.0. https://scorecompute.com/engines/verify-policy/ (accessed YYYY-MM-DD).

All engine citations · Evidence card

Execution and availability

ScoreCompute exposes this tool through MCP Streamable HTTP. Rust computation runs on a connected worker; the public website and MCP gateway run separately. Among these 28 scientific tools, CUDA is implemented for simulate_pi; the other scientific engines run on CPU. The separate contributor network runs two compiled public workloads: a π estimate and fixed synthetic schedule probes. Requests are bounded and concurrent work may be refused when capacity is occupied.

Record inputs, assumptions and returned provenance when sharing a result. The public observatory displays software client names and tool activity, without publishing calculation arguments or results.

Explore another engine →Agent-readable overview ↗

Related guide

Formal business rule & policy verification with SMT: catching silent stacking bugs →

Sources

These publications describe the method or a reference used in its tests. Citing them does not certify this implementation.

First published 25 November 2026 · Last updated 25 November 2026