Autonomic.Contracts (Autonomic v0.1.0)

Copy Markdown View Source

Normative public contracts for the BEAM Autonomic Agent Runtime.

This file is intentionally self-contained so an implementation agent can use it as the starting contract before splitting modules into their final files.

Summary

Types

domain_ref()

@type domain_ref() :: String.t()

effect_class()

@type effect_class() ::
  :class_0_local_replayable
  | :class_1_isolated_mutable
  | :class_2_external_observable_or_compensatable
  | :class_3_authoritative_external_mutation
  | :class_4_irreversible_high_impact

effect_id()

@type effect_id() :: String.t()

effect_state()

@type effect_state() ::
  :proposed
  | :prepared
  | :evaluating
  | :ready
  | :commit_intent
  | :committing
  | :committed
  | :aborted
  | :expired
  | :stale
  | :commit_unknown
  | :failed

episode_id()

@type episode_id() :: String.t()

epoch()

@type epoch() :: non_neg_integer()

lease_id()

@type lease_id() :: String.t()

policy_version()

@type policy_version() :: non_neg_integer()

semantic_exit()

@type semantic_exit() :: {:semantic_exit, semantic_exit_reason(), evidence :: map()}

semantic_exit_reason()

@type semantic_exit_reason() ::
  :trajectory_violation
  | :confidence_collapse
  | :authority_exhausted
  | :environment_mismatch
  | :irreversible_effect_risk

snapshot_ref()

@type snapshot_ref() :: String.t()

trajectory_regime()

@type trajectory_regime() ::
  :stable | :uncertain | :drifting | :unstable | :containment

trajectory_version()

@type trajectory_version() :: non_neg_integer()