You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ENG-524 Remove supportsComputerUse restriction and support browser use through any model that supports images (RooCodeInc#3048)
* Enhance fixWithCline command execution by focusing chat input and adding a delay before processing the fixWithCline command.
* feat: add OpenRouter base URL and balance display component
* refactor: remove supportsComputerUse from modelInfo and related components, replacing with supportsImages where applicable
* feat: add OpenRouter base URL and balance display component
* feat: add OpenRouter base URL and balance display component
* feat: add OpenRouter base URL and balance display component
* feat: add OpenRouter base URL and balance display component
* feat: add OpenRouter base URL and balance display component
Copy file name to clipboardExpand all lines: src/core/prompts/system.ts
+6-6Lines changed: 6 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ import { BrowserSettings } from "@shared/BrowserSettings"
6
6
7
7
exportconstSYSTEM_PROMPT=async(
8
8
cwd: string,
9
-
supportsComputerUse: boolean,
9
+
supportsBrowserUse: boolean,
10
10
mcpHub: McpHub,
11
11
browserSettings: BrowserSettings,
12
12
)=>`You are Cline, a highly skilled software engineer with extensive knowledge in many programming languages, frameworks, design patterns, and best practices.
@@ -138,7 +138,7 @@ Usage:
138
138
<list_code_definition_names>
139
139
<path>Directory path here</path>
140
140
</list_code_definition_names>${
141
-
supportsComputerUse
141
+
supportsBrowserUse
142
142
? `
143
143
144
144
## browser_action
@@ -561,14 +561,14 @@ In each user message, the environment_details will specify the current mode. The
561
561
CAPABILITIES
562
562
563
563
- You have access to tools that let you execute CLI commands on the user's computer, list files, view source code definitions, regex search${
564
-
supportsComputerUse ? ", use the browser" : ""
564
+
supportsBrowserUse ? ", use the browser" : ""
565
565
}, read and edit files, and ask follow-up questions. These tools help you effectively accomplish a wide range of tasks, such as writing code, making edits or improvements to existing files, understanding the current state of a project, performing system operations, and much more.
566
566
- When the user initially gives you a task, a recursive list of all filepaths in the current working directory ('${cwd.toPosix()}') will be included in environment_details. This provides an overview of the project's file structure, offering key insights into the project from directory/file names (how developers conceptualize and organize their code) and file extensions (the language used). This can also guide decision-making on which files to explore further. If you need to further explore directories such as outside the current working directory, you can use the list_files tool. If you pass 'true' for the recursive parameter, it will list files recursively. Otherwise, it will list files at the top level, which is better suited for generic directories where you don't necessarily need the nested structure, like the Desktop.
567
567
- You can use search_files to perform regex searches across files in a specified directory, outputting context-rich results that include surrounding lines. This is particularly useful for understanding code patterns, finding specific implementations, or identifying areas that need refactoring.
568
568
- You can use the list_code_definition_names tool to get an overview of source code definitions for all files at the top level of a specified directory. This can be particularly useful when you need to understand the broader context and relationships between certain parts of the code. You may need to call this tool multiple times to understand various parts of the codebase related to the task.
569
569
- For example, when asked to make edits or improvements you might analyze the file structure in the initial environment_details to get an overview of the project, then use list_code_definition_names to get further insight using source code definitions for files located in relevant directories, then read_file to examine the contents of relevant files, analyze the code and suggest improvements or make necessary edits, then use the replace_in_file tool to implement changes. If you refactored code that could affect other parts of the codebase, you could use search_files to ensure you update other files as needed.
570
570
- You can use the execute_command tool to run commands on the user's computer whenever you feel it can help accomplish the user's task. When you need to execute a CLI command, you must provide a clear explanation of what the command does. Prefer to execute complex CLI commands over creating executable scripts, since they are more flexible and easier to run. Interactive and long-running commands are allowed, since the commands are run in the user's VSCode terminal. The user may keep commands running in the background and you will be kept updated on their status along the way. Each command you execute is run in a new terminal instance.${
571
-
supportsComputerUse
571
+
supportsBrowserUse
572
572
? "\n- You can use the browser_action tool to interact with websites (including html files and locally running development servers) through a Puppeteer-controlled browser when you feel it is necessary in accomplishing the user's task. This tool is particularly useful for web development tasks as it allows you to launch a browser, navigate to pages, interact with elements through clicks and keyboard input, and capture the results through screenshots and console logs. This tool may be useful at key stages of web development tasks-such as after implementing new features, making substantial changes, when troubleshooting issues, or to verify the result of your work. You can analyze the provided screenshots to ensure correct rendering or identify errors, and review console logs for runtime issues.\n - For example, if asked to add a component to a react website, you might create the necessary files, use execute_command to run the site locally, then use browser_action to launch the browser, navigate to the local server, and verify the component renders & functions correctly before closing the browser."
573
573
: ""
574
574
}
@@ -592,7 +592,7 @@ RULES
592
592
- When executing commands, if you don't see the expected output, assume the terminal executed the command successfully and proceed with the task. The user's terminal may be unable to stream the output back properly. If you absolutely need to see the actual terminal output, use the ask_followup_question tool to request the user to copy and paste it back to you.
593
593
- The user may provide a file's contents directly in their message, in which case you shouldn't use the read_file tool to get the file contents again since you already have it.
594
594
- Your goal is to try to accomplish the user's task, NOT engage in a back and forth conversation.${
595
-
supportsComputerUse
595
+
supportsBrowserUse
596
596
? `\n- The user may ask generic non-development tasks, such as "what\'s the latest news" or "look up the weather in San Diego", in which case you might use the browser_action tool to complete the task if it makes sense to do so, rather than trying to create a website or using curl to answer the question. However, if an available MCP server tool or resource can be used instead, you should prefer to use it over browser_action.`
597
597
: ""
598
598
}
@@ -604,7 +604,7 @@ RULES
604
604
- When using the replace_in_file tool, you must include complete lines in your SEARCH blocks, not partial lines. The system requires exact line matches and cannot match partial lines. For example, if you want to match a line containing "const x = 5;", your SEARCH block must include the entire line, not just "x = 5" or other fragments.
605
605
- When using the replace_in_file tool, if you use multiple SEARCH/REPLACE blocks, list them in the order they appear in the file. For example if you need to make changes to both line 10 and line 50, first include the SEARCH/REPLACE block for line 10, followed by the SEARCH/REPLACE block for line 50.
606
606
- It is critical you wait for the user's response after each tool use, in order to confirm the success of the tool use. For example, if asked to make a todo app, you would create a file, wait for the user's response it was created successfully, then create another file if needed, wait for the user's response it was created successfully, etc.${
607
-
supportsComputerUse
607
+
supportsBrowserUse
608
608
? " Then if you want to test your work, you might use browser_action to launch the site, wait for the user's response confirming the site was launched along with a screenshot, then perhaps e.g., click a button to test functionality if needed, wait for the user's response confirming the button was clicked along with a screenshot of the new state, before finally closing the browser."
constsupportsComputerUse=modelSupportsComputerUse&&!disableBrowserTool// only enable computer use if the model supports it and the user hasn't disabled it
1429
+
constsupportsBrowserUse=modelSupportsBrowserUse&&!disableBrowserTool// only enable browser use if the model supports it and the user hasn't disabled it
0 commit comments