Kumoss

How compliance works

How Kumoss decides whether a generate round may be merged and applied: the three checks, which are deterministic, how their results become a lock, and where each audience goes next.

Kumoss lets a change be merged and applied only after it has been checked against your organization’s rules. This page explains the mechanism as a whole: when the checks run, what each one is, how their results become a session lock, and how a lock is cleared. The pages it links to cover each part in detail.

When the checks run

The checks run at the end of every generate round, after the plan has been validated and the report written, and before the plan is pinned for apply. Drift and import rounds are never checked and never lock a session: drift remediation ends at the merge, and an import changes no infrastructure.

Two switches in config.yaml decide which checks run; both default to false in code, and the shipped config.yaml turns both on:

  • orchestration.enable_compliance_checker runs the compliance policy and the intent check.

  • orchestration.block_on_high_impact lets a high-impact verdict lock the session.

The three checks

Check Deterministic What it does Defined in

Compliance policy

Yes

Open Policy Agent evaluates Rego policies against the plan’s JSON: the general policy, and the policy of each provider the root module declares. Fails closed: a policy that cannot be evaluated locks the round too.

Prompts general/policies/compliance and <provider>/policies/compliance

Intent check

No

A language model judges only whether the plan does what every request of the session asks: scope_exceeded (a change nobody asked for) and scope_incomplete (a part of a request left out), both of severity error. It does not judge safety, conventions, deletions, or versions, and a change the user asked for is never a violation.

Prompt general/intent/rules

High impact

No

The report model rates the change low, medium, or high from written criteria.

Prompt general/compliance/impact

Only the policy check is deterministic: it reads attributes of the plan, so the same plan always gets the same verdict. The intent check and the impact rating depend on what the request means and on what a change implies, which only a model can judge, so their verdicts can vary between runs. Rules that can be stated as a condition on the plan therefore belong in the policies. Your conventions (the guideline and resource prompts) only guide generation: no check reviews a plan against them afterwards except what a policy enforces. For what each check looks for, why, and where to adapt it, see Why a session is locked.

From findings to a lock

  1. The core evaluates the policies, then runs the intent check, and merges both into one compliance report for the round; only this merge produces a verdict. Each finding carries its source (opa for the policies, intent for the intent check), a rule id, a severity, and, when it concerns one, the resource.

  2. The report fails when either source has a finding of severity error or critical. Findings of severity warning are reported only.

  3. The core sets the session’s lock from that round alone: locked when the report failed, or when the impact is high and block_on_high_impact is on; unlocked otherwise. A later clean round therefore clears an earlier lock.

  4. When the report failed, or a high impact locked the session, the notifications sidecar, if enabled, alerts the session owner and every user with the panel role editor or higher.

The compliance report is stored as the round’s Compliance Check artifact, and the lock as the session’s is_blocked flag in core-db; see Data and state.

What a lock does

While a session is locked, its owner can still read everything, continue the conversation, and create the pull request, but merging the pull request and applying the plan are refused with 409. The web application shows the Deployment Blocked screen with the findings that caused the lock, each badged policy or intent by its source.

A lock is cleared in one of two ways:

  • The owner sends a follow-up request whose round passes every check.

  • A reviewer with the panel role editor or admin unlocks the session from the admin panel. That unlock lasts until the owner’s next generate round, which sets the lock again from its own results.

Where to go next

If you are Read

A user whose session is locked

Resolve a locked session

A reviewer deciding whether to unlock

Lock or unlock the apply of a session

Adapting the rules to your organization

Compliance prompts and Write a policy rule

Looking for the exact policy contract

Compliance policy