Interface SLOScope

All Known Implementing Classes:
SLOScope.ForAgent, SLOScope.ForCapability, SLOScope.ForTenant, SLOScope.Global

What an SLODefinition measures (issue #92): the framework as a whole, a single tenant, a specific agent inside a tenant, or every implementation of a Capability interface.

Scope determines which events the SLOEvaluator counts when computing compliance — a ForTenant("acme") SLO ignores events from tenant beta.

Since:
0.5.0 (issue #92)
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static final record 
    Single-agent-within-tenant scope.
    static final record 
    Every implementation of a capability interface — useful for cross-tenant SLOs like "all chat agents must hit p95 invalid input: '<' 3s".
    static final record 
    Single-tenant scope.
    static final record 
    Whole-framework scope — every event counts.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Returns true if attempt (an event-level scope description) falls within this SLO's scope.
  • Method Details

    • matches

      boolean matches(EventScope attempt)
      Returns true if attempt (an event-level scope description) falls within this SLO's scope. Used by the evaluator to decide which counted attempts contribute to this SLO.