Token Allowance Spring Boot 0.3.1 budgets Spring AI ChatClient tokens
The author built Token Allowance, a Spring Boot starter designed to enforce token and dollar budgets on Spring AI ChatClient calls to prevent runaway agent tool loops. The library uses two advisors to handle admission and metering, relies on atomic Redis scripts for budget reservations, and accounts for provider-specific differences in token reporting and streaming behavior. Open article →