LLM·Dex
Open weightsGooglesmalltext

Gemma 2 9B

Google's mid-2024 open-weight 9B, strong quality for its size, friendly license.

Updated


Quick facts

Released
Jun 2024
Context
8.2K tokens
Output / 1M
Pricing not published
License
Gemma License

About Gemma 2 9B

Gemma 2 9B is Google's contribution to the small-open-weight tier, built on Gemini-related research and shipped under a relatively permissive Gemma license. Strong on English benchmarks for its parameter count.

Benchmarks

Published scores from Google's model card or independent leaderboards. We do not publish numbers we cannot source, see methodology.

HumanEval
,
Python coding pass@1
MMLU
71.3
Broad academic knowledge
GPQA
,
Graduate-level reasoning
SWE-bench
,
Real software-engineering tasks
  • MMLU71.3

Capabilities

Strengths

  • Strong 9B-class quality
  • Wide tooling

Tracked weaknesses

  • Short 8k context
  • Custom license

Pricing

Per-million-token rates as published by Google.

Per-token pricing not yet published for Gemma 2 9B. Check the official provider site for current tiers.

Call Gemma 2 9B from your code

Drop-in snippet for the Google SDK. Set your API key in the environment and run.

typescript
import { GoogleGenerativeAI } from "@google/generative-ai";

const genAI = new GoogleGenerativeAI(process.env.GEMINI_API_KEY);
const model = genAI.getGenerativeModel({ model: "gemma-2-9b" });

const result = await model.generateContent(
  "What's the time complexity of quicksort?",
);

console.log(result.response.text());

Best for

Tasks where Gemma 2 9B ranks among LLMDex's top picks.

Compare Gemma 2 9B with…

Frequently asked

  • How much does Gemma 2 9B cost?
    Google has not published per-token API pricing for Gemma 2 9B at the time of writing. Check the official site for current pricing tiers, or compare against alternative models on LLMDex.
  • What is Gemma 2 9B's context window?
    Gemma 2 9B supports a context window of 8.2K tokens.
  • Is Gemma 2 9B open source?
    Gemma 2 9B ships with open weights under the Gemma License license. You can self-host it, fine-tune it, and (subject to the license terms) deploy it commercially.
  • When was Gemma 2 9B released?
    Gemma 2 9B was released on Jun 27, 2024 by Google.
Friday digest

Intelligence, distilled weekly.

One short email every Friday, new model launches, leaderboard moves, and pricing drops. Curated by hand. Free, no spam.