# Google Gemini

You can follow the steps given below to configure Google Gemini to enable yCrash AI features.


# Step 1: Get Your Gemini API Key

Think of an API key as a password that lets yCrash talk to Google's AI on your behalf. You create it once in Google's portal and paste it into your yCrash configuration file.

# Open Google AI Studio

  1. In a web browser, go to Google AI Studio (opens new window)
  2. Sign in with your Google account (work or personal, depending on your organization's policy)

Tip for IT / procurement teams:

Some organizations require a Google Cloud project with billing enabled instead of AI Studio. If your security team blocks AI Studio, ask them to provision a Gemini API key from Google Cloud Console under APIs & Services -> Credentials. The key format and usage in yCrash are the same.

# Create an API key

  1. In AI Studio, open Get API key (or API Keys in the left navigation)
  2. Click Create API key
  3. If prompted, select or create a Google Cloud project - this is a container Google uses for billing and access control
  4. Copy the key when it is displayed

The key typically:

  • Starts with AIza
  • Is a long string of letters, numbers, and symbols
  • Is shown only once - store it somewhere secure (password manager, secrets vault) before closing the dialog

# Enable billing (if required)

Google may require billing to be enabled on the project for production API usage. Free tiers and trial credits vary by Google's current policy - check AI Studio or Cloud Console for your account's limits.

# Treat the key like a password

Do Don't
Store the key in a secrets manager or restricted server directory Email or chat the key in plain text
Restrict file permissions on ycbuddy-config.json (e.g. readable only by the yCrash service account) Commit the key to Git or share it in tickets
Rotate the key if it is ever exposed Reuse the same key across unrelated environments without tracking

# Step 2: Add the Gemini Settings

Paste the following JSON into ycbuddy-config.json and replace your-gemini-api-key with the key you copied from Google:

{
  "llmProvider": "gemini",
  "llmApiKey": "your-gemini-api-key",
  "llmModelName": "gemini-3.6-flash",
  "llmEmbeddingModelName": "gemini-embedding-001"
}
1
2
3
4
5
6

# What each field means (in plain language)

Field What it is What to put
llmProvider Which AI company yCrash should call "gemini" for Google Gemini
llmApiKey Your secret key from Google The key from Step 1 (starts with AIza...)
llmModelName The "brain" that writes chat answers "gemini-2.5-flash" (recommended). This is the model that generates RCA explanations and answers follow-up questions.
llmEmbeddingModelName A helper model for finding relevant context "gemini-embedding-001". You rarely change this. It powers semantic search over yCrash guides and conversation context - not the visible chat text itself.

Note:

If any required field is missing or empty, yCrash disables AI and logs a configuration error at startup.

You can omit llmApiKey and set LLM_API_KEY on the yCrash process instead. All other fields are still required in the JSON file.


# Supported Gemini Chat Models

yCrash recognizes these Gemini model IDs (use the exact string in llmModelName):

Model ID Best for
gemini-3.6-flash Recommended — Google’s current Gemini Developer API replacement for 2.5 Flash; default in yCrash
gemini-3.7-flash Newest Flash id; short-term availability. Use after a live smoke test if you want the latest
gemini-3.5-flash Previous 3.x Flash with a longer published support window
gemini-3.5-flash-lite Lower cost / higher throughput 3.x option
gemini-2.5-flash Previous generation; Google shutdown date 16 Oct 2026. Migrate to 3.6 Flash

If you specify an unknown model name, yCrash still runs but applies conservative token limits (128k context, no 20 MB file-ref budget).

The following IDs are shut down on the Gemini Developer API and should not be used: gemini-2.0-flash, gemini-1.5-flash, `gemini


# Step 3: Place the File and Restart

Place ycbuddy-config.json in the yCrash upload directory (opens new window) and restart the yCrash server.

Note:

Note: To check whether LLM configuration took effect successfully, refer here.


# Optional Gemini Tuning

Most teams do not need these. Add them to ycbuddy-config.json only when directed by support or performance tuning.

{
  "llmProvider": "gemini",
  "llmApiKey": "your-gemini-api-key",
  "llmModelName": "gemini-3.6-flash",
  "llmEmbeddingModelName": "gemini-embedding-001",
  "geminiMinimizeThinking": true
}
1
2
3
4
5
6
7
Field Default Purpose
geminiMinimizeThinking true Reduces internal “thinking” so the first visible tokens arrive faster. For Gemini 2.5, sends thinkingBudget: 0. For Gemini 3.x Flash / Flash-Lite, sends thinkingLevel: "minimal" (thinking cannot be fully disabled on 3.x Flash).

# Troubleshooting

Symptom Likely cause
Log: Unsupported LLM provider Typo in llmProvider (must be exactly gemini)
Chat opens but returns auth / 403 errors Invalid, expired, or revoked API key; or billing not enabled in Google
Log: Gemini client not initialized Empty or malformed API key

Also confirm:

  • llmProvider is "gemini" (lowercase)
  • API key is complete, not expired, and has Gemini API access in Google
  • Google Cloud project has billing enabled if Google requires it
  • Outbound HTTPS from the yCrash server to Google is allowed (generativelanguage.googleapis.com)

If you LLM setup still fails, check the documentation here or reach our support team (opens new window).