Use the Gemini Code Assist chat

This document describes how to get AI-powered assistance in the Gemini Code Assist chat in your integrated development environment (IDE).

Gemini Code Assist chat lets you write natural language statements or questions (called prompts) to get in-depth explanations of your code, suggested actions, or guided workflows that help you complete tasks quickly and efficiently without leaving the IDE.

Learn how and when Gemini for Google Cloud uses your data.

Open Gemini Code Assist chat

To open Gemini Code Assist chat in the IDE:

VS Code

  1. In the activity bar of your IDE, click spark Gemini Code Assist.

  2. In the Gemini Code Assist chat, enter a prompt and then click send Send.

IntelliJ

In the Gemini Code Assist tool window, enter a prompt and then click Submit.

View query history

VS Code

Query history isn't available for VS Code.

IntelliJ

If you want to re-use your previous prompts, you can find them in your Query History in the Gemini Code Assist tool window by clicking schedule Show Query History.

Gemini Query History in the tool window.

Reset chat history

Gemini Code Assist uses the chat history for additional context when responding to your prompts. If your chat history is no longer relevant to what you're trying to achieve, you can reset the chat history:

VS Code

In the Gemini Code Assist pane, click delete Reset Chat.

IntelliJ

In the Gemini Code Assist tool window, click delete Clear Conversation History. This also clears your query history.

Button to clear conversation history in Gemini tool window.

What's next

For more information on using Gemini Code Assist in the IDE, see Code with Gemini Code Assist.