🎁注册即到账 $10 试用余额,立即体验全部模型

Google: Google: Gemma 3n 4B

openrouter--google-gemma-3n-e4b-it
32.768K context·$0.075/M input·$0.15/M output

Google: Gemma 3n 4B provides text to text inference with a 32768 context window for production workloads routed through MaxRouter.

模型参数

上下文长度32.768K tokens
输入价格$0.075 / 1M tokens
输出价格$0.15 / 1M tokens
模型标识openrouter--google-gemma-3n-e4b-it
类型Chat Completion
最大输出8,192 tokens

模型能力

流式输出
支持 SSE 实时流式返回
Function Calling
支持工具调用与函数执行
视觉理解
支持图片输入与分析
JSON Mode
支持结构化 JSON 输出
System Prompt
支持系统提示词设定
多轮对话
支持上下文连续对话

快速开始

curl https://www.maxrouter.ai/api/v1/chat/completions \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer sk-your-api-key" \
  -d '{
    "model": "openrouter--google-gemma-3n-e4b-it",
    "messages": [
      {"role": "user", "content": "你好"}
    ]
  }'

常用参数

modelstring

模型标识,如 openrouter--google-gemma-3n-e4b-it

messagesarray

对话消息数组,包含 role 和 content

temperaturenumber

采样温度 0~2,默认 1。越低越确定

max_tokensinteger

最大生成 token 数

streamboolean

是否流式输出,默认 false

top_pnumber

核采样参数,默认 1

API 兼容性

OpenAI SDK
完全兼容 Python、Node.js、Go 官方 SDK
Chat Completions
标准 OpenAI Chat Completions API 格式
流式响应
支持 SSE 流式与标准非流式两种模式

只需将 base_url 指向本平台,使用平台 API Key 即可无缝切换。