2525from cecli .hooks import HookIntegration
2626from cecli .llm import litellm
2727from cecli .mcp import LocalServer , McpServerManager
28+ from cecli .tools .utils .base_tool import BaseTool
2829from cecli .tools .utils .registry import ToolRegistry
2930from cecli .utils import copy_tool_call , tool_call_to_dict
3031
@@ -52,12 +53,9 @@ def __init__(self, *args, **kwargs):
5253 self .read_tools = {
5354 "command" ,
5455 "commandinteractive" ,
55- "viewfilesatglob" ,
56- "viewfilesmatching" ,
56+ "exploresymbols" ,
5757 "ls" ,
58- "viewfileswithsymbol" ,
5958 "grep" ,
60- "listchanges" ,
6159 "showcontext" ,
6260 "thinking" ,
6361 "updatetodolist" ,
@@ -328,7 +326,7 @@ async def _execute_local_tool_calls(self, tool_calls_list):
328326 {"role" : "tool" , "tool_call_id" : tool_call .id , "content" : result_message }
329327 )
330328
331- if self .auto_lint and used_write_tool and not self . edit_allowed :
329+ if self .auto_lint and used_write_tool :
332330 edited = list (self .files_edited_by_tools )
333331 lint_errors = self .lint_edited (edited , show_output = False )
334332 self .lint_outcome = not lint_errors
@@ -1019,25 +1017,25 @@ def _generate_tool_context(self, repetitive_tools):
10191017
10201018 if not self .model_kwargs :
10211019 self .model_kwargs = {
1022- "temperature" : default_temp + 0.1 ,
1023- "frequency_penalty" : default_fp + 0.2 ,
1020+ "temperature" : default_temp + 2 ** - 5 ,
1021+ "frequency_penalty" : default_fp + 2 ** - 5 ,
10241022 # "presence_penalty": 0.1,
10251023 }
10261024 else :
10271025 temperature = nested .getter (self .model_kwargs , "temperature" , default_temp )
10281026 freq_penalty = nested .getter (self .model_kwargs , "frequency_penalty" , default_fp )
10291027
1030- self .model_kwargs ["temperature" ] = temperature + 0.1
1031- self .model_kwargs ["frequency_penalty" ] = freq_penalty + 0.1
1028+ self .model_kwargs ["temperature" ] = temperature + 2 ** - 5
1029+ self .model_kwargs ["frequency_penalty" ] = freq_penalty + 2 ** - 5
10321030
10331031 if random .random () < 0.2 :
10341032 self .model_kwargs ["temperature" ] = max (
10351033 default_temp ,
1036- temperature - 0.15 ,
1034+ temperature - 2 ** - 4 ,
10371035 )
10381036 self .model_kwargs ["frequency_penalty" ] = max (
10391037 default_fp ,
1040- freq_penalty - 0.15 ,
1038+ freq_penalty - 2 ** - 4 ,
10411039 )
10421040
10431041 self .model_kwargs ["temperature" ] = max (
@@ -1161,7 +1159,7 @@ def _add_file_to_context(self, file_path, explicit=False):
11611159
11621160 Parameters:
11631161 - file_path: Path to the file to add
1164- - explicit: Whether this was an explicit view command (vs. implicit through ViewFilesMatching )
1162+ - explicit: Whether this was an explicit view command (vs. implicit through other tools )
11651163 """
11661164 abs_path = self .abs_root_path (file_path )
11671165 rel_path = self .get_rel_fname (abs_path )
@@ -1206,7 +1204,7 @@ async def check_for_file_mentions(self, content):
12061204
12071205 Override parent's method to disable implicit file mention handling in agent mode.
12081206 Files should only be added via explicit tool commands
1209- (`View`, `ViewFilesAtGlob`, `ViewFilesMatching`, `ViewFilesWithSymbol `).
1207+ (`ContextManager `).
12101208 """
12111209 pass
12121210
@@ -1218,6 +1216,7 @@ async def preproc_user_input(self, inp):
12181216 inp = await super ().preproc_user_input (inp )
12191217 inp = self .wrap_user_input (inp )
12201218
1219+ BaseTool .clear_invocation_cache ()
12211220 self .agent_finished = False
12221221 self .turn_count = 0
12231222 return inp
0 commit comments