Write a business rule once. Get the same answer everywhere.

Rules in YAML or JSON, checked before they ship and enforced the same way by your form, your API, your batch jobs and your AI agents.

Free to use under the Apache License 2.0.

- id: customer.full-name.required
  kind: validation
  operations: [create, update]
  assert:
    op: not
    args: [ { fn: isBlank, args: [ { var: data.fullName } ] } ]
  severity: error
  finding: { code: ONB-STR-001, message: fullName.required }
A new customer whose full name is
  • TypeScriptdeny ONB-STR-001 Enter your full name.
  • Javadeny ONB-STR-001 Enter your full name.
  • Godeny ONB-STR-001 Enter your full name.
  • Pythondeny ONB-STR-001 Enter your full name.
  • rcasdeny ONB-STR-001 Enter your full name.
  • WebAssemblydeny ONB-STR-001 Enter your full name.
One rule from the example catalog. More than 1,900 conformance cases hold every engine to the same result.
One ruleset, checked and sealed once, then enforced the same way by every engine.

What it is for

Validation rules, limits, eligibility checks and approvals that a form, an API, a batch job and an AI agent must all apply the same way.

How it works

  1. Step 1

    Write

    Describe the data and write rules in YAML or JSON, with golden tests beside them.

  2. Step 2

    Check

    rcas check refuses unknown fields and failing golden tests before anything ships.

  3. Step 3

    Seal

    The rules compile into one bundle with a checksum: the exact version every engine runs.

  4. Step 4

    Evaluate

    Your form, API, job or agent asks for a decision and gets findings, field states and values.

Install

rcas is one static binary for macOS, Linux and Windows. It checks, compiles and evaluates rulesets and serves the Model Context Protocol to AI coding tools.

curl -fsSL https://rulescascade.com/install.sh | sh

Then run rcas version. The scripts check the binary against SHA256SUMS before they install it. Options, libraries for each language and the Docker image: Install.

rcas 1.0.0-alpha.11

Every file is signed with Sigstore. Checksums, signatures and WebAssembly: Download and verify.

Two people, one rule

The owner decides what a rule says; the engineer decides where it runs. They change different files.

Two people, one rule: the rule owner edits the ruleset and its golden tests; the engineer loads the bundle onceRule ownerparameters, messages, testsEngineerform and API, oncePull requestone reviewed change
WhoWhat they get
Product or policy ownerChanges a limit, a message or an example in one reviewed file
DeveloperWires the engine once and deletes duplicated validation
QAThe golden tests in the ruleset are the acceptance criteria
Audit and complianceEvery decision names the ruleset version and checksum
Platform and AI teamsServices, jobs and agents apply the same rule

The steps are in the playbook Author and ship a rule change.

Watch the three classes

One rule, every place it applies3:26Why it exists, in a bank's transfer limit.
Two people, one rule3:35An expense receipt rule, from policy change to production.
From zero to enforced5:45An insurance claims form, start to finish.

Start here

Status

1.0.0-alpha.11. The specification is a draft and may change before 1.0; see the changelog.

Each release publishes the rcas command as signed downloads and on npm (@rules-cascade/cli), and the libraries on npm (@rules-cascade/*), PyPI (rule-cascade), Maven Central (rules-cascade-core) and the Go module proxy (rulescascade.com/go). They are free to use under the Apache License 2.0.