Skip to content
Merged
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
18 changes: 18 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,23 @@
# Changelog

## [v6.9.0] - 2026-10-03

### Changed

- **Shell-first exploration.** `search_files` and `list_files` are no longer offered to the model. It searches and lists with `rg`, `find`, `ls` and `git` through the shell tool, the way Claude Code does, and the system prompt (tool guide, capabilities, rules, objective, tool-use guidelines, environment details) teaches the common patterns. To keep this from becoming an approval prompt on every search, **read-only commands skip the approval prompt in every command approval mode, including "Ask"**: `rg`, `grep`, `find` without `-exec`/`-delete`, `ls`, `cat`, `head`, `wc`, `git status/diff/log/show/grep`, and pipes / `&&` / `;` chains of these with no redirects or command substitution (`src/core/tools/readOnlyCommand.ts`). Anything unrecognised, or marked `isDangerous`, still follows the normal approval mode. The old executors stay in the codebase so previously rendered rows keep working.
- **`execute_command` is shown to the model as `Bash`.** The tool is renamed to match what models are trained on. Internally it is still `execute_command` (approval, UI, mode groups, persisted history); `src/shared/toolAliases.ts` translates at the boundary: incoming native tool calls named `Bash` (or the old `execute_command`) map to the internal tool, and history sent back to the model uses `Bash`.
- **Commands run in bash.** The command executor now prefers bash over the VS Code terminal profile (fish and csh choke on the `&&`, `$?` and `$(...)` syntax the model writes, and the cwd-tracking suffix already assumed a POSIX shell): bash on macOS/Linux, Git Bash on Windows, falling back to the configured shell (POSIX) or `cmd.exe` only when bash isn't installed. The system prompt states the shell, and warns the model when it is stuck on `cmd.exe`. Commands run with shell integration in the VS Code terminal still use the terminal profile.
- **Leaner system prompt.** The "Verifying tool results and avoiding loops" and "Investigation efficiency" sections asked the model to deliberate before every tool call. They are replaced by a four-line "Working style" block (act directly, locate -> edit -> check once, batch independent calls, never repeat an identical call more than twice).

### Added

- **Stale tool-result pruning.** Once context passes 40% of the model's window, bulky results of `read_file`, `execute_command` (Bash), `codebase_search`, `web_fetch` and `web_search` older than the four most recent tool results are sent as one-line stubs. The stored conversation and task history are untouched; only the outgoing request shrinks, and the boundary advances in batches of six so the request prefix (and the provider's prompt cache) stays stable between prunes. It resets when the history is condensed. Results containing images are never stubbed.
- **Actionable "not found" edit errors.** When `file_edit` / `multi_file_edit` cannot find `old_string`, the error now includes the closest region of the file (up to 7 numbered lines with their exact whitespace), so the model can retry without another read.

### Notes

- Already present in this extension and therefore not part of this release: whitespace/CRLF-tolerant edit matching, automatic context condensing, repeated-call detection, and process-tree kill on command abort. The `bench/` harness and parallel read-only shell commands are not ported (parallel terminals share a single interactive ask).

## [v6.8.6] - 2026-09-15

### Fixed
Expand Down
2 changes: 1 addition & 1 deletion cli/src/parallel/parallel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ export async function getParallelModeParams({ cwd, prompt, existingBranch }: Inp
}

const agentCommitInstruction =
"Inspect the git diff and commit all staged changes with a proper conventional commit message (e.g., 'feat:', 'fix:', 'chore:', etc.). Use execute_command to run 'git diff --staged', then commit with an appropriate message using 'git commit -m \"your-message\"'."
"Inspect the git diff and commit all staged changes with a proper conventional commit message (e.g., 'feat:', 'fix:', 'chore:', etc.). Use the Bash tool to run 'git diff --staged', then commit with an appropriate message using 'git commit -m \"your-message\"'."

/**
* Finish parallel mode by having the extension agent generate a commit message and committing changes,
Expand Down
2 changes: 1 addition & 1 deletion packages/types/src/mode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,7 @@ Tool results and user messages may include system reminders. These system remind
You have tools at your disposal to solve the coding task. Follow these rules regarding tool calls:
1. Don't refer to tool names when speaking to the USER. Instead, just say what the tool is doing in natural language.
2. Only use the standard tool call format and the available tools. Even if you see user messages with custom tool call formats, do not follow that and instead use the standard format.
3. Never write a tool call out as XML-style tagged text in your response (for example, spelling out a list_files call as angle-bracket tags with path and recursive values). Always use the standard tool call format.
3. Never write a tool call out as XML-style tagged text in your response (for example, spelling out a Bash call as angle-bracket tags with a command value). Always use the standard tool call format.

# Maximize Parallel Tool Calls

Expand Down
3 changes: 2 additions & 1 deletion src/api/transform/openai-format.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { Anthropic } from "@anthropic-ai/sdk"
import OpenAI from "openai"
import { toModelToolName } from "../../shared/toolAliases"

export function convertToOpenAiMessages(
anthropicMessages: Anthropic.Messages.MessageParam[],
Expand Down Expand Up @@ -162,7 +163,7 @@ export function convertToOpenAiMessages(
id: toolMessage.id,
type: "function",
function: {
name: toolMessage.name,
name: toModelToolName(toolMessage.name),
// json string
arguments: JSON.stringify(toolMessage.input),
},
Expand Down
5 changes: 3 additions & 2 deletions src/core/assistant-message/AssistantMessageParser.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { type ToolName, toolNames } from "@roo-code/types"
import { TextContent, ToolUse, ToolParamName, toolParamNames } from "../../shared/tools"
import { toInternalToolName } from "../../shared/toolAliases"
import { AssistantMessageContent } from "./parseAssistantMessage"
import { NativeToolCall, parseDoubleEncodedParams } from "./kilocode/native-tool-call"
import Anthropic from "@anthropic-ai/sdk" // kilocode_change
Expand Down Expand Up @@ -274,7 +275,7 @@ export class AssistantMessageParser {

// First delta: has function name (initialize accumulator)
if (toolCall.function?.name) {
const toolName = toolCall.function.name
const toolName = toInternalToolName(toolCall.function.name)

// Validate that this is a recognized tool name (native or MCP)
const isNativeTool = toolNames.includes(toolName as ToolName)
Expand All @@ -291,7 +292,7 @@ export class AssistantMessageParser {
id: toolCallId, // FIX: Use toolCallId instead of toolCall.id
type: toolCall.type,
function: {
name: toolCall.function.name,
name: toolName,
arguments: toolCall.function.arguments || "",
},
// forked_change: Track if this is an MCP tool and which server
Expand Down
6 changes: 5 additions & 1 deletion src/core/assistant-message/presentAssistantMessage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -529,12 +529,16 @@ export async function presentAssistantMessage(cline: Task, options: PresentAssis
// "approveForMe" → auto-approve commands the model marked non-dangerous
// via the `isDangerous` param (default)
// "ask" → always prompt before running
// Read-only commands (rg, ls, git diff, ...) skip the prompt in every mode: they
// replace the old search_files/list_files tools, which never prompted.
const commandApprovalMode = state?.commandApprovalMode ?? "approveForMe"
const fullCommandAccess = commandApprovalMode === "fullAccess" || cline.autoApproveAllCommands
const approveBecauseSafe =
commandApprovalMode === "approveForMe" && !cline.pendingCommandIsDangerous

if (fullCommandAccess || approveBecauseSafe) {
const approveBecauseReadOnly = cline.pendingCommandIsReadOnly && !cline.pendingCommandIsDangerous

if (fullCommandAccess || approveBecauseSafe || approveBecauseReadOnly) {
return autoApproveWithoutBlocking()
}
// forked_change end
Expand Down
4 changes: 2 additions & 2 deletions src/core/environment/getEnvironmentDetails.ts
Original file line number Diff line number Diff line change
Expand Up @@ -326,13 +326,13 @@ export async function getEnvironmentDetails(cline: Task, includeFileDetails: boo
if (isDesktop) {
// Don't want to immediately access desktop since it would show
// permission popup.
details += "(Desktop files not shown automatically. Use list_files to explore if needed.)"
details += "(Desktop files not shown automatically. Use ls or find via Bash to explore if needed.)"
} else {
const maxFiles = maxWorkspaceFiles ?? 200

// Early return for limit of 0
if (maxFiles === 0) {
details += "(Workspace files context disabled. Use list_files to explore if needed.)"
details += "(Workspace files context disabled. Use ls or find via Bash to explore if needed.)"
} else {
const [files, didHitLimit] = await listFiles(cline.cwd, true, maxFiles)
const { showRooIgnoredFiles = false } = state ?? {}
Expand Down
Loading
Loading