Before You Start
Make sure you have:- ✅ Installed Elastic Copilot
- ✅ Completed authentication
- ✅ A code project open in VSCode
1. Meet Your AI Assistant (1 minute)
Let’s start with a simple conversation:1
Open Elastic Copilot
Click the Elastic Copilot icon in VSCode’s sidebar (or press
Ctrl+Shift+E)2
Say Hello
Type “Hello! Can you help me understand this project?” in the chat
3
Watch the Magic
Elastic Copilot will analyze your project and provide insights about its structure and purpose
2. AI Commands in Action (2 minutes)
The fastest way to get help with your code:Explain Code
1
Select Code
Highlight any function or code block in your editor
2
Use Command
Press
Ctrl+L (or right-click → “Elastic: Explain”)3
Get Explanation
Elastic Copilot will provide a clear explanation of what the code does
Fix Issues
1
Find an Error
Look for red squiggly lines indicating errors in your code
2
Select Problem Area
Highlight the problematic code
3
Get Fix
Press
Ctrl+Shift+F (or right-click → “Elastic: Fix”)4
Review Solution
Elastic Copilot will suggest a fix with explanation
Improve Code
1
Select Code to Improve
Highlight code that could be optimized
2
Request Improvements
Press
Ctrl+I (or right-click → “Elastic: Improve”)3
See Suggestions
Get suggestions for performance, readability, or best practices
3. Smart Code Completion (1 minute)
Experience AI-powered autocomplete:1
Start Typing
Begin writing a new function or class
2
Watch for Suggestions
Elastic Copilot will suggest completions as you type
3
Accept or Dismiss
Press
Tab to accept suggestions or Esc to dismiss4. Context-Aware Chat (1 minute)
Have a conversation about your code:Ask About Files
“@filename.js What does this file do?”
Request Features
“Add a new user authentication system”
Debug Issues
“Why is my API call failing?”
Get Recommendations
“How can I improve this component’s performance?”
Try This Chat Examples:
Essential Keyboard Shortcuts
AI Commands
Ctrl+L- Explain selected codeCtrl+Shift+F- Fix selected codeCtrl+I- Improve selected codeCtrl+Shift+E- Open Elastic panel
Code Completion
Tab- Accept suggestionEsc- Dismiss suggestionCtrl+Space- Trigger completionAlt+]- Next suggestion
Quick Wins for Your Workflow
Now that you know the basics, here are some immediate ways to boost your productivity:Document Your Code
Document Your Code
Select any function and ask: “Add comprehensive JSDoc comments to this function”
Write Tests
Write Tests
Highlight a function and ask: “Create unit tests for this function using Jest”
Refactor Legacy Code
Refactor Legacy Code
Select old code and ask: “Modernize this code using current best practices”
Code Reviews
Code Reviews
Paste code and ask: “Review this code for security vulnerabilities and performance issues”