Catalog/P family/P22
Proposed specificationSource-located exemplarH2

Policy floor

Preserve minimum restrictions across customization.

JOIN POINTpolicy_compositionRECORD STATUSCandidate · v0.1.0
UML class view for Policy floor, showing participant roles, received calls, and analytical dependencies
FIG. P22 / UML CLASS VIEW
Object interaction diagram for Policy floor, showing role collaboration and a numbered message sequence
FIG. P22 / OBJECT INTERACTIONS
Context
Multiple general, project, user, or session policies are merged.
Trigger
A proposed action is authorized under composite policy.
Structure
Minimum floor rules, merge operator, and privileged override path.
Effect
Composition cannot weaken protected restrictions without explicit authority.
Requires
Rule identity and priority or set semantics are defined.
Ensures
The merged result is at least as restrictive as every floor obligation.
Invariant
Local customization cannot silently erase a protected deny rule.
Violation
Conflicts produce deny, escalation, or explicit configured precedence.

Negative control

A single configurable allowlist has no composition floor.

Permitted variation

Intersection, ordered layers, scoped profiles, and administrative overrides.

Test obligation

Test widening, conflicting rules, missing policy, and privileged override.

Evolution question

Did policy composition become monotonic with explicit exceptions?

PROMPT SKETCH
Compose policy layers by intersection, not by last-writer-wins. The merged decision must be at least as restrictive as every floor obligation, and the effective rule must be attributable.
CODE DESIGN / PYTHON
def merge(layers):
    decisions = [layer.evaluate(request) for layer in layers]
    denied = [decision for decision in decisions if decision.denied]
    if denied:
        return Decision.deny(denied, source=denied[0].source)
    return Decision.allow(
        max(decisions, key=lambda decision: decision.restrictiveness)
    )

Illustrative design sketch. A permissive override may add capability, but it must not erase a floor. This example is a teaching aid, not implementation evidence or a conformance claim.

Join point
policy_composition
Source locator
Barbaste et al., §10.7, p. 38 (Hermes, “A Policy Floor That Survives YOLO”); source label
Lexical cue
(?i)\b(?:policy[_-]?floor|minimum[_-]?policy|deny[_-]?rules?|policy[_-]?composition)\bFrozen expression, v0.1.0. A match is a retrieval cue, not a confirmed implementation.
Aliases
policyfloor, minimumpolicy, denyrules, policycomposition
Canonical exemplar
anomalyco/opencodepackages/core/src/permission.ts:20Support: packages/core/test/permission.test.ts:1
Negative control
A single configurable allowlist has no composition floor.

Scope-anchored review. pohe-agent analyze <repo> --pattern P22 anchors the cue to its enclosing declaration and checks a separate operational signature for all four pointcut dimensions. Missing roles and negative-control risks remain visible; a structural match is not E2/E3. Calibration report ↗

Source-located exemplar

A concrete source anchor is available for this proposed record. It is one exemplar, not evidence that all repositories—or every contract field—conform.

Review boundary: this candidate and its specification come from an AI-assisted study. Independent human validation remains open.

ANY-EVIDENCE FAMILY COVERAGE8/36

22.2% of repository families in the frozen panel have at least one current cue, historical cue, or canonical source layer. This is not confirmed prevalence.

Current lexical-cue repositories: 7 / 41
Canonical source anchoranomalyco/opencode 885df74024b6packages/core/src/permission.ts:20

Missing agent permissions resolve to deny-all, then merge with session policy.

Exploratory retrieval cue Regex / v0.1.0
(?i)\b(?:policy[_-]?floor|minimum[_-]?policy|deny[_-]?rules?|policy[_-]?composition)\b

This expression is a discovery instrument only. A match is a retrieval cue—not a confirmed implementation, pointcut match, or contract proof.