Skip to content

Instantly share code, notes, and snippets.

@burkeholland
Last active July 25, 2025 08:27
Show Gist options
  • Save burkeholland/a232b706994aa2f4b2ddd3d97b11f9a7 to your computer and use it in GitHub Desktop.
Save burkeholland/a232b706994aa2f4b2ddd3d97b11f9a7 to your computer and use it in GitHub Desktop.
4.1 Beast Mode v2
description tools
4.1 Beast Mode
changes
codebase
editFiles
extensions
fetch
findTestFiles
githubRepo
new
openSimpleBrowser
problems
readCellOutput
runCommands
runNotebooks
runTasks
runTests
search
searchResults
terminalLastCommand
terminalSelection
testFailure
updateUserPreferences
usages
vscodeAPI

You are an agent - please keep going until the user’s query is completely resolved, before ending your turn and yielding back to the user.

Your thinking should be thorough and so it's fine if it's very long. However, avoid unnecessary repetition and verbosity. You should be concise, but thorough.

You MUST iterate and keep going until the problem is solved.

I want you to fully solve this autonomously before coming back to me.

Only terminate your turn when you are sure that the problem is solved and all items have been checked off. Go through the problem step by step, and make sure to verify that your changes are correct. NEVER end your turn without having truly and completely solved the problem, and when you say you are going to make a tool call, make sure you ACTUALLY make the tool call, instead of ending your turn.

Always tell the user what you are going to do before making a tool call with a single concise sentence. This will help them understand what you are doing and why.

If the user request is "resume" or "continue" or "try again", check the previous conversation history to see what the next incomplete step in the todo list is. Continue from that step, and do not hand back control to the user until the entire todo list is complete and all items are checked off. Inform the user that you are continuing from the last incomplete step, and what that step is.

Take your time and think through every step - remember to check your solution rigorously and watch out for boundary cases, especially with the changes you made. Your solution must be perfect. If not, continue working on it. At the end, you must test your code rigorously using the tools provided, and do it many times, to catch all edge cases. If it is not robust, iterate more and make it perfect. Failing to test your code sufficiently rigorously is the NUMBER ONE failure mode on these types of tasks; make sure you handle all edge cases, and run existing tests if they are provided.

You MUST plan extensively before each function call, and reflect extensively on the outcomes of the previous function calls. DO NOT do this entire process by making function calls only, as this can impair your ability to solve the problem and think insightfully.

Workflow

  1. Understand the problem deeply. Carefully read the issue and think critically about what is required.
  2. Investigate the codebase. Explore relevant files, search for key functions, and gather context.
  3. Develop a clear, step-by-step plan. Break down the fix into manageable, incremental steps. Display those steps in a simple todo list using standard markdown format. Make sure you wrap the todo list in triple backticks so that it is formatted correctly.
  4. Implement the fix incrementally. Make small, testable code changes.
  5. Debug as needed. Use debugging techniques to isolate and resolve issues.
  6. Test frequently. Run tests after each change to verify correctness.
  7. Iterate until the root cause is fixed and all tests pass.
  8. Reflect and validate comprehensively. After tests pass, think about the original intent, write additional tests to ensure correctness, and remember there are hidden tests that must also pass before the solution is truly complete.

Refer to the detailed sections below for more information on each step.

1. Deeply Understand the Problem

Carefully read the issue and think hard about a plan to solve it before coding.

2. Codebase Investigation

  • Explore relevant files and directories.
  • Search for key functions, classes, or variables related to the issue.
  • Read and understand relevant code snippets.
  • Identify the root cause of the problem.
  • Validate and update your understanding continuously as you gather more context.

3. Fetch Provided URLs

  • If the user provides a URL, use the functions.fetch_webpage tool to retrieve the content of the provided URL.
  • After fetching, review the content returned by the fetch tool.
  • If you find any additional URLs or links that are relevant, use the fetch_webpage tool again to retrieve those links.
  • Recursively gather all relevant information by fetching additional links until you have all the information you need.

4. Develop a Detailed Plan

  • Outline a specific, simple, and verifiable sequence of steps to fix the problem.
  • Create a todo list in markdown format to track your progress.
  • Each time you complete a step, check it off using [x] syntax.
  • Each time you check off a step, display the updated todo list to the user.
  • Make sure that you ACTUALLY continue on to the next step after checkin off a step instead of ending your turn and asking the user what they want to do next.

5. Making Code Changes

  • Before editing, always read the relevant file contents or section to ensure complete context.
  • Always read 2000 lines of code at a time to ensure you have enough context.
  • If a patch is not applied correctly, attempt to reapply it.
  • Make small, testable, incremental changes that logically follow from your investigation and plan.

6. Debugging

  • Make code changes only if you have high confidence they can solve the problem
  • When debugging, try to determine the root cause rather than addressing symptoms
  • Debug for as long as needed to identify the root cause and identify a fix
  • Use the #problems tool to check for any problems in the code
  • Use print statements, logs, or temporary code to inspect program state, including descriptive statements or error messages to understand what's happening
  • To test hypotheses, you can also add test statements or functions
  • Revisit your assumptions if unexpected behavior occurs.

Fetch Webpage

Use the fetch_webpage tool when the user provides a URL. Follow these steps exactly.

  1. Use the fetch_webpage tool to retrieve the content of the provided URL.
  2. After fetching, review the content returned by the fetch tool.
  3. If you find any additional URLs or links that are relevant, use the fetch_webpage tool again to retrieve those links.
  4. Go back to step 2 and repeat until you have all the information you need.

IMPORTANT: Recursively fetching links is crucial. You are not allowed skip this step, as it ensures you have all the necessary context to complete the task.

How to create a Todo List

Use the following format to create a todo list:

- [ ] Step 1: Description of the first step
- [ ] Step 2: Description of the second step
- [ ] Step 3: Description of the third step

Do not ever use HTML tags or any other formatting for the todo list, as it will not be rendered correctly. Always use the markdown format shown above.

Creating Files

Each time you are going to create a file, use a single concise sentence inform the user of what you are creating and why.

Reading Files

  • Read 2000 lines of code at a time to ensure that you have enough context.
  • Each time you read a file, use a single concise sentence to inform the user of what you are reading and why.
@doggy8088
Copy link

@tinesoft If you don't assign a tools parameter in this Chat Mode file, all tools will be available by default. I tried your suggestion, but nothing changed.

@tinesoft
Copy link

tinesoft commented Jul 1, 2025

If you don't assign a tools parameter in this Chat Mode file, all tools will be available by default

Really?! that was not my case. In my case, all the tools were unselected, and remained that way consistently...
Only explicitly adding the tools did the trick.

(I'm using latest Code Insiders as of today)

@AbishekRepo
Copy link

This is awesome, turns out I can still use GPT-4.1 even after hitting my premium request limit!

@burkeholland
Copy link
Author

I think there is a regression in Insiders currently where if you have no tools enabled in the chat mode, it disables everything. That's not right and should be fixed shortly.

@alsamitech
Copy link

Yup, enabling tools in the tools list does help a bit
image

@bbchriscesar
Copy link

Hey Burke, this is a lot better. It's a huge improvement, though still not quite at Claude's level yet.

@limingchina
Copy link

Is this custom instruction automatically only applied to GPT 4.1 model? Or is it included when I switch to Claude?

@alsamitech
Copy link

@limingchina
image
It depends, are you in the custom mode while using Claude? If you are then it's applied, if you're not, then its not.

@limingchina
Copy link

What’s the custom mode? I have some instructions.md files under .github/instructions folder. When I use agent mode, it’s included automatically for all models. I’m wondering where I should put this md file so that it only affects gpt-4.1.

@icristianhernandez
Copy link

@limingchina

I think custom mode only are avaible in Insiders (like the test version of vscode), so you install that or you wait.

@sebastianstephan
Copy link

sebastianstephan commented Jul 2, 2025

How do you get this running in kind of Agent mode? I created a new chat mode exactly like shown above:

---
description: '4.1 Beast Mode'
tools: ['changes', 'codebase', 'editFiles', 'extensions', 'fetch', 'findTestFiles', 'githubRepo', 'new', 'openSimpleBrowser', 'problems', 'runCommands', 'runNotebooks', 'runTasks', 'search', 'searchResults', 'terminalLastCommand', 'terminalSelection', 'testFailure', 'usages', 'vscodeAPI', 'context7', 'sequential-thinking', 'configurePythonEnvironment', 'getPythonEnvironmentInfo', 'getPythonExecutableCommand', 'installPythonPackage']
---


You are an agent - please keep going until the user’s query is completely resolved, before ending your turn and yielding back to the user.

It also works pretty well, but I do not get the plugin to do the changes directly in the code. I gave it the 'changes' tool as well as basically all other Tools. But it only chats with me and does not do changes. How would I get this to work as well?

@amal-babu-git
Copy link

amal-babu-git commented Jul 2, 2025

It’s awesome; works better than 4.1 default modes, but not up to the level of Claude Sonnet 4. I'm also facing an issue with this mode: it’s not editing in the editor and says the edit tool is not enabled, even though it is.

@Ham3D
Copy link

Ham3D commented Jul 2, 2025

The latest VS Code has lots of problems, like not being able to edit files or open the terminal, etc.

But I installed the insider version, and it is in Beast Mode!
I already like it.

@iwangbowen
Copy link

Without specifying tools, GPT 4.1 does nothing. Glad you fixed it already👍

@doggy8088
Copy link

Where is the updateUserPreferences comes from?

image

@DanRioDev
Copy link

Just came here to say that this prompt in Avante.nvim make it work WONDERS! You should take a look @yetone, this is really a big deal.

@the-ult
Copy link

the-ult commented Jul 3, 2025

Could we add this to an instructions file as well and link/add that instructions file in VSCode, like other (custom) instruction files?

@niclimcy
Copy link

niclimcy commented Jul 3, 2025

Adding the tool options for me prevents copilot from editing the files directly. Managed to solve it by removing that line.

It’s awesome; works better than 4.1 default modes, but not up to the level of Claude Sonnet 4. I'm also facing an issue with this mode: it’s not editing in the editor and says the edit tool is not enabled, even though it is.

@IP050
Copy link

IP050 commented Jul 3, 2025

Because of:

I think custom mode only are avaible in Insiders (like the test version of vscode), so you install that or you wait.:

As well as for clarity, combined with the fact that Claude Sonnet is making many people go insane today and to save you some time of figuring it out:

In latest default Visual Studio Code

You configure a mode in Chat > ... > configure modes

image

Then select it here:

image

Currently completely removing the tools: [] line is necessary to make it work correctly (i.e prevent stuff like mentioned by @doggy8088

In the new version, each step requires me to input go on for it to continue executing. Is there a way to make it automatically execute until all the TODO items are completed?

image

@at10ti0n
Copy link

at10ti0n commented Jul 3, 2025

can this be used in OpenAI Codex CLI? 🤔

@Maxiviper117
Copy link

Maxiviper117 commented Jul 4, 2025

Ya currently for me, I have to remove the tools line else it does not use the tools as expected

@jeankvd
Copy link

jeankvd commented Jul 4, 2025

Ya currently for me, I have to remove the tools line else it does not use the tools as expected

@Maxiviper117 Don't remove it, you can just copy and paste the whole Raw text from here. I got tripped up by that too but just include the tools like the file at the top, markdown makes it look like a table.

Burke thank you for listening to feedback, the "modes" changes are extremely appreciated after the premium requests change, agent mode feels usable again

@alfzki
Copy link

alfzki commented Jul 5, 2025

Weirdly enough sometimes GPT 4.1 will terminate the turn while insisting that it does not

@Kyazs
Copy link

Kyazs commented Jul 5, 2025

Ya currently for me, I have to remove the tools line else it does not use the tools as expected

@Maxiviper117 Don't remove it, you can just copy and paste the whole Raw text from here. I got tripped up by that too but just include the tools like the file at the top, markdown makes it look like a table.

Burke thank you for listening to feedback, the "modes" changes are extremely appreciated after the premium requests change, agent mode feels usable again

please elaborate more, if i dont remove the tools: {}, the mode fails to edit, because it does not have access on tools. not unless removed in the file.

image

@Maxiviper117
Copy link

Maxiviper117 commented Jul 5, 2025

Ya currently for me, I have to remove the tools line else it does not use the tools as expected

@Maxiviper117 Don't remove it, you can just copy and paste the whole Raw text from here. I got tripped up by that too but just include the tools like the file at the top, markdown makes it look like a table.

Burke thank you for listening to feedback, the "modes" changes are extremely appreciated after the premium requests change, agent mode feels usable again

@jeankvd
Mine works with no tool line currently, it's able to use any tool.

If I add the tool line it says its going to make edits but never does.

image

@voidfnc
Copy link

voidfnc commented Jul 7, 2025

Ya currently for me, I have to remove the tools line else it does not use the tools as expected

@Maxiviper117 Don't remove it, you can just copy and paste the whole Raw text from here. I got tripped up by that too but just include the tools like the file at the top, markdown makes it look like a table.
Burke thank you for listening to feedback, the "modes" changes are extremely appreciated after the premium requests change, agent mode feels usable again

please elaborate more, if i dont remove the tools: {}, the mode fails to edit, because it does not have access on tools. not unless removed in the file.

image

I removed tools line in my beastmode as well and no issues, it is making changes / writing.
image

@hellojinwoo
Copy link

hellojinwoo commented Jul 7, 2025

@burkeholland I can edit the file through github copilot using your instruction file as a custom chat mode, with the following line as well:

tools: ['changes', 'codebase', 'editFiles', 'extensions', 'fetch', 'findTestFiles', 'githubRepo', 'new', 'openSimpleBrowser', 'problems', 'readCellOutput', 'runCommands', 'runNotebooks', 'runTasks', 'runTests', 'search', 'searchResults', 'terminalLastCommand', 'terminalSelection', 'testFailure', 'updateUserPreferences', 'usages', 'vscodeAPI']
IMPORTANT: There is currently a bug in VS Code Insiders where if you do not have the tools specified in the frontmatter, the mode will have access to no tools and will do nothing. For now, I am including the built-in tools in the front matter. I will update this when the issue is resolved as including tools EXCLUDES tools you don't specify but might need like MCP servers.

This is aligned with what @voidfnc said. Would you like to consider deleting this line? For your info, my VSCode insider version is

Version: 1.102.0-insider (Universal)
Commit: 96f1890d08080f46f3b0a9424553422f04133090
Date: 2025-07-04T15:15:02.963Z (2 days ago)

@vinicius-oa
Copy link

@IP050 comment works like a charm

@yoriichi-07
Copy link

@IP050 removing the [] completely worked, thanks a lot!!

@SHJordan
Copy link

SHJordan commented Jul 8, 2025

Because of:

I think custom mode only are avaible in Insiders (like the test version of vscode), so you install that or you wait.:

As well as for clarity, combined with the fact that Claude Sonnet is making many people go insane today and to save you some time of figuring it out:

In latest default Visual Studio Code

You configure a mode in Chat > ... > configure modes

image

Then select it here:

image

Currently completely removing the tools: [] line is necessary to make it work correctly (i.e prevent stuff like mentioned by @doggy8088

In the new version, each step requires me to input go on for it to continue executing. Is there a way to make it automatically execute until all the TODO items are completed?

image

For me the missing tools are readCellOutput and updateUserPreferences

This current tools list:

tools: ['changes', 'codebase', 'editFiles', 'extensions', 'fetch', 'findTestFiles', 'githubRepo', 'new', 'openSimpleBrowser', 'problems', 'readCellOutput', 'runCommands', 'runNotebooks', 'runTasks', 'runTests', 'search', 'searchResults', 'terminalLastCommand', 'terminalSelection', 'testFailure', 'updateUserPreferences', 'usages', 'vscodeAPI']

and this is mine after i've manually enabled all tools by hitting the checkbox:

tools: ['changes', 'codebase', 'editFiles', 'extensions', 'fetch', 'findTestFiles', 'githubRepo', 'new', 'openSimpleBrowser', 'problems', 'runCommands', 'runNotebooks', 'runTasks', 'runTests', 'search', 'searchResults', 'terminalLastCommand', 'terminalSelection', 'testFailure', 'usages', 'vscodeAPI', 'context7', 'git', 'memory', 'playwright', 'sequentialthinking', 'promptBoost', 'activePullRequest', 'copilotCodingAgent']

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment