1 minute readImprovedAgent-ready
Routing picks the same way every time, and policies are checked
Automatic routing skips experiment assigners, breaks ties the same way on every call, and a routing policy that names a function it could never use is refused when you save it.
- Only functions that price: routing leaves out experiment assigners such as
lastprice/elo-ab-test, so an automatic call no longer lands on one. - The same answer for the same request: ties are broken by name.
- Weighted routing says what it needs: with no saved weights it answers 400
weighted_policy_required, and when no weighted function can serve, 400no_weighted_function_available, instead of picking another function. - Policies checked when saved: a weight, rule or fallback naming a function that does not exist, that your workspace cannot reach, or that does not compute a price is refused with 400 naming the field.
- The trace names the policy: the route step and
routing.policysay which policy decided.