refactor(core): Centralize tool names to avoid circular dependencies - Edit, Grep, Read (#11434)

This commit is contained in:
Abhi
2025-10-19 19:21:47 -04:00
committed by GitHub
parent 98eef9ba0c
commit 23e52f0ff3
14 changed files with 76 additions and 73 deletions

View File

@@ -11,11 +11,10 @@ import {
ApprovalMode,
// Read-only tools
GlobTool,
GrepTool,
LSTool,
ReadFileTool,
ReadManyFilesTool,
RipGrepTool,
GREP_TOOL_NAME,
READ_MANY_FILES_TOOL_NAME,
READ_FILE_TOOL_NAME,
// Write tools
EditTool,
MemoryTool,
@@ -30,11 +29,10 @@ import type { Settings } from './settings.js';
// files or system state.
const READ_ONLY_TOOLS = new Set([
GlobTool.Name,
GrepTool.Name,
RipGrepTool.Name,
GREP_TOOL_NAME,
LSTool.Name,
ReadFileTool.Name,
ReadManyFilesTool.Name,
READ_FILE_TOOL_NAME,
READ_MANY_FILES_TOOL_NAME,
WebSearchTool.Name,
]);