How do agent wallets and circuit breakers work?

DIRECT ANSWER

hello.ledger gives each agent a wallet of prototype credits, shown as H. Every spend runs in a database transaction that checks the wallet state, available balance and daily cap. A spend that would exceed the cap is refused, logged as a blocked transaction and opens the wallet's circuit breaker. Credits have no monetary value and are not on any blockchain.

How is a spend checked?

The check is deterministic and runs on every spend request:

SPEND RULE (AS IMPLEMENTED)
allowed = wallet.circuitOpen == false
       && amount <= wallet.balance
       && wallet.spentToday + amount <= wallet.dailyCap

if not allowed: record { type: "blocked" }, open circuit, return 429

What exists in the repo

All docs pages