fix(agents): honor explicit rate-limit cooldown probes in fallback runs

This commit is contained in:
Vignesh Natarajan
2026-03-05 20:02:36 -08:00
parent ce71fac7d6
commit d45353f95b
14 changed files with 150 additions and 25 deletions

View File

@@ -1,7 +1,11 @@
export async function runWithModelFallback(params: {
provider: string;
model: string;
run: (provider: string, model: string) => Promise<unknown>;
run: (
provider: string,
model: string,
options?: { allowRateLimitCooldownProbe?: boolean },
) => Promise<unknown>;
}) {
return {
result: await params.run(params.provider, params.model),