Skip to main content
A ControlBook turns a regulation into checks. Each obligation names the regulation it serves, the evaluators that test it, and the pass rate it needs. Sengol never hardcodes a regulation: every gate verdict and every report reads the active ControlBook. One ControlBook is active per install. Activate it in Settings → General or with POST /v1/controlbook (how).

Shape

controlbook.yaml

Top-level fields

Obligation fields

An obligation reports NO_RECORDS_OBSERVED when no record in the period both ran its evaluators and carried its policy_id. Developers set the label with policies=[...] on each input.
human_review_required is accepted in the file but does not route anything to the review queue today.

Gold score

formula_type is one of weighted_average, minimum_threshold or all_must_pass. (custom_expression is reserved and not implemented.) app_weights maps obligation ids to weights. The agent is compliant when the score reaches compliant_threshold (default 0.85). Under weighted_average, a score below minimum_floor (default 0.80) is clamped to 0; under minimum_threshold, every obligation must also clear the floor.

The policy catalog

29 regulations ship. List them with sengol policy list, filter with --region or --industry, and inspect one with sengol regulation show <ID>.

Custom policies

Add internal policies under custom_policies in sengol.yaml. Ids must not collide with built-in ones:
sengol.yaml
Required: display_name and region. Optional: industries, authority, url, version, and report (title, subtitle, plain_language).
The appliance validates an uploaded ControlBook against its own catalog. For it to accept a custom policy, set SENGOL_CONFIG on the API process to a file with the same custom_policies block.