diff --git a/astrbot/builtin_stars/astrbot/process_llm_request.py b/astrbot/builtin_stars/astrbot/process_llm_request.py index 547b12410..36d7a67ae 100644 --- a/astrbot/builtin_stars/astrbot/process_llm_request.py +++ b/astrbot/builtin_stars/astrbot/process_llm_request.py @@ -82,7 +82,8 @@ class ProcessLLMRequest: # Encourage the model to delegate to subagents. # Use the built-in default router prompt; user overrides are disabled for now. router_prompt = ( - self.ctx.get_config().get("provider_settings", {}) + self.ctx.get_config() + .get("provider_settings", {}) .get("subagent_orchestrator", {}) .get("router_system_prompt", "") ).strip() diff --git a/astrbot/core/astr_agent_tool_exec.py b/astrbot/core/astr_agent_tool_exec.py index 83c3512c2..e940bd05b 100644 --- a/astrbot/core/astr_agent_tool_exec.py +++ b/astrbot/core/astr_agent_tool_exec.py @@ -77,7 +77,9 @@ class FunctionToolExecutor(BaseFunctionToolExecutor[AstrAgentContext]): # Use per-subagent provider override if configured; otherwise fall back # to the current/default provider resolution. - prov_id = getattr(tool, "provider_id", None) or await ctx.get_current_chat_provider_id(umo) + prov_id = getattr( + tool, "provider_id", None + ) or await ctx.get_current_chat_provider_id(umo) llm_resp = await ctx.tool_loop_agent( event=event, chat_provider_id=prov_id, diff --git a/astrbot/core/config/default.py b/astrbot/core/config/default.py index e14187a1c..1b9daa3e0 100644 --- a/astrbot/core/config/default.py +++ b/astrbot/core/config/default.py @@ -121,7 +121,6 @@ DEFAULT_CONFIG = { "shipyard_ttl": 3600, "shipyard_max_sessions": 10, }, - # SubAgent orchestrator mode: the main LLM only delegates tasks to subagents # (via transfer_to_{agent} tools). Domain tools are mounted on subagents. "subagent_orchestrator": { diff --git a/astrbot/dashboard/routes/subagent.py b/astrbot/dashboard/routes/subagent.py index 34b31c9e8..6eb833f9e 100644 --- a/astrbot/dashboard/routes/subagent.py +++ b/astrbot/dashboard/routes/subagent.py @@ -41,7 +41,11 @@ class SubAgentRoute(Route): } # Backward compatibility: older config used `enable`. - if isinstance(data, dict) and "main_enable" not in data and "enable" in data: + if ( + isinstance(data, dict) + and "main_enable" not in data + and "enable" in data + ): data["main_enable"] = bool(data.get("enable", False)) # Ensure required keys exist.