Skip to content

Code Completions SOP

Fresh

Inline completions and Next Edit Predictions for faster coding.

Standard Completions

Gemini suggests completions automatically as you type.

mermaid
flowchart LR
    A[Start typing] --> B[Ghost text suggestion appears]
    B --> C{Decision}
    C -->|Accept| D[Press Tab]
    C -->|Reject| E[Press Esc or keep typing]

Accept: TabDismiss: Esc or continue typing to ignore

Next Edit Predictions

Goes beyond the cursor — suggests changes throughout the file even in other locations.

Enable in VS Code

  1. Settings > Extensions > Gemini Code Assist
  2. Find Next Edit Predictions checkbox
  3. Enable it

Enable in IntelliJ

  1. File > Settings > Tools > Gemini
  2. Completion section > check Next Edit Predictions

Using Next Edit Predictions

  1. Write code — predictions appear when you pause typing
  2. Press Tab to accept a prediction
  3. Press Tab again for the next suggestion
  4. Press Esc to dismiss (stops for that code block)

INFO

When multiple suggestions exist, hover over a suggestion to see alternatives and use arrow keys to cycle through them.

Disable Completions

VS Code:

  • Settings > Extensions > Gemini Code Assist > Inline Suggestions: Enable Auto > Off
  • OR: Click spark status bar > Disable AI Code Completion

IntelliJ:

  • Click spark status bar > Enable AI Code Completion (toggle)

Exclude Files from Context

Create .aiexclude in your project root:

# Exclude secrets
.env
secrets/
credentials.json

# Exclude generated files
dist/
build/
*.generated.ts
node_modules/

Gemini also respects .gitignore patterns automatically.

Disable Cited Code Suggestions

To prevent suggestions that match open source code:

VS Code: Settings > Gemini Code Assist > Recitation: Max Cited Length > set to 0

IntelliJ: spark status bar > Configure Gemini > Advanced settings > Block selections that match external cited sources

Based on official Google Gemini Code Assist documentation.