WorkLensDocs
    Studio
    concept

    How validation works

    Two layers of checking: the recipe before a run, and the data after it — what each layer looks at and what neither can see.

    Last updated 2026-09-14 · Markdown

    Summary

    Validation happens twice: the recipe before a run, and the data after it.

    Recipebefore the run
    Structure · rules · dry runvalidate_recipe
    Dataafter the run
    Checks with countsin the receipt

    What is checked

    WorkLens checks
    • Recipe structure, and the closest supported key when one is misspelt.
    • Static satisfiability — a constraint that no row could meet is reported before any row is written.
    • A one-row in-memory dry run in the engine.
    • A ledger of requirements the recipe declares that the engine will not execute, so nothing is dropped silently.
    • After the run: formulas, identifier checksums, ranges, allowed values, uniqueness — with counts.
    WorkLens does not check
    • The meaning of your rules. A range of 0–1 on an age column validates; it is simply wrong.
    • Your application’s behaviour on the data.

    Why the ledger matters

    The recipe is an open superset: it may declare any requirement, including ones the engine does not implement, so that a requirement is never lost between the business and the test. The price is that the engine must say which it executed. That list — declared but not executed — is in the validation result and in the receipt, and an agent is told to read it before drafting further.

    Common questions

    Where do I run the recipe check?

    The validate_recipe MCP tool is the fullest form and returns a next_step to follow verbatim. The studio checks a recipe as you edit it. The CLI’s check command proves a recipe is data-free before it is shared.