summaryrefslogtreecommitdiff
path: root/internal/executor/ratelimit.go
diff options
context:
space:
mode:
authorPeter Stone <thepeterstone@gmail.com>2026-03-09 05:50:59 +0000
committerPeter Stone <thepeterstone@gmail.com>2026-03-09 05:50:59 +0000
commit8ec366de42dd66256895f16c9669469791ca823a (patch)
tree1650beda8dd017e476148a0177e96e3ab79832a8 /internal/executor/ratelimit.go
parent5c8562460fc5b78372a1cfdb400e0cb1f51875cd (diff)
executor: strengthen rate-limit avoidance in classifier
Updated isQuotaExhausted to detect more Claude quota messages. Added 'rate limit reached (rejected)' to quota exhausted checks. Strengthened classifier prompt to explicitly forbid selecting rate-limited agents. Improved Pool to set 5h rate limit on quota exhaustion.
Diffstat (limited to 'internal/executor/ratelimit.go')
-rw-r--r--internal/executor/ratelimit.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/internal/executor/ratelimit.go b/internal/executor/ratelimit.go
index deaad18..aa9df99 100644
--- a/internal/executor/ratelimit.go
+++ b/internal/executor/ratelimit.go
@@ -34,7 +34,9 @@ func isQuotaExhausted(err error) bool {
}
msg := strings.ToLower(err.Error())
return strings.Contains(msg, "hit your limit") ||
- strings.Contains(msg, "you've hit your limit")
+ strings.Contains(msg, "you've hit your limit") ||
+ strings.Contains(msg, "you have hit your limit") ||
+ strings.Contains(msg, "rate limit reached (rejected)")
}
// parseRetryAfter extracts a Retry-After duration from an error message.