Add stricter prompt to prevent file edit during browser session

This commit is contained in:
Saoud Rizwan 2024-10-28 15:10:49 -04:00
parent 87d10c36d1
commit 4658e5cead
3 changed files with 6 additions and 2 deletions

View File

@ -1,5 +1,9 @@
# Change Log # Change Log
## [2.1.1]
- Add stricter prompt to prevent Cline from editing files during a browser session without first closing the browser
## [2.1.0] ## [2.1.0]
- Cline now uses Anthropic's new "Computer Use" feature to launch a browser, click, type, and scroll. This gives him more autonomy in runtime debugging, end-to-end testing, and even general web use. Try asking "Look up the weather in Colorado" to see it in action! (Available with Claude 3.5 Sonnet v2) - Cline now uses Anthropic's new "Computer Use" feature to launch a browser, click, type, and scroll. This gives him more autonomy in runtime debugging, end-to-end testing, and even general web use. Try asking "Look up the weather in Colorado" to see it in action! (Available with Claude 3.5 Sonnet v2)

View File

@ -2,7 +2,7 @@
"name": "claude-dev", "name": "claude-dev",
"displayName": "Cline (prev. Claude Dev)", "displayName": "Cline (prev. Claude Dev)",
"description": "Autonomous coding agent right in your IDE, capable of creating/editing files, running commands, using the browser, and more with your permission every step of the way.", "description": "Autonomous coding agent right in your IDE, capable of creating/editing files, running commands, using the browser, and more with your permission every step of the way.",
"version": "2.1.0", "version": "2.1.1",
"icon": "assets/icons/icon.png", "icon": "assets/icons/icon.png",
"galleryBanner": { "galleryBanner": {
"color": "#617A91", "color": "#617A91",

View File

@ -1467,7 +1467,7 @@ export class Cline {
formatResponse.toolResult( formatResponse.toolResult(
`The browser action has been executed. The console logs and screenshot have been captured for your analysis.\n\nConsole logs:\n${ `The browser action has been executed. The console logs and screenshot have been captured for your analysis.\n\nConsole logs:\n${
browserActionResult.logs || "(No new logs)" browserActionResult.logs || "(No new logs)"
}\n\n(REMEMBER: if you need to proceed to using non-\`browser_action\` tools or launch a new browser, you MUST first close this browser.)`, }\n\n(REMEMBER: if you need to proceed to using non-\`browser_action\` tools or launch a new browser, you MUST first close this browser. For example, if after analyzing the logs and screenshot you need to edit a file, you must first close the browser before you can use the write_to_file tool.)`,
browserActionResult.screenshot ? [browserActionResult.screenshot] : [] browserActionResult.screenshot ? [browserActionResult.screenshot] : []
) )
) )