mirror of
https://github.com/usestrix/strix.git
synced 2026-11-18 09:42:48 +00:00
Refactor agent tool settings initialization
revert(factory): restore factory.py to match upstream
This commit is contained in:
parent
05ec422bf5
commit
05a28b0778
1 changed files with 2 additions and 6 deletions
|
|
@ -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:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue