From 05a28b077867f239c8e6c649e66a93eae849386c Mon Sep 17 00:00:00 2001 From: RAJVARDHAN <95933896+vardhans07@users.noreply.github.com> Date: Sat, 19 Sep 2026 01:17:49 +0530 Subject: [PATCH] Refactor agent tool settings initialization revert(factory): restore factory.py to match upstream --- strix/agents/factory.py | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/strix/agents/factory.py b/strix/agents/factory.py index a707914e4..a1f2a33de 100644 --- a/strix/agents/factory.py +++ b/strix/agents/factory.py @@ -671,12 +671,6 @@ def build_strix_agent( instructions_override: Use this verbatim as the system prompt instead of rendering the built-in scan prompt. """ - settings = load_settings() - if settings.llm.api_type == "chat_completions": - chat_completions_tools = True - elif settings.llm.api_type == "responses": - chat_completions_tools = False - if instructions_override is not None: instructions = instructions_override else: @@ -692,7 +686,9 @@ def build_strix_agent( agent_tools = [*_EXTRA_TOOLS, *(extra_tools or [])] if interactive: + # yielding to the user is only meaningful when one is attached agent_tools.append(respond_to_user) + if is_root: tools: list[Tool] = [*_BASE_TOOLS, *agent_tools, finish_scan] else: