AI Assistance
DojoCode includes a built-in AI assistant available directly in the challenge editor via the Chat tab. It helps you learn, get unstuck, and — when you're ready — write code. The assistant supports two modes: Understand and Implement.

Fig. 1 - The Chat panel
Getting started
To open the AI assistant, click the Chat tab in the action area (next to Description, Preview, and API Tester). The chat panel will appear, ready for your questions or instructions.
Understand mode
Understand mode is your learning companion. It helps you grasp new coding concepts, gives you hints for the current challenge, and explains why your tests might be failing — all without writing code for you.
What you can do
- Ask for hints about the challenge approach
- Get explanations of coding concepts, data structures, or algorithms
- Understand why your tests are failing (ties into the AI Test Explanations feature)
- Ask about language-specific syntax or patterns
Example prompts
- "Give me a hint"
- "Explain the challenge to me"
- "Why is my test failing?"
- "What data structure should I use for this?"
Implement mode
Implement mode is the agent mode. The AI can read your existing code and write directly in the editor. You provide the instructions — think of it as prompt engineering — and the AI handles the implementation.
What you can do
- Ask the AI to write or modify code in your editor
- Request implementations of specific functions or components
- Get refactoring suggestions applied directly
- Fix bugs based on your description
Example prompts
- "Refactor my code to use a more efficient algorithm"
- "Add error handling to my function"
- "Fix the bug in my implementation"
WARNING
AI Assistance usage affects your challenge score. Each AI prompt reduces your score by 3%. Try solving challenges on your own first for the best score. See how scoring works.
Switching between modes
You can switch between Understand and Implement at any time from the mode selector in the Chat panel.
Voice commands
You can interact with the AI assistant hands-free using voice commands:
- Click the microphone icon to start speaking
- The AI will process your speech and respond accordingly
- Make sure your microphone is enabled and functioning
Keyboard shortcuts
| Shortcut | Action |
|---|---|
| Ctrl + Alt + V | Toggle between voice and text mode |
| Ctrl + M | Enable/toggle microphone |
See all keyboard shortcuts.
Tips
- Start with Understand mode to learn the concept before jumping to Implement — you'll learn more
- Be specific in your prompts for better AI responses
- Use Understand mode to ask about failing tests before asking the AI to fix them
- Fewer AI prompts = higher challenge score