Interface ModelCallGuardrail

All Superinterfaces:
Guardrail
All Known Implementing Classes:
ModelCallSimilarityGuard

public non-sealed interface ModelCallGuardrail extends Guardrail
A guardrail that decides whether a model call may proceed. The runtime evaluates it before every model invocation, with the conversation entering the call.

An implementation has a public constructor, optionally taking a GuardrailContext parameter, which gives access to the guardrail's configured name and config section. The per-call data is delivered to decide(akka.javasdk.agent.ModelCallGuardrail.CallContext) via ModelCallGuardrail.CallContext.

The runtime shares one instance across concurrent calls from different sessions and agents. An implementation must be thread safe.