style(agent): satisfy golines in retry classification
This commit is contained in:
parent
c10a34604f
commit
f026151ffb
1 changed files with 11 additions and 9 deletions
|
|
@ -1152,7 +1152,9 @@ func (al *AgentLoop) runLLMIteration(
|
|||
isTransientProviderError := classifiedErr != nil && classifiedErr.Reason == providers.FailoverTimeout
|
||||
|
||||
// Detect real context window / token limit errors, excluding network timeouts.
|
||||
isContextError := !isTimeoutError && !isTransientProviderError && (strings.Contains(errMsg, "context_length_exceeded") ||
|
||||
isContextError := !isTimeoutError &&
|
||||
!isTransientProviderError &&
|
||||
(strings.Contains(errMsg, "context_length_exceeded") ||
|
||||
strings.Contains(errMsg, "context window") ||
|
||||
strings.Contains(errMsg, "maximum context length") ||
|
||||
strings.Contains(errMsg, "token limit") ||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue