jack 3 ay önce
ebeveyn
işleme
9be94b87f5

+ 5 - 4
app/core/runner/thread_runner.py

@@ -215,9 +215,10 @@ class ThreadRunner:
             self.event_handler.pub_run_step_created(new_run_step)
             self.event_handler.pub_run_step_in_progress(new_run_step)
 
-            # internal_tool_calls = list(
-            #    filter(lambda _tool_calls: _tool_calls[0] is not None, tool_calls)
-            # )
+            internal_tool_calls = list(
+                filter(lambda _tool_calls: _tool_calls[0] is not None, tool_calls)
+            )
+            """
             seen = set()
             internal_tool_calls = []
             for _tool_call in tool_calls:
@@ -225,7 +226,7 @@ class ThreadRunner:
                 if tool_obj is not None and tool_obj not in seen:
                     seen.add(tool_obj)
                     internal_tool_calls.append(_tool_call)
-
+            """
             external_tool_call_dict = [
                 tool_call_dict for tool, tool_call_dict in tool_calls if tool is None
             ]

+ 1 - 1
app/core/tools/file_search_tool.py

@@ -145,7 +145,7 @@ class FileSearchTool(BaseTool):
         if (self.__keys and len(self.__keys) > 0) or (
             self.__dirkeys and len(self.__dirkeys) > 0
         ):
-            return "## Top Important: Please use the 'file_search' tool to search for relevant content or keywords. Summarize the content or keywords and provide them for 'file_search' tool usage. Please ensure that the 'file_search' tool is used only once per request."
+            return ""  # "## Top Important: Please use the 'file_search' tool to search for relevant content or keywords. Summarize the content or keywords and provide them for 'file_search' tool usage. Please ensure that the 'file_search' tool is used only once per request."
         else:
             return ""