()
| 191 | * NOTE: This MUST stay in sync with https://console.statsig.com/4aF3Ewatb6xPVpCwxb5nA3/dynamic_configs/claude_code_global_system_caching, in order to cache the system prompt across users. |
| 192 | */ |
| 193 | export function getAllBaseTools(): Tools { |
| 194 | return [ |
| 195 | AgentTool, |
| 196 | TaskOutputTool, |
| 197 | BashTool, |
| 198 | // Ant-native builds have bfs/ugrep embedded in the bun binary (same ARGV0 |
| 199 | // trick as ripgrep). When available, find/grep in Claude's shell are aliased |
| 200 | // to these fast tools, so the dedicated Glob/Grep tools are unnecessary. |
| 201 | ...(hasEmbeddedSearchTools() ? [] : [GlobTool, GrepTool]), |
| 202 | ExitPlanModeV2Tool, |
| 203 | FileReadTool, |
| 204 | FileEditTool, |
| 205 | FileWriteTool, |
| 206 | NotebookEditTool, |
| 207 | WebFetchTool, |
| 208 | TodoWriteTool, |
| 209 | WebSearchTool, |
| 210 | TaskStopTool, |
| 211 | AskUserQuestionTool, |
| 212 | SkillTool, |
| 213 | EnterPlanModeTool, |
| 214 | ...(process.env.USER_TYPE === 'ant' ? [ConfigTool] : []), |
| 215 | ...(process.env.USER_TYPE === 'ant' ? [TungstenTool] : []), |
| 216 | ...(SuggestBackgroundPRTool ? [SuggestBackgroundPRTool] : []), |
| 217 | ...(WebBrowserTool ? [WebBrowserTool] : []), |
| 218 | ...(isTodoV2Enabled() |
| 219 | ? [TaskCreateTool, TaskGetTool, TaskUpdateTool, TaskListTool] |
| 220 | : []), |
| 221 | ...(OverflowTestTool ? [OverflowTestTool] : []), |
| 222 | ...(CtxInspectTool ? [CtxInspectTool] : []), |
| 223 | ...(TerminalCaptureTool ? [TerminalCaptureTool] : []), |
| 224 | ...(isEnvTruthy(process.env.ENABLE_LSP_TOOL) ? [LSPTool] : []), |
| 225 | ...(isWorktreeModeEnabled() ? [EnterWorktreeTool, ExitWorktreeTool] : []), |
| 226 | getSendMessageTool(), |
| 227 | ...(ListPeersTool ? [ListPeersTool] : []), |
| 228 | ...(isAgentSwarmsEnabled() |
| 229 | ? [getTeamCreateTool(), getTeamDeleteTool()] |
| 230 | : []), |
| 231 | ...(VerifyPlanExecutionTool ? [VerifyPlanExecutionTool] : []), |
| 232 | ...(process.env.USER_TYPE === 'ant' && REPLTool ? [REPLTool] : []), |
| 233 | ...(WorkflowTool ? [WorkflowTool] : []), |
| 234 | ...(SleepTool ? [SleepTool] : []), |
| 235 | ...cronTools, |
| 236 | ...(RemoteTriggerTool ? [RemoteTriggerTool] : []), |
| 237 | ...(MonitorTool ? [MonitorTool] : []), |
| 238 | BriefTool, |
| 239 | ...(SendUserFileTool ? [SendUserFileTool] : []), |
| 240 | ...(PushNotificationTool ? [PushNotificationTool] : []), |
| 241 | ...(SubscribePRTool ? [SubscribePRTool] : []), |
| 242 | ...(getPowerShellTool() ? [getPowerShellTool()] : []), |
| 243 | ...(SnipTool ? [SnipTool] : []), |
| 244 | ...(process.env.NODE_ENV === 'test' ? [TestingPermissionTool] : []), |
| 245 | ListMcpResourcesTool, |
| 246 | ReadMcpResourceTool, |
| 247 | // Include ToolSearchTool when tool search might be enabled (optimistic check) |
| 248 | // The actual decision to defer tools happens at request time in claude.ts |
| 249 | ...(isToolSearchEnabledOptimistic() ? [ToolSearchTool] : []), |
| 250 | ] |
no test coverage detected