Chat vs Inline vs Agent Mode: How AI Coding Modes Work
Every AI coding tool has three ways to help you. Inline finishes your line. Chat answers your question. Agent does a whole task. Pick the right one and you work faster.
In short: use inline for small code, chat for questions and bigger blocks, and agent for multi-file tasks that you review step by step.
Why the mode matters
The wrong mode wastes time and tokens. Asking an agent to rename one variable is slow. Waiting for inline to write a whole feature does not work. Each mode has a job.
What each mode is
- Inline (autocomplete): faint grey “ghost text” appears as you type. Tab accepts it. Esc rejects it.
- Next edit suggestion: the tool guesses your next change somewhere else in the file. GitHub Copilot calls it next edit suggestions.
- Chat: a side panel. You ask in plain words. It explains code or writes a block for you to paste or apply.
- Inline chat: a small chat box right inside the editor (Ctrl+I in VS Code with Copilot). Good for “fix this function”.
- Agent: you give a goal. It plans, edits many files and runs commands like tests. It asks for approval on risky steps.
- Plan mode: the agent only describes what it will do. Nothing changes until you approve. Claude Code and Copilot both have it.
How the three modes flow
How to pick a mode
- Writing one line or a small loop? Use inline. Type a clear function name or comment, wait, press Tab.
- Need to understand code or an error? Use chat. Select the code first, then ask “explain this in simple words”.
- Changing one function? Use inline chat. Select it, press Ctrl+I, type “add input checks”.
- Task touches many files (new API route + test + docs)? Use plan mode first, read the plan, then let the agent run.
- Always review the diff the agent shows. Accept only what you understand. Run the tests yourself.
Same task in three modes (example)
Task: add a is_even(n) helper to a Python, JavaScript or Java project.
| Mode | What you do | What you get |
|---|---|---|
| Inline | Type def is_even(n): and wait | Ghost text return n % 2 == 0; press Tab |
| Chat | Ask “write is_even in Java with a JUnit test” | A method + a test class to copy |
| Agent | Ask “add is_even to utils, add a test, run the tests” | Edited files + test run, waiting for your approval |
Where to find each mode (setup check)
- GitHub Copilot in VS Code: inline is on after sign-in. Chat: the chat icon in the title bar or Ctrl+Alt+I. Pick Ask or Agent (and Plan, where shown) from the mode list in the chat box.
- Claude Code in VS Code: chat and agent in one panel (Spark icon). Switch Manual, Plan, Auto or Edit automatically at the bottom of the prompt box. It has no grey inline autocomplete.
- Copilot in IntelliJ: inline after login. Chat tool window on the right side. Agent mode is in the chat mode list.
- Settings tip: if inline ghost text distracts you, turn it off per language in the tool settings and keep chat.
Quick quiz
1. Which mode shows grey ghost text?
Inline (autocomplete). Tab accepts it.
2. You want the AI to explain an error. Which mode?
Chat. Paste or select the error and ask.
3. Which mode can edit many files and run tests?
Agent mode.
4. What does plan mode do?
It shows the steps first. Nothing changes until you approve.
Save tokens and money
Inline is the cheapest help. Chat costs more. Agent costs the most, because it reads many files and loops. Use the smallest mode that does the job. Start a new chat for a new task, so old history is not re-sent.