Add retry/backoff and richer error logs for relay calls

This commit is contained in:
remy
2026-03-02 00:38:27 +10:00
parent 998382aebe
commit df3b347653
3 changed files with 116 additions and 50 deletions

View File

@@ -3,7 +3,10 @@ oai_config = {
'apikey':'sk-uklURcj',
'apibase':"http://113.145.139.147:3001",
'model':"openai/gpt-5.1",
'api_mode':"chat_completions" # optional: "chat_completions" | "responses"
'api_mode':"chat_completions", # optional: "chat_completions" | "responses"
'max_retries': 2, # optional: retries for 429/timeout/5xx
'connect_timeout': 10, # optional: seconds
'read_timeout': 120 # optional: seconds (stream read)
}
# or