# Output Styles

> Adapt Claude Code for uses beyond software engineering

Output styles allow you to use Claude Code as any type of agent while keeping its core capabilities, such as running local scripts, reading/writing files, and tracking TODOs.

## Built-in Output Styles

### Default
The existing system prompt, designed to help you complete software engineering tasks efficiently.

### Explanatory
Provides educational "Insights" in between helping you complete software engineering tasks. Helps you understand implementation choices and codebase patterns.

### Learning
Collaborative, learn-by-doing mode where Claude will not only share "Insights" while coding, but also ask you to contribute small, strategic pieces of code yourself. Claude Code will add `TODO(human)` markers in your code for you to implement.

## How Output Styles Work

Output styles directly modify Claude Code's system prompt:

- All output styles exclude instructions for efficient output (such as responding concisely).
- Custom output styles exclude instructions for coding (such as verifying code with tests), unless `keep-coding-instructions` is true.
- All output styles have their own custom instructions added to the end of the system prompt.
- All output styles trigger reminders for Claude to adhere to the output style instructions during the conversation.

## Changing Your Output Style

### Interactive Method
Run `/output-style` to access a menu and select your output style (this can also be accessed from the `/config` menu).

### Direct Method
Run `/output-style [style]`:
```
/output-style explanatory
```

These changes apply to the local project level and are saved in `.claude/settings.local.json`. You can also directly edit the `outputStyle` field in a settings file at a different level.

## Creating a Custom Output Style

Custom output styles are Markdown files with frontmatter and the text that will be added to the system prompt:

```markdown
---
name: My Custom Style
description:
  A brief description of what this style does, to be displayed to the user
---

# Custom Style Instructions

You are an interactive CLI tool that helps users with software engineering
tasks. [Your custom instructions here...]

## Specific Behaviors

[Define how the assistant should behave in this style...]
```

### Storage Locations

- **User level**: `~/.claude/output-styles`
- **Project level**: `.claude/output-styles`

### Frontmatter Options

| Frontmatter                | Purpose                                                                     | Default                 |
| :------------------------- | :-------------------------------------------------------------------------- | :---------------------- |
| `name`                     | Name of the output style, if not the file name                              | Inherits from file name |
| `description`              | Description of the output style. Used only in the UI of `/output-style`     | None                    |
| `keep-coding-instructions` | Whether to keep the parts of Claude Code's system prompt related to coding. | false                   |

## Comparisons to Related Features

### Output Styles vs. CLAUDE.md vs. --append-system-prompt

Output styles completely "turn off" the parts of Claude Code's default system prompt specific to software engineering.

- **CLAUDE.md** adds contents as a user message *following* Claude Code's default system prompt.
- **`--append-system-prompt`** appends content to the system prompt.

Neither edits Claude Code's default system prompt like output styles do.

### Output Styles vs. Agents

- **Output styles** directly affect the main agent loop and only affect the system prompt.
- **Agents** are invoked to handle specific tasks and can include additional settings like the model to use, the tools they have available, and context about when to use the agent.

### Output Styles vs. Skills

- **Output styles** modify how Claude responds (formatting, tone, structure) and are always active once selected.
- **Skills** are task-specific prompts that you invoke with `/skill-name` or that Claude loads automatically when relevant.

Use output styles for consistent formatting preferences; use skills for reusable workflows and tasks.

## Example: Technical Writer Style

```markdown
---
name: Technical Writer
description: Focuses on documentation, explanation, and clear communication
keep-coding-instructions: false
---

# Technical Writer Mode

You are a technical writer assistant. Your primary focus is on:

1. **Documentation**: Create clear, comprehensive documentation
2. **Explanation**: Break down complex concepts into understandable parts
3. **Communication**: Use precise, jargon-free language when possible
4. **Structure**: Organize information logically with proper headings

## Response Format

- Use markdown formatting extensively
- Include code examples when relevant
- Add diagrams or ASCII art when helpful
- Always explain the "why" behind technical decisions
```

## Example: Code Review Style

```markdown
---
name: Code Reviewer
description: Systematic code review with security and best practices focus
keep-coding-instructions: true
---

# Code Review Mode

You are a senior code reviewer. For every code change:

1. **Security**: Check for vulnerabilities and data exposure
2. **Performance**: Identify potential bottlenecks
3. **Maintainability**: Assess code clarity and documentation
4. **Testing**: Verify adequate test coverage

## Review Format

Always provide:
- Summary of changes
- Critical issues (must fix)
- Suggestions (nice to have)
- Questions for the author
```

## Grid Integration Opportunities

<!-- Placeholder for Grid-specific integration notes -->
