Welcome to Elastic Copilot! This guide will get you up and running in just 5 minutes. Follow along to learn the essential features and see the power of AI-assisted coding.

Before You Start

Make sure you have:

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
Elastic Copilot automatically understands your codebase through intelligent analysis - no manual setup required!

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 dismiss
Example - try typing this in a JavaScript file:
function calculateTotal(items) {
  // Start typing and watch for AI suggestions

}

4. 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:

"@package.json What dependencies are we using?"

"Create a new React component for a user profile card"

"How do I add error handling to this function?"

"Explain the difference between these two approaches"

Essential Keyboard Shortcuts

AI Commands

  • Ctrl+L - Explain selected code
  • Ctrl+Shift+F - Fix selected code
  • Ctrl+I - Improve selected code
  • Ctrl+Shift+E - Open Elastic panel

Code Completion

  • Tab - Accept suggestion
  • Esc - Dismiss suggestion
  • Ctrl+Space - Trigger completion
  • Alt+] - Next suggestion

Quick Wins for Your Workflow

Now that you know the basics, here are some immediate ways to boost your productivity:

Pro Tips

Be Specific: Instead of “fix this”, try “fix the async/await syntax error in this function”
Use Context: Mention file names with @ to give Elastic Copilot more context about what you’re working on
Iterate: Don’t hesitate to ask follow-up questions or request modifications to suggestions
Congratulations! You’re now ready to code with AI assistance. Elastic Copilot will learn your patterns and become even more helpful over time.