| 1 | --- |
| 2 | title: "How Chat Works" |
| 3 | description: "Continue's Chat feature provides a conversational interface with AI models directly in your IDE sidebar." |
| 4 | --- |
| 5 | |
| 6 | ## How Chat Core Functionality Works |
| 7 | |
| 8 | When you start a chat conversation, Continue: |
| 9 | |
| 10 | 1. **Gathers Context**: Uses any selected code sections and @-mentioned context |
| 11 | 2. **Constructs Prompt**: Combines your input with relevant context |
| 12 | 3. **Sends to Model**: Prompts the configured AI model for a response |
| 13 | 4. **Streams Response**: Returns the AI response in real-time to the sidebar |
| 14 | |
| 15 | ## How Context Management Works |
| 16 | |
| 17 | ### What Context Is Automatically Included |
| 18 | |
| 19 | - Selected code in your editor |
| 20 | - Current file context when relevant |
| 21 | - Previous conversation history in the session |
| 22 | |
| 23 | ### How to Add Manual Context |
| 24 | |
| 25 | - `@Files` - Reference specific files |
| 26 | |
| 27 | ## How Response Handling Works |
| 28 | |
| 29 | Each code section in the AI response includes action buttons: |
| 30 | |
| 31 | - **Apply to current file** - Replace selected code |
| 32 | - **Insert at cursor** - Add code at cursor position |
| 33 | - **Copy** - Copy code to clipboard |
| 34 | |
| 35 | ## How Session Management Works |
| 36 | |
| 37 | - Use `Cmd/Ctrl + L` (VS Code) or `Cmd/Ctrl + J` (JetBrains) to start a new session |
| 38 | - Clears all previous context for a fresh start |
| 39 | - Helpful for switching between different tasks |
| 40 | |
| 41 | ## What Advanced Features Are Available |
| 42 | |
| 43 | ### How to Use Prompt Inspection |
| 44 | |
| 45 | View the exact prompt sent to the AI model in the [prompt logs](/troubleshooting) for debugging and optimization. |
| 46 | |
| 47 | ### Context |
| 48 | |
| 49 | Learn more about how you can bring in context: |
| 50 | |
| 51 | - [Codebase Context](/guides/codebase-documentation-awareness) |
| 52 | - [Documentation Context](/guides/codebase-documentation-awareness) |
| 53 | - [Built-in Context Providers](/customize/deep-dives/custom-providers) |
| 54 | |
| 55 | --- |
| 56 | |
| 57 | _Chat is designed to feel like a natural conversation while maintaining full transparency about what context is being used._ |