adk_safety_settings (erlang_adk v0.7.0)

View Source

Provider-neutral safety-setting contract used by agent specifications.

Providers encode the canonical categories and thresholds for their own wire protocol. Values are normalized without creating atoms at runtime.

Summary

Types

category/0

-type category() :: harassment | hate_speech | sexually_explicit | dangerous_content.

setting/0

-type setting() :: #{category := category(), threshold := threshold()}.

threshold/0

-type threshold() ::
          off | block_none | block_only_high | block_medium_and_above | block_low_and_above |
          unspecified.

Functions

normalize(Settings)

-spec normalize(term()) -> {ok, [setting()]} | {error, term()}.