cursor-model-selection
Configure and select AI models in Cursor for Chat, Composer, and Agent mode. Triggers on "cursor model", "cursor gpt", "cursor claude", "change cursor model", "cursor ai model", "cursor auto mode".
What this skill does
# Cursor Model Selection
Configure AI models for Chat, Composer, and Agent mode. Cursor supports models from OpenAI, Anthropic, Google, and its own proprietary models. Choosing the right model per task is a major productivity lever.
## Available Models
### Included with Cursor Subscription
| Model | Provider | Best For | Context |
|-------|----------|----------|---------|
| **GPT-4o** | OpenAI | General coding, fast responses | 128K |
| **GPT-4o-mini** | OpenAI | Simple tasks, cost-efficient | 128K |
| **Claude Sonnet** | Anthropic | Code quality, detailed explanations | 200K |
| **Claude Haiku** | Anthropic | Fast simple tasks | 200K |
| **cursor-small** | Cursor | Quick completions, simple edits | 8K |
| **Auto** | Cursor | Automatic model selection per query | Varies |
### Premium Models (count against fast request quota)
| Model | Provider | Best For | Context |
|-------|----------|----------|---------|
| **Claude Opus** | Anthropic | Complex architecture, hard bugs | 200K |
| **GPT-5** | OpenAI | Advanced reasoning, complex code | 128K+ |
| **o1 / o3** | OpenAI | Deep reasoning, mathematical logic | 128K |
| **Gemini 2.5 Pro** | Google | Design, large context analysis | 1M |
## Model Selection by Task
### Quick Reference
```
Bug fix in one file → GPT-4o or Claude Sonnet
Multi-file refactoring → Claude Sonnet or Opus
Architecture planning → Claude Opus or GPT-5
Test generation → GPT-4o (fast + good patterns)
Complex algorithm design → o1/o3 reasoning models
Large codebase analysis → Gemini 2.5 Pro (1M context)
Simple autocomplete → cursor-small (automatic via Tab)
"I don't know" → Auto mode
```
### How to Switch Models
**Per conversation:** Click the model name in the top-right of Chat or Composer panel.
**Default model:** `Cursor Settings` > `Models` > set default for Chat and Composer separately.
**Auto mode:** Select "Auto" as the model. Cursor picks the best model per query based on complexity and current server load.
## Bring Your Own Key (BYOK)
Use your own API keys to bypass Cursor's quota system. You pay the provider directly at their rates.
### Configuration
`Cursor Settings` > `Models` > enable `Use own API key`:
**OpenAI:**
```
API Key: sk-proj-xxxxxxxxxxxxxxxxxxxx
```
**Anthropic:**
```
API Key: sk-ant-xxxxxxxxxxxxxxxxxxxx
```
**Google (Gemini):**
```
API Key: AIzaSyxxxxxxxxxxxxxxxxxxxxxxxxx
```
### Azure OpenAI
For enterprise Azure deployments:
```
Cursor Settings > Models > Azure:
API Key: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Endpoint: https://my-instance.openai.azure.com
Deployment: gpt-4o-deployment-name
API Version: 2024-10-21
```
### Adding Custom Models
For OpenAI-compatible providers (Ollama, LM Studio, Together AI):
1. `Cursor Settings` > `Models` > `Add Model`
2. Enter model name (e.g., `llama-3.1-70b`)
3. Enable `Override OpenAI Base URL`
4. Enter base URL: `http://localhost:11434/v1` (Ollama) or provider URL
5. Enter API key if required
### BYOK Limitations
| Feature | Uses BYOK Key? | Uses Cursor Model? |
|---------|---------------|-------------------|
| Chat | Yes | -- |
| Composer | Yes | -- |
| Agent mode | Yes | -- |
| **Tab Completion** | **No** | **Always Cursor model** |
| **Apply from Chat** | **No** | **Always Cursor model** |
Tab Completion always uses Cursor's proprietary model regardless of BYOK configuration.
## Cost Optimization Strategies
### Tiered Model Usage
```
Tier 1 (Fast + Cheap): cursor-small, GPT-4o-mini, Claude Haiku
Use for: simple questions, syntax help, boilerplate
Tier 2 (Balanced): GPT-4o, Claude Sonnet
Use for: most coding tasks, debugging, refactoring
Tier 3 (Premium): Claude Opus, GPT-5, o1/o3
Use for: architecture decisions, critical bugs, complex logic
```
### Quota Management
Cursor subscription includes a monthly quota of "fast requests" (premium model uses). When exceeded, requests queue behind other users ("slow requests").
- Check remaining quota: `cursor.com/settings` > Usage
- Pro plan: ~500 fast requests/month
- Business plan: ~500 fast requests/month per seat
### Tips to Reduce Usage
1. Use Auto mode -- it picks cheaper models when they suffice
2. Start with Sonnet/GPT-4o, escalate to Opus/o1 only if needed
3. Write detailed prompts to avoid back-and-forth (fewer requests)
4. Use BYOK for heavy usage -- pay per token instead of per request
## Model Behavior Differences
### Code Generation Style
```python
# Claude models: Verbose, well-documented, defensive
def process_order(order: Order) -> Result[ProcessedOrder, OrderError]:
"""Process an order through the payment and fulfillment pipeline.
Args:
order: The order to process.
Returns:
Result containing the processed order or an error.
Raises:
Never raises -- errors returned as Result.Err.
"""
if not order.items:
return Err(OrderError.EMPTY_ORDER)
...
# GPT models: Concise, pragmatic, fewer comments
def process_order(order: Order) -> ProcessedOrder:
if not order.items:
raise ValueError("Order has no items")
...
```
### Reasoning Models (o1, o3)
These models "think" before responding. They are slower but significantly better at:
- Multi-step logic problems
- Finding subtle bugs in complex code
- Mathematical or algorithmic optimization
- Understanding implicit requirements
They are overkill for simple tasks. Use them deliberately for hard problems.
## Enterprise Considerations
- **Model access control**: Admins can restrict which models team members access via the admin dashboard
- **Spending limits**: Set per-user or per-team spending caps when using BYOK
- **Compliance**: Some models route through different providers -- verify data handling per model
- **Azure preference**: Enterprise teams on Azure can route all requests through their own Azure OpenAI deployments
- **Audit**: Model selection per request is visible in usage analytics (Business/Enterprise plans)
## Resources
- [Cursor Models Documentation](https://docs.cursor.com/settings/models)
- [API Key Configuration](https://docs.cursor.com/advanced/api-keys)
- [Pricing and Plans](https://cursor.com/pricing)
Related in AI Agents
skill-development
IncludedComprehensive meta-skill for creating, managing, validating, auditing, and distributing Claude Code skills and slash commands (unified in v2.1.3+). Provides skill templates, creation workflows, validation patterns, audit checklists, naming conventions, YAML frontmatter guidance, progressive disclosure examples, and best practices lookup. Use when creating new skills, validating existing skills, auditing skill quality, understanding skill architecture, needing skill templates, learning about YAML frontmatter requirements, progressive disclosure patterns, tool restrictions (allowed-tools), skill composition, skill naming conventions, troubleshooting skill activation issues, creating custom slash commands, configuring command frontmatter, using command arguments ($ARGUMENTS, $1, $2), bash execution in commands, file references in commands, command namespacing, plugin commands, MCP slash commands, Skill tool configuration, or deciding between skills vs slash commands. Delegates to docs-management skill for official documentation.
reprompter
IncludedTransform messy prompts into well-structured, effective prompts — single or multi-agent. Use when: "reprompt", "reprompt this", "clean up this prompt", "structure my prompt", rough text needing XML tags and best practices, "reprompter teams", "repromptception", "run with quality", "smart run", "smart agents", multi-agent tasks, audits, parallel work, anything going to agent teams. Don't use when: simple Q&A, pure chat, immediate execution-only tasks. See "Don't Use When" section for details. Outputs: Structured XML/Markdown prompt, quality score (before/after), optional team brief + per-agent sub-prompts, agent team output files. Success criteria: Single mode quality score ≥ 7/10; Repromptception per-agent prompt quality score 8+/10; all required sections present, actionable and specific.
adaptive-compaction
IncludedAdaptive add-on policy and recovery layer that decides WHEN to compact, prune, snapshot, or fork -- replacing fixed-percent auto-compaction across Claude Code, Codex, and MCP-capable hosts. Trigger on auto-compact timing or damage: "when should I compact", "is it safe to compact now or start a fresh session", "auto-compact fires too early/mid-task", "switching to an unrelated task but the window still has space", "context rot", "answers get worse the longer the session runs", "the agent forgot the plan or my decisions after it summarized", "add a layer on top that manages context without changing the agent", raising autoCompactWindow to give the policy room, or installing/tuning a cross-tool compaction policy or PreCompact hook -- even when "compaction" is never said but the problem is context-window pressure or post-summarization memory loss. Do NOT use to summarize a conversation, build RAG, write a summarization prompt (decides WHEN not HOW), or answer max-context-length trivia.
agent-skill-creator
IncludedCreate cross-platform agent skills from workflow descriptions. Activates when users ask to create an agent, automate a repetitive workflow, create a custom skill, or need advanced agent creation. Triggers on phrases like create agent for, automate workflow, create skill for, every day I have to, daily I need to, turn process into agent, need to automate, create a cross-platform skill, validate this skill, export this skill, migrate this skill. Supports single skills, multi-agent suites, transcript processing, template-based creation, interactive configuration, cross-platform export, and spec validation.
llm-wiki
IncludedUse when building or maintaining a persistent personal knowledge base (second brain) in Obsidian where an LLM incrementally ingests sources, updates entity/concept pages, maintains cross-references, and keeps a synthesis current. Triggers include "second brain", "Obsidian wiki", "personal knowledge management", "ingest this paper/article/book", "build a research wiki", "compound knowledge", "Memex", or whenever the user wants knowledge to accumulate across sessions instead of being re-derived by RAG on every query.
skill-master
IncludedAgent Skills authoring, evaluation, and optimization. Create, edit, validate, benchmark, and improve skills following the agentskills.io specification. Use when designing SKILL.md files, structuring skill folders (references, scripts, assets), ingesting external documentation into skills, running trigger evals, benchmarking skill quality, optimizing descriptions, or performing blind A/B comparisons. Keywords: agentskills.io, SKILL.md, skill authoring, eval, benchmark, trigger optimization.