Package com.axelor.ai.chat.provider
Class FlexFallback
java.lang.Object
com.axelor.ai.chat.provider.FlexFallback
Sends a request at OpenAI's Flex tier and, when Flex refuses it, once more at Standard.
Only a blocking background call uses it — session notes, on a thread of its own. Flex answers 429 when it lacks capacity, and refuses outright for models or regions it does not serve. Every refusal is retried rather than only the 429: a request that fails for its own reasons fails again at Standard at no cost, while one Flex could not take then goes through.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordA blocking model, for the background tasks that call the utility model. -
Field Summary
Fields -
Method Summary
-
Field Details
-
FLEX_TIMEOUT
OpenAI's advice for Flex, which queues: raise the timeout from the usual minute or so. -
FLEX
- See Also:
-