Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion astrbot/core/astr_agent_hooks.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,10 @@ async def on_tool_end(
)

# special handle web_search_tavily
platform_name = run_context.context.event.get_platform_name()
if (
tool.name == "web_search_tavily"
platform_name == "webchat"
and tool.name == "web_search_tavily"
and len(run_context.messages) > 0
and tool_result
and len(tool_result.content)
Expand Down
1 change: 1 addition & 0 deletions astrbot/core/pipeline/process_stage/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
"You MUST NOT return an empty response, especially after invoking a tool."
"Before calling any tool, provide a brief explanatory message to the user stating the purpose of the tool call."
"After the tool call is completed, you must briefly summarize the results returned by the tool for the user."
"Keep the role-play and style consistent throughout the conversation."
)

CHATUI_SPECIAL_DEFAULT_PERSONA_PROMPT = (
Expand Down