Skip to main content

Customizing Prompt Templates

goose comes with built-in prompt templates that guide its behavior in different situations. You can edit these templates to customize how goose responds, creates plans, decides what to save during compaction, and more.

How It Works

goose's default prompt templates are defined in the codebase and embedded in the application. You can override any default by creating a custom version in your local config directory (either directly or via goose Desktop).

When you customize a template:

  • Your customizations persist across goose updates
  • Changes to defaults in the codebase don't affect your customized templates
  • You can reset to default templates at any time
  • Changes take effect in new sessions

Your changes can range from major updates to minor adjustments such as:

  • Edit system.md to have goose respond in Dutch by adding an instruction to "Reply in Dutch"
  • Edit plan.md to add time estimates by adding instructions to "Include an estimated time for each step (e.g., "~5 min", "~30 min", "~2 hours")."

See Template Variable Syntax for important information about modifying template variables.

Related Configuration

Other goose settings and features can also affect behavior or provide context, such as config files, .goosehints, and skills.

Managing Prompt Templates

goose Desktop users can manage templates from the Settings page.

To customize a template:

  1. Click the button in the top-left to open the sidebar
  2. Click Settings in the sidebar
  3. Click the Prompts tab
  4. Click Edit next to the template you want to change
  5. Make your changes in the editor. You can click Restore Default to start over from the default template at any time.
  6. Click Save to apply your customization

Customized prompt templates display a Customized badge.

To reset a template to its default:

  1. Click the button in the top-left to open the sidebar
  2. Click Settings in the sidebar
  3. Click the Prompts tab
  4. Click Edit next to the template you want to reset
  5. Click Reset to Default to delete your local template file

Or click Reset All at the top of the tab to delete all of your local template files.

Available Prompt Templates

The following default templates can be customized.

TemplateDescriptionApplies To
system.mdGeneral system prompt defining goose's role, capabilities, and response formatDesktop and CLI
apps_create.mdPrompt for generating new standalone apps (in development)Desktop only
apps_iterate.mdPrompt for updating existing standalone apps (in development)Desktop only
compaction.mdPrompt for summarizing conversation history when context limits are reachedDesktop and CLI
desktop_prompt.mdContext about the user interface and available featuresDesktop only
desktop_recipe_instruction.mdInstructions for executing recipesDesktop only
permission_judge.mdPrompt for analyzing tool operations for read-only detectionDesktop and CLI
plan.mdInstructions for creating detailed, actionable plans with clarifying questionsCLI only
recipe.mdPrompt for generating recipe files from conversationsDesktop and CLI
subagent_system.mdSystem prompt for subagents spawned to handle specific tasksDesktop and CLI

Customizable templates are enumerated in the TEMPLATE_REGISTRY array in prompt_template.rs.

Template Variable Syntax

Templates use Jinja2 syntax for dynamic content:

  • {{ variable }} - Inserts a value (e.g., {{ extensions }} lists enabled extensions)
  • {% if condition %}...{% endif %} - Conditional sections
  • {% for item in list %}...{% endfor %} - Loops over items

Check out the default templates (linked to from the table above) to find common variables, such as {{ extensions }} and {{ hints }}.

warning

Be careful when modifying template variables, as incorrect changes can break functionality. Test your changes in a new session to ensure they work as expected.

Additional Resources