Skip to content

Release v7.186.0

Choose a tag to compare

@github-actions github-actions released this 24 Nov 06:49
3859f4e

Agent session usage now carries a snapshot of the provider's allowance at the moment the usage was recorded, so usage and remaining capacity can be read together without a second query.

Added

  • RecordAgentSessionUsageWithCapacity command (/api/a-i/usage/recording) that records session usage and, on the same session stream, an AgentSessionCapacityObserved event with the provider's allowance windows, freshness state and reason as captured by the server (#375)
  • Provider allowance snapshot types (AIProviderCapacitySnapshot, allowance windows and states), captured from the cached capacity observations without blocking or calling the provider
  • TypeScript proxy for the new command, exported from @cratis/ai
  • Documentation on provider capacity boundaries and how to read usage together with its allowance snapshot: https://github.com/Cratis/AI/blob/main/Documentation/provider-capacity-boundaries.md

Changed

  • Managed language models and pooled chat clients now record usage through the new command; the UsageRecorded event and the existing RecordAgentSessionUsage command and route are unchanged, and a failed allowance capture never prevents usage from being recorded