Skip to content
Open
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
6 changes: 6 additions & 0 deletions packages/types/src/global-settings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,12 @@ export const globalSettingsSchema = z.object({
alwaysAllowMcp: z.boolean().optional(),
alwaysAllowModeSwitch: z.boolean().optional(),
alwaysAllowSubtasks: z.boolean().optional(),
/**
* Auto-approve `fetch_web_content` requests without prompting. Internal and
* private network addresses remain blocked regardless of this setting.
* @default false
*/
alwaysAllowWebFetch: z.boolean().optional(),
alwaysAllowExecute: z.boolean().optional(),
destructiveCommandGuardEnabled: z.boolean().optional(),
/**
Expand Down
8 changes: 4 additions & 4 deletions packages/types/src/mode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ export const DEFAULT_MODES: readonly ModeConfig[] = [
whenToUse:
"Use this mode when you need to plan, design, or strategize before implementation. Perfect for breaking down complex problems, creating technical specifications, designing system architecture, or brainstorming solutions before coding.",
description: "Plan and design before implementation",
groups: ["read", ["edit", { fileRegex: "\\.md$", description: "Markdown files only" }], "mcp"],
groups: ["read", ["edit", { fileRegex: "\\.md$", description: "Markdown files only" }], "mcp", "web"],
customInstructions:
'1. Do some information gathering (using provided tools) to get more context about the task.\n\n2. You should also ask the user clarifying questions to get a better understanding of the task.\n\n3. Once you\'ve gained more context about the user\'s request, break down the task into clear, actionable steps and create a todo list using the `update_todo_list` tool. Each todo item should be:\n - Specific and actionable\n - Listed in logical execution order\n - Focused on a single, well-defined outcome\n - Clear enough that another mode could execute it independently\n\n **Note:** If the `update_todo_list` tool is not available, write the plan to a markdown file (e.g., `plan.md` or `todo.md`) instead.\n\n4. As you gather more information or discover new requirements, update the todo list to reflect the current understanding of what needs to be accomplished.\n\n5. Ask the user if they are pleased with this plan, or if they would like to make any changes. Think of this as a brainstorming session where you can discuss the task and refine the todo list.\n\n6. Include Mermaid diagrams if they help clarify complex workflows or system architecture. Please avoid using double quotes ("") and parentheses () inside square brackets ([]) in Mermaid diagrams, as this can cause parsing errors.\n\n7. Use the switch_mode tool to request that the user switch to another mode to implement the solution.\n\n**IMPORTANT: Focus on creating clear, actionable todo lists rather than lengthy markdown documents. Use the todo list as your primary planning tool to track and organize the work that needs to be done.**\n\n**CRITICAL: Never provide level of effort time estimates (e.g., hours, days, weeks) for tasks. Focus solely on breaking down the work into clear, actionable steps without estimating how long they will take.**\n\nUnless told otherwise, if you want to save a plan file, put it in the ./plans directory (a directory named "plans" relative to the workspace root, not the absolute filesystem path /plans)',
},
Expand All @@ -192,7 +192,7 @@ export const DEFAULT_MODES: readonly ModeConfig[] = [
whenToUse:
"Use this mode when you need to write, modify, or refactor code. Ideal for implementing features, fixing bugs, creating new files, or making code improvements across any programming language or framework.",
description: "Write, modify, and refactor code",
groups: ["read", "edit", "command", "mcp"],
groups: ["read", "edit", "command", "mcp", "web"],
Comment thread
p12tic marked this conversation as resolved.
Resolved
},
{
slug: "ask",
Expand All @@ -202,7 +202,7 @@ export const DEFAULT_MODES: readonly ModeConfig[] = [
whenToUse:
"Use this mode when you need explanations, documentation, or answers to technical questions. Best for understanding concepts, analyzing existing code, getting recommendations, or learning about technologies without making changes.",
description: "Get answers and explanations",
groups: ["read", "mcp"],
groups: ["read", "mcp", "web"],
customInstructions:
"You can analyze code, explain concepts, and access external resources. Always answer the user's questions thoroughly, and do not switch to implementing code unless explicitly requested by the user. Include Mermaid diagrams when they clarify your response.",
},
Expand All @@ -214,7 +214,7 @@ export const DEFAULT_MODES: readonly ModeConfig[] = [
whenToUse:
"Use this mode when you're troubleshooting issues, investigating errors, or diagnosing problems. Specialized in systematic debugging, adding logging, analyzing stack traces, and identifying root causes before applying fixes.",
description: "Diagnose and fix software issues",
groups: ["read", "edit", "command", "mcp"],
groups: ["read", "edit", "command", "mcp", "web"],
customInstructions:
"Reflect on 5-7 different possible sources of the problem, distill those down to 1-2 most likely sources, and then add logs to validate your assumptions. Explicitly ask the user to confirm the diagnosis before fixing the problem.",
},
Expand Down
3 changes: 2 additions & 1 deletion packages/types/src/tool.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { z } from "zod"
* ToolGroup
*/

export const toolGroups = ["read", "edit", "command", "mcp", "modes"] as const
export const toolGroups = ["read", "edit", "command", "mcp", "modes", "web"] as const

export const toolGroupsSchema = z.enum(toolGroups)

Expand Down Expand Up @@ -47,6 +47,7 @@ export const toolNames = [
"generate_image",
"custom_tool",
"invalid_tool_call",
"fetch_web_content",
] as const

export const toolNamesSchema = z.enum(toolNames)
Expand Down
3 changes: 3 additions & 0 deletions packages/types/src/vscode-extension-host.ts
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,7 @@ export type ExtensionState = Pick<
| "alwaysAllowMcp"
| "alwaysAllowModeSwitch"
| "alwaysAllowSubtasks"
| "alwaysAllowWebFetch"
| "alwaysAllowFollowupQuestions"
| "alwaysAllowExecute"
| "destructiveCommandGuardEnabled"
Expand Down Expand Up @@ -873,6 +874,8 @@ export interface ClineSayTool {
| "runSlashCommand"
| "updateTodoList"
| "skill"
| "fetchWebContent"
url?: string
path?: string
// For readCommandOutput
readStart?: number
Expand Down
Loading
Loading