mirror of
https://gitee.com/zhangsken/opencode.git
synced 2026-11-14 07:42:03 +08:00
docs(ai): describe quota codes provider-neutrally
This commit is contained in:
@@ -59,8 +59,7 @@ export const isContextOverflowFailure = (failure: unknown) =>
|
||||
: Schema.is(ProviderErrorEvent)(failure) && failure.classification === "context-overflow"
|
||||
|
||||
const decodeJson = Schema.decodeUnknownOption(Schema.fromJsonString(Schema.Unknown))
|
||||
// OpenCode Zen reports account caps as typed 429/402 errors that are not throttles, and
|
||||
// OpenAI reports hard spend limits as 429s with a spend-limit code.
|
||||
// Account caps that providers and gateways report as typed 429/402 errors, not throttles.
|
||||
const QUOTA_CODES = new Set([
|
||||
"insufficient_quota",
|
||||
"usage_not_included",
|
||||
|
||||
Reference in New Issue
Block a user