Skip to content

Commit e9e774d

Browse files
authored
Remove TodoListToolInstructions references from agent prompts (#1166)
1 parent e361b5e commit e9e774d

File tree

2 files changed

+3
-54
lines changed

2 files changed

+3
-54
lines changed

src/extension/prompts/node/agent/agentInstructions.tsx

Lines changed: 1 addition & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,6 @@ export class DefaultAgentPrompt extends PromptElement<DefaultAgentPromptProps> {
184184
</Tag>}
185185
{tools[ToolName.ApplyPatch] && <ApplyPatchInstructions {...this.props} tools={tools} />}
186186
{this.props.availableTools && <McpToolInstructions tools={this.props.availableTools} />}
187-
{tools[ToolName.CoreManageTodoList] && <TodoListToolInstructions {...this.props} />}
188187
<NotebookInstructions {...this.props} />
189188
<Tag name='outputFormatting'>
190189
Use proper Markdown formatting in your answers. When referring to a filename or symbol in the user's workspace, wrap it in backticks.<br />
@@ -597,7 +596,6 @@ export class DefaultAgentPromptV2 extends PromptElement<DefaultAgentPromptProps>
597596
- You don't currently have any tools available for editing files. If the user asks you to edit a file, request enabling editing tools or print a codeblock with the suggested changes.<br />
598597
</Tag>}
599598
{this.props.codesearchMode && <Tag name='codesearch_mode_instructions'><CodesearchModeInstructions {...this.props} /></Tag>}
600-
{tools[ToolName.CoreManageTodoList] && <TodoListToolInstructions {...this.props} />}
601599
{isGrokCode && tools[ToolName.ReplaceString] && !tools[ToolName.ApplyPatch] && <Tag name='edit_file_instructions'>
602600
Before you edit an existing file, make sure you either already have it in the provided context, or read it with the {ToolName.ReadFile} tool, so that you can make proper changes.<br />
603601
{tools[ToolName.MultiReplaceString]
@@ -785,7 +783,6 @@ export class AlternateGPTPrompt extends PromptElement<DefaultAgentPromptProps> {
785783
</Tag>}
786784
{tools[ToolName.ApplyPatch] && <ApplyPatchInstructions {...this.props} tools={tools} />}
787785
{this.props.availableTools && <McpToolInstructions tools={this.props.availableTools} />}
788-
{tools[ToolName.CoreManageTodoList] && <TodoListToolInstructions {...this.props} />}
789786
<NotebookInstructions {...this.props} />
790787
<Tag name='outputFormatting'>
791788
Use proper Markdown formatting in your answers. When referring to a filename or symbol in the user's workspace, wrap it in backticks.<br />
@@ -1117,52 +1114,4 @@ class NotebookInstructions extends PromptElement<DefaultAgentPromptProps> {
11171114
}
11181115
}
11191116

1120-
class TodoListToolInstructions extends PromptElement<DefaultAgentPromptProps> {
1121-
render() {
1122-
return <Tag name='planning_instructions'>
1123-
You have access to an {ToolName.CoreManageTodoList} tool which tracks todos and progress and renders them to the user. Using the tool helps demonstrate that you've understood the task and convey how you're approaching it. Plans can help to make complex, ambiguous, or multi-phase work clearer and more collaborative for the user. A good plan should break the task into meaningful, logically ordered steps that are easy to verify as you go. Note that plans are not for padding out simple work with filler steps or stating the obvious. <br />
1124-
Use this tool to create and manage a structured todo list for your current coding session. This helps you track progress, organize complex tasks, and demonstrate thoroughness to the user.<br />
1125-
It also helps the user understand the progress of the task and overall progress of their requests.<br />
1126-
<br />
1127-
NOTE that you should not use this tool if there is only one trivial task to do. In this case you are better off just doing the task directly.<br />
1128-
<br />
1129-
Use a plan when:<br />
1130-
- The task is non-trivial and will require multiple actions over a long time horizon.<br />
1131-
- There are logical phases or dependencies where sequencing matters.<br />
1132-
- The work has ambiguity that benefits from outlining high-level goals.<br />
1133-
- You want intermediate checkpoints for feedback and validation.<br />
1134-
- When the user asked you to do more than one thing in a single prompt<br />
1135-
- The user has asked you to use the plan tool (aka "TODOs")<br />
1136-
- You generate additional steps while working, and plan to do them before yielding to the user<br />
1137-
<br />
1138-
Skip a plan when:<br />
1139-
- The task is simple and direct.<br />
1140-
- Breaking it down would only produce literal or trivial steps.<br />
1141-
<br />
1142-
Examples of TRIVIAL tasks (skip planning):<br />
1143-
- "Fix this typo in the README"<br />
1144-
- "Add a console.log statement to debug"<br />
1145-
- "Update the version number in package.json"<br />
1146-
- "Answer a question about existing code"<br />
1147-
- "Read and explain what this function does"<br />
1148-
- "Add a simple getter method to a class"<br />
1149-
<br />
1150-
Examples of NON-TRIVIAL tasks and the plan (use planning):<br />
1151-
- "Add user authentication to the app" → Design auth flow, Update backend API, Implement login UI, Add session management<br />
1152-
- "Refactor the payment system to support multiple currencies" → Analyze current system, Design new schema, Update backend logic, Migrate data, Update frontend<br />
1153-
- "Debug and fix the performance issue in the dashboard" → Profile performance, Identify bottlenecks, Implement optimizations, Validate improvements<br />
1154-
- "Implement a new feature with multiple components" → Design component architecture, Create data models, Build UI components, Add integration tests<br />
1155-
- "Migrate from REST API to GraphQL" → Design GraphQL schema, Update backend resolvers, Migrate frontend queries, Update documentation<br />
1156-
<br />
1157-
<br />
1158-
Planning Progress Rules<br />
1159-
- Before beginning any new todo: you MUST update the todo list and mark exactly one todo as `in-progress`. Never start work with zero `in-progress` items.<br />
1160-
- Keep only one todo `in-progress` at a time. If switching tasks, first mark the current todo `completed` or revert it to `not-started` with a short reason; then set the next todo to `in-progress`.<br />
1161-
- Immediately after finishing a todo: you MUST mark it `completed` and add any newly discovered follow-up todos. Do not leave completion implicit.<br />
1162-
- Before ending your turn or declaring completion: ensure EVERY todo is explicitly marked (`not-started`, `in-progress`, or `completed`). If the work is finished, ALL todos must be marked `completed`. Never leave items unchecked or ambiguous.<br />
1163-
<br />
1164-
The content of your plan should not involve doing anything that you aren't capable of doing (i.e. don't try to test things that you can't test). Do not use plans for simple or single-step queries that you can just do or answer immediately.<br />
1165-
<br />
1166-
</Tag>;
1167-
}
1168-
}
1117+

src/extension/prompts/node/agent/agentPrompt.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ import { ITasksService } from '../../../../platform/tasks/common/tasksService';
2020
import { IExperimentationService } from '../../../../platform/telemetry/common/nullExperimentationService';
2121
import { IWorkspaceService } from '../../../../platform/workspace/common/workspaceService';
2222
import { basename } from '../../../../util/vs/base/common/path';
23+
import { isDefined } from '../../../../util/vs/base/common/types';
2324
import { IInstantiationService } from '../../../../util/vs/platform/instantiation/common/instantiation';
2425
import { ChatRequestEditedFileEventKind, Position, Range } from '../../../../vscodeTypes';
2526
import { GenericBasePromptElementProps } from '../../../context/node/resolvers/genericPanelIntentInvocation';
@@ -46,7 +47,6 @@ import { MultirootWorkspaceStructure } from '../panel/workspace/workspaceStructu
4647
import { AgentConversationHistory } from './agentConversationHistory';
4748
import { AlternateGPTPrompt, CodexStyleGPT5CodexPrompt, CodexStyleGPTPrompt, DefaultAgentPrompt, DefaultAgentPromptV2, SweBenchAgentPrompt } from './agentInstructions';
4849
import { SummarizedConversationHistory } from './summarizedConversationHistory';
49-
import { isDefined } from '../../../../util/vs/base/common/types';
5050

5151
export interface AgentPromptProps extends GenericBasePromptElementProps {
5252
readonly endpoint: IChatEndpoint;
@@ -822,7 +822,7 @@ function getExplanationReminder(modelFamily: string | undefined, hasTodoTool?: b
822822
Before starting a task, review and follow the guidance in &lt;responseModeHints&gt;, &lt;engineeringMindsetHints&gt;, and &lt;requirementsUnderstanding&gt;.<br />
823823
{!isGpt5Mini && <>Start your response with a brief acknowledgement, followed by a concise high-level plan outlining your approach.<br /></>}
824824
DO NOT state your identity or model name unless the user explicitly asks you to. <br />
825-
{hasTodoTool && <>You MUST use the todo list tool to plan and track your progress. NEVER skip this step, and START with this step whenever the task is multi-step. This is essential for maintaining visibility and proper execution of large tasks. Follow the todoListToolInstructions strictly.<br /></>}
825+
{hasTodoTool && <>You MUST use the todo list tool to plan and track your progress. NEVER skip this step, and START with this step whenever the task is multi-step. This is essential for maintaining visibility and proper execution of large tasks.<br /></>}
826826
{!hasTodoTool && <>Break down the request into clear, actionable steps and present them at the beginning of your response before proceeding with implementation. This helps maintain visibility and ensures all requirements are addressed systematically.<br /></>}
827827
When referring to a filename or symbol in the user's workspace, wrap it in backticks.<br />
828828
</Tag>

0 commit comments

Comments
 (0)