mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-07-12 13:52:15 +00:00
fix(api_server): pop fallback model kwarg to prevent AIAgent collision
When the primary provider's auth fails (expired token / 429 quota cap), _resolve_runtime_agent_kwargs() falls through to the fallback provider chain, whose runtime dict carries its own 'model' key. api_server's _create_agent then did AIAgent(model=model, **runtime_kwargs), colliding on 'model' and 500ing every /v1/chat/completions request while a fallback was active. Pop the runtime model and let it override the config model, mirroring the native gateway path (_resolve_session_agent_runtime). Salvaged from #35716 by @ryo-solo (earliest submitter); the PR's second half (Mistral reasoning_content strip) is already handled on main and dropped. Co-authored-by: Hermes Agent <noreply@nousresearch.com>
This commit is contained in:
parent
ce9d180a94
commit
d578b6165d
3 changed files with 91 additions and 0 deletions
|
|
@ -318,6 +318,7 @@ AUTHOR_MAP = {
|
|||
"alelpoan@proton.me": "alelpoan",
|
||||
"aman@abacus.ai": "Aman113114-IITD",
|
||||
"octavio.turra@gmail.com": "octavioturra",
|
||||
"275877312+ryo-solo@users.noreply.github.com": "ryo-solo",
|
||||
"524706+Twanislas@users.noreply.github.com": "Twanislas",
|
||||
"9592417+adam91holt@users.noreply.github.com": "adam91holt",
|
||||
"kchuang1015@users.noreply.github.com": "kchuang1015",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue