Rule Cascade
Reference

Changelog

All notable changes are recorded here. The format follows Keep a Changelog and the project uses Semantic Versioning.

All notable changes are recorded here. The format follows Keep a Changelog and the project uses Semantic Versioning.

[Unreleased]

Changed

  • A lone UTF-16 surrogate is refused everywhere. A string, or a member name, holding a surrogate that is not part of a pair (such as "\ud800") makes a request malformed: RequestError (400) in every runtime and BAD_REQUEST from an engine. A ruleset holding one fails to load with SCHEMA_INVALID (specification 4.1, 5 and 8). Before, the runtimes disagreed: Go read it as U+FFFD, and Python, JavaScript and Java kept it, so length, matches and equality could answer the same request differently. A surrogate pair is one character, as before.
  • Go: ParseJSON keeps a lone surrogate escape as the three bytes UTF-8 would give that code unit, where encoding/json put U+FFFD, and Marshal writes it back as the escape. That is what lets Go refuse such a request like the other runtimes. Before, the Python compiler crashed on a member name holding one.
  • The 422 answer to a denied operation no longer shows server-only rules. problem() and the problem-details helpers (problemDetails, problem_details, ProblemDetails, RuleViolationException.problemDetails) keep only the findings and effects of rules on the client channel; a denial by a server-only rule shows as one finding with code RULE-DENIED, no rule, no source and no fields. enforce passes the ruleset's client rules for you; when you build the answer yourself, pass them (rules.clientRules(), rules.client_rules(), rules.ClientRules()), because without them no finding is shown. The error keeps the whole result for the server's logs (specification section 9). Before, a rule left out of the client manifest still sent its id, message and parameters to the browser through the error path.

[1.0.0-alpha.11] - 2026-11-02

Added

  • The skills from rulescascade.com. https://rulescascade.com/skills.git serves the skills, the four sub-agents and the two commands without rcas, after each release: a plugin for Claude Code (/plugin marketplace add https://rulescascade.com/skills.git) and GitHub Copilot CLI, and Agent Skills for Codex, Cursor, Gemini CLI and any other tool (npx skills add https://rulescascade.com/skills.git). The plugin starts the local MCP server.

  • rules-cascade-architecture skill. Written for every project by rcas agent install: how Rule Cascade is designed (pipeline, bundles, engine forms, what the server decides, inheritance, the design decisions) and how a project sets it up.

  • rcas mcp --http: RCAS_MCP_READ_TIMEOUT_SECONDS and RCAS_MCP_IDLE_TIMEOUT_SECONDS. A client now gets 30 seconds to send a request body, and is answered 408 after that, so one that trickles a body cannot hold a connection open; streams are not affected. An idle keep-alive connection is closed after 620 seconds; before, it was never closed, which let idle connections pile up.

  • Rule server: settings for the request body limit, the HTTP timeouts and the evaluation queue. RULE_SERVER_MAX_BODY_BYTES (default 1 MiB), RULE_SERVER_KEEP_ALIVE_TIMEOUT_MS (65 s), RULE_SERVER_HEADERS_TIMEOUT_MS (66 s), RULE_SERVER_REQUEST_TIMEOUT_MS (120 s) and, with workers, RULE_SERVER_MAX_QUEUE (256 per worker); embedded, the createRuleServer options maxBodyBytes, keepAliveTimeoutMs, headersTimeoutMs, requestTimeoutMs and maxQueue. The defaults are exported (DEFAULT_MAX_BODY_BYTES and the others).

  • Rule server: CORS for the public endpoints, off by default. RULE_SERVER_CORS_ORIGINS (a comma-separated list of origins, or *) lets a page on another site read the ruleset list, client manifests and rule details with createManifestClient: the server answers the preflight that If-None-Match causes and exposes ETag. Before, that preflight was answered 405 and the browser refused the manifest. The server manifest, bundles and evaluations are never opened to another origin, also on a server without a token, and rule details asked from another site come from the client channel. With CORS configured, a caller that sends Origin gets client-channel rule details even with the token; a server-side caller should leave Origin out. RULE_SERVER_CORS_MAX_AGE (default 600 s); embedded, corsOrigins and corsMaxAgeSeconds.

  • Rule server: RULE_SERVER_REQUEST_LOG=off (embedded: requestLog: false) leaves out the log line per request, for platforms that already log every request; the load test then answers about 13 % more requests per second. Request lines are now written in batches, once per turn of the event loop, instead of one write each; warnings and errors are still written at once.

  • A Support page on rulescascade.com. /support and a Support link in the header send a reader to a Stripe Payment Link where they choose the amount of a one-time contribution. The site holds no Stripe key; the address comes from NEXT_PUBLIC_SUPPORT_URL, and without it the link and the page are left out of the build.

  • Specification 1.1: isDate and isDateTime. They are true when a value is a date, or a date-time, that the date operators accept, and false for anything else; they are never an evaluation error. A rule can now check 1990-02-30 and show the user a message, where an age rule used to fail closed with "This rule could not be evaluated." A ruleset that uses them declares ruleCascade: 1.1.0 (ADR 0010).

  • A ruleset that needs a newer runtime is refused when it loads (VERSION_UNSUPPORTED). Every runtime checks the ruleCascade of a document, of its parent, of each manifest of a bundle and of a single manifest; an absent value in a manifest is 1.0.0, so existing bundles keep loading. A ruleset whose resolved ruleCascade is 1.0 and that uses a 1.1 operator does not load (OPERATOR_NOT_IN_VERSION). The resolved ruleset, and every manifest, takes the parent's ruleCascade when its minor version is later; patch versions never change it, so the checksums of existing rulesets do not change. The engine's version command answers ruleCascade: 1.1.0.

  • Runtimes up to 1.0.0-alpha.10 do not read a manifest's ruleCascade: as evaluators they load a 1.1 bundle and fail closed on every request that reaches isDate; as compilers they refuse isDate (SCHEMA_INVALID). Upgrade every runtime that evaluates a ruleset before the ruleset declares 1.1.0.

Changed

  • rcas mcp --http compares RCAS_MCP_TOKEN in constant time whatever its length, as SHA-256 digests. Go's subtle.ConstantTimeCompare returns at once for a token of another length, which told an attacker the token's length.

  • The rule server keeps idle connections open for 65 s, not 5 s. Node.js closes an idle keep-alive connection after 5 s, before the 60 s idle timeout of common load balancers, so a load balancer could reuse a connection the server had just closed and answer 502. A client now gets 120 s, not 300 s, to send a whole request.

  • The rule server compares the token in constant time whatever its length, as SHA-256 digests; before, a token of another length was refused faster, which told an attacker the token's length. A refusal now carries WWW-Authenticate: Bearer, and every answer X-Content-Type-Options: nosniff.

  • The Go module reads YAML with go.yaml.in/yaml/v3, the YAML organization's maintained continuation of gopkg.in/yaml.v3, which was archived and gets no more fixes. The API is the same; a Go project that uses rulescascade.com/go gets the new module with its next update.

  • The home page of rulescascade.com has a header. It used the documentation layout, so on a desktop it showed only the sidebar. It now has Docs, Learn, Try it, Examples, Changelog, search, the theme switch and an Install button across the top, and an Install section with the one-line installs and the signed downloads of the newest release.

  • The rcas downloads are built with Go 1.27, the newest Go release.

  • CI also tests Java 27, the current Java release, next to the LTS releases 17, 21 and 25. The minimum stays Java 17.

  • The install scripts check which repository signed a release. --verify cosign (and -Verify cosign on Windows) also passes --certificate-github-workflow-repository YarlisAISolutions/rule-cascade, so a release workflow in another repository of the organization no longer passes. The download page's manual steps do the same.

  • Docs: the cookbook shows how to disable a field by operation and by a feature flag passed in ctx, and why the flag needs a coalesce default. The React form playbook maps enabled to disabled.

  • Site: the home page opens with one rule and the result every engine returns for it, and the long paragraphs are now short sections, one row of videos and grouped links.

Removed

Rule Cascade supports and tests every runtime release that is not end of life, and no release that is. These releases have reached end of life, so support for them ends:

  • Node.js 20. The npm packages need Node.js 22 or later (engines). CI tests 22, 24 and 26.
  • Python 3.10. The Python package needs Python 3.11 or later (requires-python). CI tests 3.11 to 3.15.
  • Go 1.22 to 1.25. The Go module needs Go 1.26 or later (go in go.mod): a project on an older Go can no longer build it. CI tests 1.26 and 1.27. The public Go module gets the new go line with the next release.
  • macOS 12. The macOS downloads are built with Go 1.27, which needs macOS 13 or later.

Fixed

  • The rule server checks PORT, DRAIN_SECONDS and its other numbers at start-up. A value such as DRAIN_SECONDS=5s was read as no number at all, so SIGTERM stopped the process at once instead of draining it, and a bad PORT crashed it with an uncaught ERR_SOCKET_BAD_PORT. Now a value that is not a whole number in range, an empty one included, stops the process with exit code 1 and a fatal line that names the variable. Values that used to work and now stop the process: a fractional DRAIN_SECONDS such as 0.5, an empty PORT (it listened on a random port) or an empty RULE_SERVER_WORKERS. A delay longer than Node.js timers honour (2^31−1 ms, about 24.8 days) is refused too, since it would fire after 1 ms. createRuleServer refuses a bad maxBodyBytes or evaluationTimeoutMs too.

  • The download links on rulescascade.com save the file. The hosting rules that send the rcas binaries and rcas.wasm as attachments still named them rule-cascade-*, so after the rename a browser saved rcas-darwin-arm64 and rcas-linux-amd64 as .html files and got the Windows .exe with a guessed type. A test now checks the rules against the list of release files.

  • The one-line install leaves rcas runnable on every system. irm https://rulescascade.com/install.ps1 | iex installed into %LOCALAPPDATA%\Programs\rcas but added it to PATH only with -AddToPath, which that form cannot pass, so rcas was "not recognized" afterwards. install.ps1 now adds the directory to the user PATH by default, and install.sh adds one marked line to the shell's startup file when ~/.local/bin is not on PATH (macOS never has it there). --no-modify-path, -NoModifyPath or RCAS_NO_MODIFY_PATH=1 turn this off; -AddToPath is still accepted. A weekly Install check workflow runs every documented install command on Linux, macOS and Windows, amd64 and arm64, against rulescascade.com.

  • rulecheck derive writes the shortest path to the OpenAPI file when the output or the input path goes through a symbolic link (macOS /var is /private/var). The header named a path that climbed to the root and back, and the tool tests failed on macOS.

  • Go and Python: a ruleset with deeply nested invalid expressions is rejected quickly. The time to check it grew exponentially with the depth: 18 levels took about 2 seconds in Go and 40 seconds in Python, so a few kilobytes sent to rcas mcp --hosted could hold a CPU for minutes. The same documents are accepted and refused as before, with the same error codes. New load-error cases pin it down.

  • Python: the engine no longer stops on a string with a lone surrogate. A request such as {"command":"expression","expr":"\ud800"} ended the python -m rule_cascade engine process, and later requests got no answer. The answer is now written with the surrogate escaped.

  • Python: a version number of more than 4300 digits is compared, not an error. An extends version range that long raised ValueError instead of EXTENDS_VERSION_MISMATCH, and could end the engine. Versions are now compared as numbers of any size, as in the other runtimes.

  • Python and TypeScript: an evaluation error shows at most 80 characters of the value, followed by ..., as Go does. A 100 KB string passed to add made a 100 KB message.

  • @rules-cascade/client: a manifest fetched by checksum must have that checksum. When the answer to get(id, { checksum }) holds another version, it is an error: the manifest is not stored, and with staleIfError the held copy is returned. A server that ignores ?checksum=, or a cache that leaves the query string out of its key, could otherwise swap in another version.

[1.0.0-alpha.10] - 2026-10-19

Fixed

  • Java: the package reaches Maven Central again. 1.0.0-alpha.9 is not on Maven Central: built with Maven 3.10, central-publishing-maven-plugin 0.11.0 left maven-metadata-local.xml and _remote.repositories in the bundle, and Central refused it ("Bundle has content that does NOT have a .pom file"). The plugin is now 0.12.0, which removes them, so this is the first version on Maven Central since 1.0.0-alpha.8.
  • Site: the Java page installs from Maven Central. It said the package was not published there and showed Gradle with mavenLocal(); the Gradle example now uses mavenCentral().

[1.0.0-alpha.9] - 2026-10-19

Changed

  • rcas analyze reports paths relative to the project (the directory of rcas.yaml), not to the path given, so reports of several paths and SARIF files agree. --include and --exclude match either. A line can now give more than one hit, one per detector. A line that starts with # is skipped as a comment only in Python, Ruby, PHP and Drools, so C and C++ #define limits are read.

Fixed

  • Engines: an invalid cache setting answers LOAD_FAILED in every runtime (specification section 13). The engine keeps running, answers version, still answers a malformed request with BAD_REQUEST, and answers every other command with LOAD_FAILED, an empty problems list and a message that names the setting but not its value. In 1.0.0-alpha.8 the Python and Go engines answered BAD_REQUEST to load and compile, EVALUATION_ERROR to matches and ok elsewhere; the Java engine answered LOAD_FAILED even to a malformed request; and the TypeScript engine exited at start-up. The WebAssembly host run.mjs now passes the RULE_CASCADE_* variables to the module. New conformance file conformance/engine-settings.json, run by the driver over every engine.
  • Site: the home page videos' uploadDate has a time and timezone. Search Console reported it as invalid and missing a timezone. docs/brand/videos/build.py writes an ISO 8601 date and time, and the build fails when site/lib/videos.json holds anything else.
  • Site: Sam appears after leaving the playground through search. A documentation page opened from /try through the search dialog kept the playground's Content-Security-Policy, which blocked Sam's widget. A documentation page opened from /try without a full page load now reloads once, so it gets its own policy.

Added

  • rcas analyze finds rules in every supported language, by module, feature and change. It reads TypeScript, JavaScript, Python, Java, Kotlin, Scala, Go, C#, Razor, Ruby, PHP, Rust, Swift, Dart, C and C++, Angular, Vue and Svelte templates, Drools .drl and DMN. New detectors: named limits (MAX_QUANTITY = 10, const MaxQuantity = 10, #define), a name compared with a number (amount > 10000), status branches (case, when, match arms), checks that throw, raise, return Err or require, authorization (Spring Security, NestJS, Django, ASP.NET, Laravel, Pundit), the validation libraries of each language (react-hook-form, Angular Validators, Flutter ...), and conditions in React, Angular, Vue, Svelte, Blazor, SwiftUI and Compose. Each hit has its module (the nearest build file: Maven, Gradle, sbt, npm, Go, Python, Cargo, .NET, Composer, Bundler, Swift, Dart, CMake), feature, confidence, fingerprint, and the name, operator and value it compares. The report lists candidates, one name decided in several languages, with drift when the values differ, and marks the hits a project ruleset already names (coveredBy). New options: several paths, --module, --feature (with analyze.features in rcas.yaml), --changed <git-ref>, --baseline and --write-baseline, --min-confidence, --max-hits and --format sarif for GitHub code scanning; RCAS_ANALYZE_MAX_FILES, RCAS_ANALYZE_MAX_HITS and RCAS_ANALYZE_MIN_CONFIDENCE override the limits. The MCP analyze tool and the capture-rules prompt take the same scope.
  • rcas agent install gives every AI coding tool commands, code instructions and limited sub-agents, in its own format. /rcas-capture (find the rules in a path, module or feature and propose rulesets) and /rcas-review as Claude Code commands, Copilot prompt files, Gemini CLI and Tabnine TOML commands, OpenCode, Factory, Junie, Kilo and Augment commands, and Devin workflows, each with the user's argument where the tool puts it; for the other tools, the rules-cascade-capture skill. Instructions scoped to the application code of the project's languages (and, for Claude Code, to the rulesets too) in .claude/rules/, .github/instructions/, .cursor/rules/, .kiro/steering/, .devin/rules/ and .clinerules/. Sub-agents limited to the tools their role needs: tools for Copilot, Gemini CLI, Kiro and Junie, permission for OpenCode, tools: read-only for Factory; new sub-agents for Gemini CLI, Kiro and Augment. The analyst role and the skills describe modules, features, drift, and one ruleset per module with one child per feature.
  • Site: Sam, the chat assistant, is on the documentation pages. Sam answers questions about Rule Cascade from the pages on rulescascade.com, links the pages it used, and checks the rulesets it writes with the hosted rule server before showing them. The playground (/try) has no chat. When Sam isn't sure, it points to support@rulescascade.com.
  • Site: video chapters are key moments. Each video's structured data lists its chapters as Clips, with its captions file and an ISO 8601 duration. ?video=<name>&t=<seconds> opens the home page at that video and time.

[1.0.0-alpha.8] - 2026-10-08

Added

  • MCP: HTTP, the 2026-07-28 protocol, and a hosted server. rcas mcp --http <addr> serves the Model Context Protocol over Streamable HTTP at /mcp, and over the deprecated HTTP+SSE transport at /sse for older clients (--no-sse leaves it out). Both transports and standard input and output speak every revision from 2024-11-05 to 2026-07-28: server/discover, per-request _meta, resultType, cache hints and subscriptions/listen, and initialize for older clients, all without sessions. The HTTP server binds 127.0.0.1 by default, checks Origin, takes an optional bearer token (RCAS_MCP_TOKEN) and limits request size. rcas mcp --hosted serves no project: each tool takes the ruleset files as its files argument and keeps nothing; it is what https://mcp.rulescascade.com/mcp runs. The HTTP server answers GET /health (and /healthz).

  • The hosted MCP server is live at https://mcp.rulescascade.com/mcp. No installation: point any agent that takes a URL at it (rcas mcp install <tool> --url https://mcp.rulescascade.com/mcp, or a Claude.ai custom connector). It runs on Cloud Run from deploy/mcp/ (image, service definition and provision.sh), scales to zero and stores nothing.

  • MCP: prompts, resource templates and completions. The prompts derive-rules, capture-rules, review-ruleset and explain-decision; the templates rcas://docs/{topic}, rcas://spec/{section} and rcas://rulesets/{id}; completion of their arguments. Tools have titles and idempotentHint.

  • rcas mcp install --url <url> registers a server reached over HTTP, in the entry shape each tool documents (type: http, httpUrl for Gemini CLI, serverUrl for Devin, url in Codex's TOML and others).

  • Site: three narrated videos on the home page. One rule, every place it applies (why, a bank's transfer limit, 1:24), Two people, one rule (a policy owner and an engineer change an expense rule, 2:01) and From zero to enforced (how to use rcas, an insurance claims form, 3:43). Each has English captions and chapters that seek the video, and the home page describes them to search engines as VideoObject. docs/brand/videos/ holds the concept, the agendas, the demo rulesets and build.py, which builds them again.

  • TypeScript: cache sizes can be set. selectionCacheSize (a load option), setPathCacheSize, setMaxCachedPathLength and setPatternCacheSize, or the environment variables RULE_CASCADE_SELECTION_CACHE_SIZE, RULE_CASCADE_PATH_CACHE_SIZE, RULE_CASCADE_MAX_CACHED_PATH_LENGTH and RULE_CASCADE_PATTERN_CACHE_SIZE (defaults 256, 4096, 256 and 2048; 0 turns a cache off). checkCacheSettings() checks them; loading a ruleset does too, and the rule server exits at start-up on an invalid value, which is never echoed.

  • Python: the matches pattern cache size can be set. set_pattern_cache_size or the environment variable RULE_CASCADE_PATTERN_CACHE_SIZE (default 2048; 0 turns the cache off). An invalid value makes loading refuse every ruleset with ConfigurationError (engine: BAD_REQUEST) and is never echoed.

  • Java: cache sizes can be set. The path cache and the matches pattern cache take Expressions.setPathCacheSize / setPatternCacheSize, the system properties rulecascade.pathCacheSize / rulecascade.patternCacheSize, or the environment variables RULE_CASCADE_PATH_CACHE_SIZE / RULE_CASCADE_PATTERN_CACHE_SIZE (defaults 4096 and 2048; 0 turns a cache off). Paths longer than RULE_CASCADE_MAX_CACHED_PATH_LENGTH (default 256) are never cached. An invalid value fails when a RuleSet is built (engine: LOAD_FAILED) and is never echoed.

  • Go: the matches pattern cache size can be set. SetPatternCacheSize or the environment variable RULE_CASCADE_PATTERN_CACHE_SIZE (default 2048; 0 turns the cache off). An invalid value makes loading refuse every ruleset, with an error that names the variable but not its value.

  • Site: Rule Cascade compared with OPA, CEL, JSON Logic and Drools (/get-started/compared): what each one is for, where they differ, and when to choose which.

  • Site: sitemap.xml can give each page's last change (<lastmod>), the date of the last commit to the file the page is built from, so search engines recrawl the pages that changed. The dates need the full git history; a build without it (no git, or a shallow clone) leaves them out rather than guess.

Changed

  • Site: the home page videos are short classes. A teacher's voice talks a small room through each question, the slides change as each point is made, and two questions from the room end each video. The voices are Google Cloud Text-to-Speech instead of the macOS voice.
  • TypeScript and the rule server: evaluation is faster (about 1.6–2× on the benchmark; p50 about 16–21 → 9–11 µs): a ruleset caches its rule selection per entity and operation and checks it against the rules on every evaluation, variable paths are split once, and plain numbers compare without decimal conversion. Results are unchanged. The matches pattern cache now holds 2048 patterns (was 1000).
  • Python: evaluation is faster (about 10–13% on the benchmark): expression shapes are checked without sorting their keys, and rule selection skips work a request does not need. Results are unchanged.
  • Java: evaluation is faster (about 1.6× on the benchmark; p50 about 4.8 → 3 µs): variable paths are split once and cached, and a RuleSet prepares each manifest once. Results and error messages are unchanged.
  • Go: evaluation is faster (about 20–26% on the benchmark, 37% fewer allocations): variable paths are read without splitting, small decimals take a fast path, and each manifest's rules are ordered once at load and planned again whenever its rules change. Results are unchanged.
  • Signature checks name the organization, not the source repository. The download page, install.sh and install.ps1 verify signatures against a release.yml workflow of the YarlisAISolutions organization, run from a v tag. Every existing signature still verifies. The public site's build now also fails on the private repository's name written with escaped dots.

Fixed

  • rcas: nested YAML aliases can no longer expand a short file without end. A ruleset or API document may expand to ten times the nodes it is written with; past that, loading stops with "the aliases of the document expand too much". A 400-byte file took 6 seconds before and a slightly longer one could exhaust memory.
  • Install: npm install @rules-cascade/cli, npx and docker run without a version get the newest release. Until the first final release, a pre-release is also published as npm and GHCR latest; before, latest stayed on 1.0.0-alpha.4 while pip, Go and the install scripts gave the newest.
  • Site: the manual Windows and Linux steps of Download and verify install the command as rcas, where rcas version finds it (they installed it as rule-cascade), and on Windows in the install script's directory. The --version examples name a version that exists.
  • A long locale no longer slows evaluation. Every runtime built every prefix of the requested tag, so a tag of thousands of subtags cost time and memory that grew with the square of its length. Prefixes longer than the longest catalog tag are now skipped: they cannot name a catalog, so messages are unchanged. The specification now lists the fallback chain in full (fr-CA-x-a consults fr-CA-x too) and says an empty subtag is a subtag; new conformance cases cover both.
  • Python: the compiled-pattern cache is bounded. It kept every pattern it ever compiled, so a long-running process that reloads rulesets grew without limit; it now holds at most RULE_CASCADE_PATTERN_CACHE_SIZE patterns.
  • The site's icon shows in search results. The site served its icon only as SVG; it now also serves /favicon.ico (16, 32 and 48 px), a 192 px PNG and an Apple touch icon, which Google and phones look for.

[1.0.0-alpha.7] - 2026-10-06

Added

  • The site is ready for search engines and link previews. The home page title and text say what Rule Cascade is ("business rules engine for TypeScript, Java, Go and Python"), every page carries Open Graph and X card tags with a preview image (/og.png), and the home page describes the product in schema.org JSON-LD.
  • Enforce in one line, in every language. enforce evaluates and returns an allowed result, or raises a rule-violation error whose problem() is the 422 answer (RFC 9457 problem details with the evaluation), built identically everywhere (conformance/problem-details.json):
    • TypeScript: rules.enforce, RuleViolationError, problemDetails, and @rules-cascade/core/http with rulesMiddleware (Express, Connect), rulesErrorHandler and rulesPreHandler (Fastify), no framework dependency.
    • Python: rules.enforce, RuleViolation, problem_details, the @enforce_rules decorator (sync and async, pydantic models, current_evaluation()), and rule_cascade.fastapi, .flask and .django to answer 422.
    • Java: rules.enforce, RuleViolationException with problem(); the Spring Boot example adds @EnforceRules with its aspect, ready to copy.
    • Go: rules.Enforce, *RuleViolation, ProblemDetails, and the rulehttp package with Enforce middleware for net/http.
  • Your first rule in an app: a walkthrough for beginners, from rcas init to an Express, FastAPI, Spring Boot or Go service that refuses a bad order, and changing the rule without changing code.
  • Skills for every stack. rcas agent install writes skills in the open Agent Skills format to .agents/skills/: rules-cascade, rules-cascade-review, rules-cascade-migrate, and one per language of the project (-typescript, -python, -java, -go, -engine for any other language). The languages come from --stack, languages in rcas.yaml, or the files found in the project.
  • Twenty AI coding tools. Besides Claude Code, Codex, Copilot, Cursor and Gemini CLI, agent install writes for Kiro, Devin (formerly Windsurf), JetBrains Junie, Cline, OpenCode, Factory, Amazon Q and Tabnine, and covers Meta Muse Code, Amp, Goose, Warp, Zed, Kilo Code and Augment through AGENTS.md and .agents/skills/. Sub-agents for Codex, Copilot, Cursor, Junie, OpenCode and Factory as well as Claude Code.
  • rcas mcp install writes for copilot-cli, kiro, devin, junie, cline, opencode, kilo, factory, amp, zed, warp, augment, amazonq and muse, each in the shape its tool expects.
  • rcas agent list shows every tool, whether the project uses it and what an install writes. rcas doctor warns when a tool the project uses is missing its files.
  • agents.tools in rcas.yaml fixes the tools for the whole team.
  • Reference page AI coding agents.

Changed

  • Contact: support@rulescascade.com for security and conduct reports and in every package's metadata (was support@sdods.com).
  • New release signing key 76DEE260FCBCC12B610ABABAC668E8410522AD0D (Ed25519, identity Rule Cascade releases <support@rulescascade.com>), on keys.openpgp.org and keyserver.ubuntu.com. Releases up to 1.0.0-alpha.6 stay signed by EA4FA781CD906ED62FB1C8341C70DE86DB43612C.
  • Package metadata on every registry. npm: keywords, author and support contact on every package. PyPI: authors, keywords, classifiers (status, Python 3.10 to 3.14, frameworks), extras rule-cascade[fastapi], [flask], [django], and links to the walkthrough and the security policy. Maven: organisation and developer contact, Automatic-Module-Name: com.rulescascade for the module path, implementation entries and a reproducible-build timestamp in the jar. The server image gets description, vendor and source revision labels. @rules-cascade/cli requires Node.js 20.
  • rcas agent install writes for the tools the project uses, no longer for five tools always: --for, then agents.tools in rcas.yaml, then the tools it finds (CLAUDE.md, .cursor/, .kiro/ ...). --for all writes for every tool.
  • Generated skills, sub-agents and rule files carry an rcas-managed line and are refreshed by every install; delete the line to keep your own edits. Files an earlier rcas wrote and nobody edited since are refreshed too; edited ones are kept.
  • Copilot gets .github/instructions/rules-cascade.instructions.md, applied to rulesets, instead of a block in .github/copilot-instructions.md: Copilot reads AGENTS.md itself. The Cursor rule points to AGENTS.md instead of repeating it.
  • The rcas binaries are built with Go 1.26 (were 1.24, which no longer gets security fixes).
  • CI tests every supported runtime: Java 17, 21 and 25; Python 3.10 to 3.14; Node 20, 22, 24 and 26; Go 1.22 (the minimum) and the current stable release.

[1.0.0-alpha.6] - 2026-10-06

Changed

  • Rule Cascade has its own domain: https://rulescascade.com. The documentation, the downloads, install.sh and install.ps1 are served there; rules.sdods.com redirects every path to the same path on the new domain, so existing links and scripts keep working.
  • The Go module is rulescascade.com/go (go install rulescascade.com/go/cmd/rcas@latest). Versions up to 1.0.0-alpha.5 remain available as rules.sdods.com/go; to move, replace the import path and require 1.0.0-alpha.6 or later.
  • The schema $id is https://rulescascade.com/schema/v1/rule-cascade.schema.json. The old address redirects to it.
  • Java coordinates. The Java runtime is com.rulescascade:rules-cascade-core and its package is com.rulescascade (was com.sdods.rules:rules-cascade-core, com.sdods.rules.cascade). It had not been published to Maven Central under the old name.
  • The site tells search engines that rulescascade.com is the canonical address (canonical links, sitemap.xml, robots.txt).

[1.0.0-alpha.5] - 2026-10-06

Added

  • Java on Maven Central: com.sdods.rules:rules-cascade-core, signed with the release key EA4FA781CD906ED62FB1C8341C70DE86DB43612C.
  • Signed downloads on the site: rules.sdods.com/download/, install.sh and install.ps1 serve the signed rcas files, starting with 1.0.0-alpha.4.

Fixed

  • npm ci in a checkout: the repository no longer declares the @rules-cascade/cli-* platform packages; the release adds them to the published @rules-cascade/cli at its exact version.

[1.0.0-alpha.4] - 2026-10-06

Changed

  • Java coordinates. The Java runtime is com.sdods.rules:rules-cascade-core and its package is com.sdods.rules.cascade (was io.github.yarlisaisolutions:rule-cascade-core, io.github.yarlisaisolutions.rulecascade). It had not been published to Maven Central under the old name.

Fixed

  • npx -y @rules-cascade/cli <command> runs rcas. In 1.0.0-alpha.3 the package declared two commands, and npx could not tell which to run, so MCP configurations that start the server with npx failed. The npm package now provides rcas only; the install scripts and go install still provide rule-cascade.

[1.0.0-alpha.3] - 2026-10-06

Added

  • rcas, the Rule Cascade command (it replaces rule-cascade, which stays as an alias): init scaffolds a project (rcas.yaml, a first ruleset with golden tests, CI, a loading guide per language); check and test read the project's rules; compile --all; analyze inventories API schemas and validation code in an existing code base; derive builds baseline rulesets from OpenAPI or JSON Schema (a Go port, byte-identical to the reference); proposals reviews what an agent proposed; doctor; shell completion.
  • AI coding tools. rcas mcp is a Model Context Protocol server whose only write is a proposal under .rcas/proposals/; rcas mcp install registers it with Claude Code, Codex, Cursor, Windsurf, Gemini CLI and VS Code; rcas agent install writes AGENTS.md, CLAUDE.md, GEMINI.md, Copilot and Cursor rules, Claude sub-agents and a skill.
  • Distribution. npm @rules-cascade/cli (with one package per platform), the install scripts https://rules.sdods.com/install.sh and install.ps1, and go install rules.sdods.com/go/cmd/rcas@latest.

Changed

  • The Go module is rules.sdods.com/go, published from the public mirror YarlisAISolutions/rule-cascade-go. The source repository is private; the packages stay free under the Apache License 2.0.
  • Release files are named rcas-<os>-<arch> and rcas.wasm.
  • The schema $id is https://rules.sdods.com/schema/v1/rule-cascade.schema.json.

[1.0.0-alpha.2] - 2026-10-05

The project is now called Rule Cascade. A ruleset is compiled once into a JSON bundle and evaluated identically by Python, TypeScript, Java and Go, by a single-file command for Linux, macOS and Windows, and by a WebAssembly module. The conformance suite has 1899 cases.

Licence

  • Free packages under the Apache License 2.0, Copyright (c) 2026 Yarlis LLC; it replaces the MIT License chosen earlier in this version. LICENSE and NOTICE are in every package (npm, PyPI, the Maven jar under META-INF, the Go module), and every manifest declares Apache-2.0. The source repository is private: the manifests point at https://rules.sdods.com instead of a repository, vulnerabilities are reported to support@sdods.com, and the Go module is published from a public mirror as rules.sdods.com/go.
  • Packages on the public registries. After the signed release, a tag v<version> on main runs the whole CI suite and then publishes to npm and PyPI with trusted publishing, to Maven Central (signed, with sources and javadoc; off until enabled), tags the Go module and pushes a multi-platform server image with a provenance attestation to GHCR. npm packages now publish to npmjs.com instead of GitHub Packages. See docs/releasing.md.

Breaking

  • The npm packages moved to the @rules-cascade scope and split in four. Nothing had been published under the old names. @yarlisaisolutions/rule-cascade is now:

    • @rules-cascade/common: the rule, bundle and manifest types, the cron schedule (@rules-cascade/common/cron) and VERSION. No dependencies.
    • @rules-cascade/core: evaluation and compilation, @rules-cascade/core/loader, and the rule-cascade-node command. It re-exports everything in common, so type imports keep working.
    • @rules-cascade/client: createManifestClient and localStorageAdapter (moved from core), and the React hook at @rules-cascade/client/react (was @yarlisaisolutions/rule-cascade/react).

    @yarlisaisolutions/rule-cascade-server is now @rules-cascade/server. The release publishes them in that order. Java, Python and the server image keep their names. The schema $id is now https://rules.sdods.com/schema/v1/rule-cascade.schema.json, where the site serves it.

  • Name. Rule Contract became Rule Cascade. The document key is ruleCascade (was ruleContract), the schema is spec/v1/rule-cascade.schema.json, the OpenAPI extension is x-rule-cascade, the npm packages are @rules-cascade/common, core, client and server (see the npm entry above), the Maven artifact is rule-cascade-core and the Java package is io.github.yarlisaisolutions.rulecascade.

  • Specification: checksums. The resolved ruleset has the new members types, functions and operators and the renamed key, so the checksum of every ruleset changes.

  • Specification: findings. finding.component is replaced by finding.location, an object with the page, screen, section and component the rule's target names.

  • Specification: patterns. matches accepts only the portable subset of section 4.4. \s and \b, which alpha.1 allowed, are rejected; . matches line breaks; $ is the very end of the string; counts, nested counts multiplied and the pattern length are limited to 1000.

  • Specification: numbers. A JSON number is the IEEE 754 double nearest to what was written, in every runtime. Every number leaving the engine is rounded to 15 significant digits, whether it was computed or passed through. A number beyond the range of a double is refused on the way in and is an evaluation error on the way out.

  • Specification: strictness. An object that is not exactly {var}, {op, args} or {fn, args} is not an expression; an unknown root is null; list indexes are runs of ASCII digits. Dates are written with ASCII digits and nothing after the value, offsets go up to 23:59, and the UTC date lies in the years 0001 to 9999. lower changes only the ASCII letters.

  • Specification: evaluation. A state rule applies all of its effects or none. An evaluation request is shape-checked and refused before anything is evaluated.

  • Specification: YAML. A ruleset in YAML is read by the YAML 1.2 core schema: unquoted no, on and 2026-10-03 are strings. Scalars that YAML 1.1 and 1.2 read differently must be quoted.

  • Tools. rulecheck export and rulecheck corpus are replaced by rulecheck sync. tools/rulecheck.py is no longer the reference implementation; it is the command-line front end of packages/python.

  • Rule server: a token is required (breaking for deployers). The server refuses to start without RULE_SERVER_TOKEN: it logs a fatal line and exits 1 before loading any rules. Set RULE_SERVER_ALLOW_OPEN=1 to serve every endpoint without a token, on a private network only. Embedded, createRuleServer throws unless it is given token or allowOpen: true. The Kubernetes deployment no longer marks the token Secret optional.

  • Specification: patterns. A group that repeats must not contain an unbounded quantifier ((a+)+, (a*){2,}): such a pattern backtracks exponentially and is refused with PATTERN_NOT_PORTABLE. matches refuses a subject longer than 10000 code points with an evaluation error.

  • Specification: nesting depth. An evaluation request whose data, original, actor or ctx is nested more than 64 deep (also every root of env in the expression command) is refused with BAD_REQUEST before anything is evaluated, and a rule expression or function body nested more than 128 deep fails the load with EXPRESSION_TOO_DEEP. Depth is checked before recursing, so no runtime can overflow its stack.

  • TypeScript compiler. Schema validation stops at the first problem (Ajv allErrors: false): reporting every problem took time exponential in expression depth. compile now reports the first schema problem only.

Added

  • Specification: locale fallback. A message is read from the catalog of the requested locale, then from each shorter prefix of the tag (fr-CA, fr), then from the default locale.
  • Specification: one manifest on its own. Every runtime reads a single manifest (RuleSet.from_manifest, fromManifest, FromManifest), which is how a native front end receives rules. In the engine protocol load accepts a manifest, reports channels and missingOperators, and a channel the ruleset lacks is CHANNEL_UNAVAILABLE.
  • Runtimes: start-up check for custom operators. Each runtime reports the custom operators a ruleset needs that the host has not registered.
  • TypeScript: the manifest client keeps working through an outage of the manifest endpoint by returning the cached manifest and reporting that it is stale.
  • Catalog: a server rule protects the credit limit. The read-only state guides the UI; the new validation rule is what stops the change.
  • Specification: targets. A rule may target a page, screen and section in addition to a component and fields, or a semantic data type. Types are declared under types and bound to fields in entities.<Name>.fieldTypes; a rule on a type runs once per bound field with value and field in scope. A request may carry a view that narrows the evaluation to one place.
  • Specification: functions and custom operators. functions declares reusable expressions, called with {fn, args}, with lexical scope and no recursion. operators declares x-* operators that the host supplies; an operator that is missing or fails makes the rule fail closed.
  • Specification: operators. Fifteen core operators: between, mod, abs, min, max, round, upper, trim, concat, substring, text, map, filter, typeOf and yearsBetween. The core profile now has 45.
  • Specification: bundles. A bundle holds the server and the client manifest of a compiled ruleset (section 7). Manifests gained fieldTypes, functions and operators. There are two conformance levels: evaluator and compiler (section 11).
  • Specification: engine protocol. JSON Lines on standard input and output with the commands version, load, manifest, evaluate, expression and compile (section 13).
  • Specification: authoring in YAML (section 12) and the load codes TYPE_UNKNOWN, SCOPE_INVALID, FUNCTION_UNKNOWN, FUNCTION_ARITY, FUNCTION_RECURSIVE, FUNCTION_REDEFINED, OPERATOR_UNDECLARED, FIELD_TYPE_REBOUND, BUNDLE_UNSUPPORTED and BUNDLE_INVALID. The recommended scope levels gained project and module.
  • Evaluation API. GET /rulesets/{rulesetId}/bundle; view in the request and location in a finding; the Bundle and View schemas. The API description is version 1.1.0.
  • Conformance. 499 expression cases (were 147), 191 load-error cases (84), five fixtures with 66 golden tests (two with 17), a 1000-case evaluation corpus (300), the five published bundles, and 88 engine-protocol cases. Two rulesets exist only for the suite: conflicts, ordering and failing closed. Three conformance operators (x-test-reverse, x-test-sum, x-luhn) test the custom-operator mechanism.
  • Python. packages/python, the rule_cascade package: the reference implementation as an installable library, with load, RuleSet.from_bundle, evaluate, evaluate_expression and the engine protocol (python -m rule_cascade engine).
  • TypeScript. Bundles (RuleSet.fromBundle, bundle()), custom operators, view and finding.location, requestProblem and RequestError, missingOperators, patternProblem, jsonFinite, the Engine class and the rule-cascade-node engine command.
  • Java. Bundles (RuleSet.fromBundle, bundle()), CustomOperator, withOperators and requiredOperators, View, and the engine protocol (Engine, Main engine). The schema validator interprets the embedded schema file instead of mirroring it.
  • Go. A new runtime, package rulecascade, at both conformance levels, with no dependencies outside the standard library.
  • Command. rule-cascade, built from the Go runtime: version, check, compile, manifest, evaluate and engine. packages/go/scripts/build-all.sh builds static binaries for Linux, macOS and Windows on amd64 and arm64, with checksums.
  • WebAssembly. The same command as a WASI preview 1 module, rule-cascade.wasm, and packages/go/wasi/run.mjs to run it under Node.js.
  • Rule server. Serves bundles (GET /rulesets/{id}/bundle, behind the token) and loads precompiled *.bundle.json files next to source rulesets. createRuleServer takes custom operators and reports the missing ones; the command logs them at start-up and after a reload.
  • Tools. rulecheck compile writes a bundle. rulecheck conformance --engine "<command>" certifies any engine over the engine protocol. rulecheck sync [--check] regenerates the schema copies, fixtures, bundles, expectations, the evaluation corpus and the example client manifest. rulecheck check reports YAML_NOT_PORTABLE and NUMBER_NOT_PORTABLE.
  • Tools: JSON Logic. rulecheck jsonlogic import|export converts expressions in both directions and refuses what it cannot convert faithfully (docs/json-logic.md).
  • Tools: OpenAPI. rulecheck derive turns the constraints of an OpenAPI component schema into a baseline ruleset with stable finding codes (docs/openapi.md).
  • Examples. A rule catalog by data type and severity (examples/catalog, 34 rules, 25 golden tests); two derived rulesets with their tests (examples/derived); the same two evaluations from Python, Node.js, Ruby, PHP, Java, shell, Rust, C# and PowerShell over the engine protocol, and in process with the WebAssembly module from Node.js and Python (examples/engine-clients). The Spring Boot example can start from a bundle and registers a custom operator.
  • Bindings. The rule-draft response format lists the 45 core operators, function calls, places and types; the evaluate_rules tool accepts a view. bindings/README.md explains both files.
  • CI. Every runtime is built and certified on Linux, Windows and macOS, in process and over the engine protocol. A job cross-compiles the command, certifies the WebAssembly module, runs the engine clients and uploads the binaries. The tools have unit tests (tools/tests).
  • Documentation. docs/authoring-guidelines.md, ADRs 0005 to 0009, packages/python/README.md.
  • Examples: services, batch and agents. examples/backend-node (node:http) and examples/backend-go (net/http) enforce the payments contract the way the Spring Boot example does: evaluate, refuse with 422 problem details, persist, run commands once per idempotency key, and serve the client manifest with an ETag. examples/batch streams a CSV or JSON Lines file through any engine over the engine protocol, one decision per line. examples/agent-tools runs the tools of bindings/llm-tools.json against the rule server, with the actor taken from the session; its README maps the same tools onto MCP.
  • Tests. The React hook and the manifest client of the TypeScript runtime have their own tests. The container smoke test (packages/server/test/smoke-image.sh) also checks that the image fails closed without a token, that a broken reload is refused while the previous rules keep serving, and that SIGTERM drains.
  • Cross-runtime version check. tools/check_versions.py (run by make contract and the CI contract job) fails unless every runtime declares the same version: the TypeScript and server package.json, the Java pom.xml, Go's version.go, and Python's pyproject.toml and __init__.py (PEP 440 1.0.0a2 is read as 1.0.0-alpha.2).
  • CI. One job per new example on Linux, and a job that runs the Go runtime and the Go example on Go 1.22, the minimum go.mod declares, with GOTOOLCHAIN=local so no newer toolchain is used.
  • Rule server: scheduled refresh. RULES_REFRESH=interval (RULES_REFRESH_INTERVAL, at least 1s) or cron (RULES_REFRESH_CRON, RULES_REFRESH_TZ, default UTC) checks the rules directory on a schedule and reloads, with the safety of SIGHUP, only when a file changed. The default, manual, is the previous behaviour. Content that was refused is not retried until it changes.
  • Rule server: cache policy. An optional cache-policy.yaml in the rules directory sets the Cache-Control of client manifests per ruleset: revalidate (default, unchanged), ttl (with stale-while-revalidate and stale-if-error) or permanent. A bad policy file is refused like a bad ruleset. ?checksum= on the manifest URL answers immutable in permanent mode, and 409 with no-store when it is not the checksum being served (a server extension, not in the OpenAPI description). Server manifests and bundles stay private, no-cache.
  • Rule server: worker threads. RULE_SERVER_WORKERS (default 0) evaluates on worker threads with identical results; an evaluation running longer than RULE_EVALUATION_TIMEOUT_MS (default 5000) is answered 503 and its worker replaced. Embedded: workers, evaluationTimeoutMs, operatorsModule and terminateWorkers().
  • TypeScript: manifest caching modes. createManifestClient takes mode (revalidate, ttl, permanent), ttlMs, staleIfError, refreshCron, storage (with localStorageAdapter) and onUpdate; get takes an optional checksum; concurrent requests for one ruleset are shared; refresh() and close(). The default behaviour is unchanged.
  • Refreshing holders. RuleSetHolder (Java, Python) and Holder (Go) reload rules on an interval or a cron schedule, swap them atomically, keep the last good rules on failure and report each refresh to a listener.
  • Cron. One five-field cron syntax in TypeScript (@rules-cascade/common/cron), Java (CronSchedule), Go (ParseCron) and Python (rule_cascade.cron), all tested against tools/cron-cases.json.
  • Benchmarks. make bench measures every runtime on the same bundle and requests (tools/bench-requests.json) and load-tests the rule server with and without workers. docs/performance.md records measured numbers; docs/caching.md describes the caching modes.

Changed

  • Specification. Canonical numbers are exact. abs keeps 34 digits. Members of a protocol request are checked before a ruleset is looked up; optional members may be null.
  • TypeScript, Java. Both runtimes implement the evaluator and the compiler level and are at version 1.0.0-alpha.2.
  • Rule server. POST /evaluations checks the body with the shape check every runtime applies and names the problem in its 400 answer. A ruleset that came from a bundle is listed with its id, version and checksum only. If-None-Match is compared as RFC 9110 says: a list of entity tags, weak or strong, or *. A path with malformed percent-encoding is 400, not 500. A body over the limit is 413 without being read to the end.
  • Tools. tools/lint_specs.py also checks that every pattern in the schema is portable, that the operator list in bindings/ matches the schema, and that all generated files are current.
  • Makefile. make verify also runs the Python package tests, the Go runtime, the release build, every engine over the protocol and the engine clients.
  • Documentation. docs/architecture.md, docs/naming-conventions.md, ADRs 0001 to 0003, CONTRIBUTING.md, SECURITY.md and the deployment notes describe the current design. The README has a table of supported versions (declared minimum, tested in CI, highest observed; no declared maximum) and says what is not verified: the Kubernetes manifests have never been applied, the WebAssembly module has not run in a browser, and the x-rule-cascade binding is checked at lint time only. The claim that the runtimes agree beyond the suite now says which part can be repeated from the repository.

[1.0.0-alpha.1]

Added

  • Specification 1.0 (draft): ruleset schema, normative semantics, evaluation API.
  • Conformance suite: expression cases, load-error cases, fixture checksums and client manifests, golden tests, and a 300-case evaluation corpus.
  • Reference implementation and linter in Python (tools/rulecheck.py).
  • TypeScript runtime for browsers and Node.js, with a React hook and a manifest client.
  • Java runtime with no dependencies.
  • Rule server: stateless HTTP service with health probes, graceful shutdown and safe reload.
  • Examples: organisation and feature rulesets, an OpenAPI binding, a React form, a Spring Boot API.
  • Deployment: Dockerfile and Kubernetes manifests for the rule server.
  • Bindings for OpenAI function tools and structured rule drafting.

On this page