Skip to main content

Module token_usage

Module token_usage 

Source
Expand description

agents logs token-usage — per-AIH token-usage snapshot subtree. Leaves:

  • get — read the current stored total_tokens (no waiting).
  • subscribe — wait for the stored total_tokens to change (or the instance lock to drop).

Modules§

get
agents logs token-usage get — read an agent’s current stored total_tokens snapshot (no waiting). total_tokens is null when no agent-completion usage has been recorded for the AIH yet.
subscribe
agents logs token-usage subscribe — wait for an agent’s stored total_tokens snapshot to change, OR for its instance lock to drop. One-shot: yields exactly one result — a token-usage value (Item) or the literal string "agents_inactive" — then ends.

Enums§

Command
Request
ResponseItem

Functions§

execute
execute_transform