fix: update MiniMax/Z.AI model lists, pass base_url to AIAgent
- Update _PROVIDER_MODELS['minimax'] from stale ABAB 6.5 models to current MiniMax-M2.7/M2.5/M2.1 lineup (matching hermes-agent upstream) - Update _PROVIDER_MODELS['zai'] from GLM-4 to current GLM-5/4.7/4.5 lineup (matching hermes-agent upstream) - Extend resolve_model_provider() to also return base_url from config.yaml, so providers with custom endpoints (MiniMax, Z.AI) are routed correctly - Pass base_url to AIAgent in both streaming and sync chat paths Fixes #6 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -100,10 +100,11 @@ def _run_agent_streaming(session_id, msg_text, model, workspace, stream_id, atta
|
||||
|
||||
if AIAgent is None:
|
||||
raise ImportError("AIAgent not available -- check that hermes-agent is on sys.path")
|
||||
resolved_model, resolved_provider = resolve_model_provider(model)
|
||||
resolved_model, resolved_provider, resolved_base_url = resolve_model_provider(model)
|
||||
agent = AIAgent(
|
||||
model=resolved_model,
|
||||
provider=resolved_provider,
|
||||
base_url=resolved_base_url,
|
||||
platform='cli',
|
||||
quiet_mode=True,
|
||||
enabled_toolsets=CLI_TOOLSETS,
|
||||
|
||||
Reference in New Issue
Block a user