class LittleGhost::Invocation

Carry one application request into an agent run. An invocation keeps framework fields and application-specific context in one indifferent-key environment.

invocation = LittleGhost::Invocation.new(
  message: "Why is transfer 481 pending?",
  account_id: "account-1",
  metadata: {channel: "customer_support"}
)

invocation.message.text  # => "Why is transfer 481 pending?"
invocation[:account_id]  # => "account-1"
invocation.account_id    # => "account-1"

String and symbol keys address the same field. Known fields have named accessors, while unknown application fields remain available through hash access and dynamic readers or writers. message and every history entry are normalized to Message objects; deadline_at lazily parses ISO 8601 text.

Missing run, invocation, and session identifiers are generated when the object is built. Actor identity is never inferred: applications that use it for persistence or tenant isolation must pass a value established by their trusted authentication boundary. Invalid payloads, messages, keys, or deadlines raise InvocationError.