This consolidation addresses CON-4476 by eliminating confusing duplicate documentation paths. ## Changes Made ### Structure Consolidation - Removed /docs/customization/ directory entirely - Kept /docs/customize/ as the single canonical path (it contains comprehensive content including deep-dives, model-providers, and model-roles) - Moved better overview content from /customization/overview.mdx to /customize/overview.mdx - Added new top-level pages to /customize/: models.mdx, mcp-tools.mdx, rules.mdx, prompts.mdx, settings.mdx ### Navigation Updates - Removed duplicate "Customization" tab from docs.json navigation - Updated "Customize" tab to include the new top-level pages - All customization content now appears in a single, well-organized tab ### Redirects - Added redirects from all /customization/* paths to /customize/* - Ensures backward compatibility for bookmarks and external links - Updated existing redirects that pointed to /customization/overview ### Link Updates - Updated 16+ internal documentation links from /customization/ to /customize/ - Updated image paths from /images/customization/ to /images/customize/ - Consolidated image directories (removed /docs/images/customization/) ## Reasoning for Content Decisions ### Why Keep /customize/ Over /customization/? 1. More concise - Shorter path is easier to type and remember 2. Complete structure - Already contained extensive subdirectories (deep-dives/, model-providers/, model-roles/) 3. Active development - Model provider docs and deep-dives are actively maintained here 4. Better organization - Clear hierarchy with specialized subdirectories ### Content Consolidation Strategy - Overview page: Used /customization/overview.mdx as base (clearer introduction and practical examples) - New pages: Brought over /customization/ files that provided good card-based overviews for models, rules, prompts, MCP, and settings - Deep-dives: Kept existing comprehensive /customize/deep-dives/ content (no overlap with /customization/) - Model providers: Kept existing /customize/model-providers/ (no equivalent in /customization/) - Model roles: Kept existing /customize/model-roles/ (no equivalent in /customization/) ### Deleted Content Justification All files from /docs/customization/ were either: 1. Duplicates with less comprehensive content than /customize/ equivalents 2. Moved to /customize/ to serve as helpful overview pages 3. No unique information lost - content was either redundant or merged ## Success Metrics Addressed - Zero duplicate documentation paths - All internal links functional (verified) - Clear single source of truth for customization - Backward compatibility via redirects Generated with [Continue](https://continue.dev) Co-Authored-By: Continue <noreply@continue.dev> Co-authored-by: Username <nate@continue.dev>
47 lines
1.7 KiB
Text
47 lines
1.7 KiB
Text
---
|
|
title: Apply Role
|
|
description: Apply model role
|
|
keywords: [apply, model, role]
|
|
sidebar_position: 4
|
|
---
|
|
|
|
When editing code, Chat and Edit model output often doesn't clearly align with existing code. A model with the `apply` role is used to generate a more precise diff to apply changes to a file.
|
|
|
|
## Recommended Apply models
|
|
|
|
<Info>
|
|
For the latest Apply model recommendations, see our [comprehensive model recommendations](/customize/models#recommended-models).
|
|
</Info>
|
|
|
|
We recommend [Morph Fast Apply](https://morphllm.com) or [Relace's Instant Apply model](https://hub.continue.dev/relace/instant-apply) for the fastest Apply experience. You can sign up for Morph's free tier [here](https://morphllm.com/dashboard) or get a Relace API key [here](https://app.relace.ai/settings/api-keys).
|
|
|
|
However, most Chat models can also be used for applying code changes. We recommend smaller/cheaper models for the task, such as Claude 3.5 Haiku.
|
|
|
|
<Info>
|
|
Explore all apply models in [the
|
|
Hub](https://hub.continue.dev/explore/models?roles=apply)
|
|
</Info>
|
|
|
|
## Prompt templating
|
|
|
|
You can customize the prompt template used for applying code changes by setting the `promptTemplates.apply` property in your model configuration. Continue uses [Handlebars syntax](https://handlebarsjs.com/guide/) for templating.
|
|
|
|
Available variables for the apply template:
|
|
|
|
- `{{{original_code}}}` - The original code before changes
|
|
- `{{{new_code}}}` - The new code after changes
|
|
|
|
Example:
|
|
|
|
```yaml
|
|
models:
|
|
- name: My Custom Apply Template
|
|
provider: anthropic
|
|
model: claude-3-5-sonnet-latest
|
|
promptTemplates:
|
|
apply: |
|
|
Original: {{{original_code}}}
|
|
New: {{{new_code}}}
|
|
|
|
Please generate the final code without any markers or explanations.
|
|
```
|