PhoenixKitAI.GuardEvent (PhoenixKitAI v0.26.1)

Copy Markdown View Source

Something the AI task guard noticed (phoenix_kit_ai_guard_events, this module's migration chain), written by PhoenixKitAI.GuardEvents.

kind is one of kinds/0. dedupe_key, when set, is unique: an event that should be signalled once per window carries a key naming that window, and only the insert that went through signals. ref holds what the kind needs (the scope, unit and period of a limit). reason is never sent in a notification.

Summary

Functions

Every kind the table takes (its CHECK constraint).

Types

t()

@type t() :: %PhoenixKitAI.GuardEvent{
  __meta__: term(),
  actor_uuid: term(),
  dedupe_key: term(),
  endpoint_uuid: term(),
  inserted_at: term(),
  kind: term(),
  reason: term(),
  ref: term(),
  request_uuid: term(),
  task_key: term(),
  user_uuid: term(),
  uuid: term()
}

Functions

kinds()

@spec kinds() :: [String.t()]

Every kind the table takes (its CHECK constraint).