Rule types
Use budget hard stops to cap customer usage.
Pre-call and post-call
Pre-call controls can block or steer a call before provider spend happens. Post-call controls alert after usage is recorded.Draft before active
Rules should be reviewed before they affect production traffic. Pylva supports draft rules so teams can preview impact before activation.Conflict resolution
When more than one rule matches a call, the most specific rule wins:- Customer-specific rules beat pooled rules.
- Step-specific rules beat general rules.
- If specificity is tied, the most recently updated rule wins.
Fail-open principle
Pylva fails open when rule state, pricing, or backend access is unavailable, so Pylva does not become the reason your agent is down. The exception is an active hard-stop rule that the SDK has already cached and can enforce safely.Operational advice
- Start with alert-only rules.
- Add budget hard stops to customer plans that need hard cost ceilings.
- Use model routing on narrow steps before broad rollouts.
- Keep failover rules explicit and tested before activating them.