Automatically retry the agent's LLM completion requests when the provider returns 429 Too Many Requests. Uses the Retry-After header to determine the retry delay if it is available. Many providers are frequently overloaded or have low rate limits. These providers are essentially unusable without automatic retries. Tested with Cerebras configured via openai_compatible. Related: #31531 Release Notes: - Added automatic retries for OpenAI-compatible LLM providers --------- Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
29 lines
525 B
TOML
29 lines
525 B
TOML
[package]
|
|
name = "open_ai"
|
|
version = "0.1.0"
|
|
edition.workspace = true
|
|
publish.workspace = true
|
|
license = "GPL-3.0-or-later"
|
|
|
|
[lints]
|
|
workspace = true
|
|
|
|
[lib]
|
|
path = "src/open_ai.rs"
|
|
|
|
[features]
|
|
default = []
|
|
schemars = ["dep:schemars"]
|
|
|
|
[dependencies]
|
|
anyhow.workspace = true
|
|
futures.workspace = true
|
|
http_client.workspace = true
|
|
schemars = { workspace = true, optional = true }
|
|
log.workspace = true
|
|
serde.workspace = true
|
|
serde_json.workspace = true
|
|
settings.workspace = true
|
|
strum.workspace = true
|
|
thiserror.workspace = true
|