Merge pull request #2691 from Weikjssss/fix-bot-type-conf

fix: pass bot_type in agent mode
This commit is contained in:
zhayujie
2026-03-10 15:00:04 +08:00
committed by GitHub

View File

@@ -97,6 +97,9 @@ class AgentLLMModel(LLMModel):
def _resolve_bot_type(self, model_name: str) -> str:
"""Resolve bot type from model name, matching Bridge.__init__ logic."""
from config import conf
configured_bot_type = conf().get("bot_type")
if configured_bot_type:
return configured_bot_type
if conf().get("use_linkai", False) and conf().get("linkai_api_key"):
return const.LINKAI
if not model_name or not isinstance(model_name, str):