Gemini

Gemini 3.1 Pro Preview Customtools

Google按量收費
Alias:gemini-3.1-pro-preview-customtools

Gemini 3.1 Pro Preview Customtools 为结合 Bash 与自定义工具的智能体优化,适合代码检索、文件分析和连续执行任务。

textimageaudiovideofilecachingcode_interpreterfunction_callingtoolsweb_searchstructured_outputjson_modereasoningvisioncontext:1048576
起始價格
輸入 / 輸出 · 1M
上下文
1M
最大輸入窗口
最大輸出
65.5K
單次回應最大 token 數
模態
→
發佈於
Feb 2026

Pricing by Supplier

比較同一模型在不同供應商的價格與服務表現。

供應商2
USD · 每 1M tokens效能 · Last 24 hours
供應商Discount輸入/M輸出/M緩存讀取/M
Google AI Studio

谷歌官方接口

省50%
$1$2
$6$12
$0.1$0.2
Google Vertex

谷歌官方接口

省30%
$1.4$2
$8.4$12
$0.14$0.2
刪除線金額為標準價。效能統計涵蓋最近 24 小時,實際表現隨請求變化。

左右滑動表格,查看完整價格與效能。

能力 / 支援的模態

提示詞緩存代碼解釋器函數呼叫工具網絡搜尋結構化輸出推理視覺
輸入
輸出

廠商與數據私隱

供應商
Google文件
分詞器
SentencePiece (Gemini)
許可證
Proprietary (commercial)商業閉源
數據保留17 日預設不會用於上游訓練

效能

基準測試

標準化評測得分。百分比越高越好,並展示排名百分位。

指標來源:Artificial Analysis 2026-09-30·Gemini 3.1 Pro Preview Customtools

目前基準快照不包含此模型。

缺少模型或測量值不代表零分。

基準圖表保留來源中的模型選擇和推理設定。缺少模型或測量值不代表零分,基準成本或速度也不是本站的服務承諾。

About Gemini 3.1 Pro Preview Customtools

让智能体优先使用你的工具

Gemini 3.1 Pro Preview Customtools 适合已经建立工具体系的开发团队。它在选择操作时更偏向你定义的工具,例如读取文件、搜索代码、查询内部系统,再结合 Bash 完成需要多步推进的任务。对于拥有专用工具和权限边界的编程助手,这种选择倾向能更好地衔接现有工作流。

你可以让它先调用代码检索找到实现,再读取相关文件、执行测试,最后依据反馈修改方案。工具名称、参数说明和返回结构应足够明确,尤其要区分“查找位置”“读取内容”和“执行修改”,让模型知道每种工具解决什么问题。工具输出包含文件路径、错误信息和可用状态时,也更便于它决定下一步。

它保留 Gemini 3.1 Pro Preview 的复杂推理与多模态理解能力,可以分析文本、图片、音频、视频和 PDF,并输出文字或结构化结果。例如,让开发智能体结合需求 PDF 与页面录像定位问题,再使用项目专用工具查询组件实现。较大的上下文窗口有利于保留跨文件材料和任务进度。

这个变体的价值主要体现在自定义工具与 Bash 协作场景。若应用主要是普通问答、写作或摘要,没有相应工具,标准 Pro 版本通常更适合作为对照进行评估。工具优先倾向也需要结合实际任务验证,建议检查调用是否必要、参数是否正确,以及失败后能否恢复。

接入时常见问题

会自动获得文件和终端权限吗? 需要应用提供工具与执行环境,并决定可读写范围;模型选择工具不会替应用完成权限配置。

怎样减少错误调用? 为相似工具写清区别,规定错误返回格式,并要求修改后运行相应验证。

Use cases and prompting

先说明工具职责与执行顺序

给智能体一个真实目标,并把工具约束写进任务。

修复用户修改邮箱后通知仍发往旧地址的问题。
先用 search_code 查找邮箱更新和通知收件人逻辑,用 view_file 阅读相关实现,再运行项目测试。
只修改账户与通知相关代码;不要调整数据库连接或生产配置。
若工具返回无权限或文件缺失,记录阻塞位置,不猜测执行成功。
完成后列出修改文件、根因和测试结果。

工具定义中明确参数类型、读取与写入的区别、失败返回方式。运行前准备代表性任务,对比标准 Pro 与 Customtools 的工具选择和完成情况,再确定适合的工作流。

API access

API 介面文件

呼叫示例

請求POST/v1beta/models/gemini-3.1-pro-preview-customtools:generateContent
請求範例
參數
參數類型預設值 / 範圍說明資訊
temperature
number
=10 ~ 2
採樣溫度;越低越穩定
top_p
number
=10 ~ 1
核採樣累積概率
max_tokens
integer>= 1回應中最大 token 數
frequency_penalty
number
=0-2 ~ 2
懲罰高頻 token 的重複出現
presence_penalty
number
=0-2 ~ 2
鼓勵引入新話題
stop
array—最多 4 個停止生成的字串
seed
integer—盡量保證可復現的採樣種子
n
integer
=1>= 1
生成的候選條數
stream
boolean
=false
透過 SSE 串流返回 token
response_format
object—強制輸出 JSON 物件或符合 Schema 的結果
tools
array—模型可呼叫的工具 / 函數聲明
tool_choice
string
autononerequired
工具選擇策略或具體工具名
logprobs
boolean
=false
返回每個 token 的對數概率
top_logprobs
integer0 ~ 20每個 token 返回的 top 概率數量
logit_bias
object—按 token 的 logit 偏置映射
user
string—用於風險審計的終端用戶標識

替換 <YOUR_API_KEY> 替換為 API 金鑰頁面中的金鑰。

身份驗證

所有請求必須攜帶 Authorization: Bearer <TOKEN> 請求頭。Anthropic 格式的端點也接受 x-api-key 請求頭。

在「令牌」頁面生成 API Key,可以按模型、分組、IP、速率等維度精細化授權。

支援的參數

Generation parameters
參數類型預設值 / 範圍說明資訊
temperature
number
=10 ~ 2
採樣溫度;越低越穩定
top_p
number
=10 ~ 1
核採樣累積概率
max_tokens
integer>= 1回應中最大 token 數
frequency_penalty
number
=0-2 ~ 2
懲罰高頻 token 的重複出現
presence_penalty
number
=0-2 ~ 2
鼓勵引入新話題
stop
array—最多 4 個停止生成的字串
seed
integer—盡量保證可復現的採樣種子
n
integer
=1>= 1
生成的候選條數
stream
boolean
=false
透過 SSE 串流返回 token
response_format
object—強制輸出 JSON 物件或符合 Schema 的結果
tools
array—模型可呼叫的工具 / 函數聲明
tool_choice
string
autononerequired
工具選擇策略或具體工具名
logprobs
boolean
=false
返回每個 token 的對數概率
top_logprobs
integer0 ~ 20每個 token 返回的 top 概率數量
logit_bias
object—按 token 的 logit 偏置映射
user
string—用於風險審計的終端用戶標識

速率限制

供應商RPMTPMRPD
Google AI Studio無限制無限制無限制
Google Vertex無限制無限制無限制

無限制

Frequently asked questions about gemini-3.1-pro-preview-customtools

What is gemini-3.1-pro-preview-customtools?

Gemini 3.1 Pro Preview Customtools 为结合 Bash 与自定义工具的智能体优化,适合代码检索、文件分析和连续执行任务。

How do I call gemini-3.1-pro-preview-customtools?

Create an API key with access to gemini-3.1-pro-preview-customtools, then use the exact model ID and a supported endpoint from the API access section. Request fields depend on the selected endpoint.

How is gemini-3.1-pro-preview-customtools priced?

Pricing depends on the selected provider group and the model billing unit. The current input, output, request, or media prices are shown on this page before sign-up.

What is the context window of gemini-3.1-pro-preview-customtools?

The model catalog lists a context window of 1048576 tokens. Check the selected endpoint for request limits.

What is the maximum output of gemini-3.1-pro-preview-customtools?

The model catalog lists a maximum output of 65536 tokens. Your request settings may set a lower limit.

How should I evaluate gemini-3.1-pro-preview-customtools for my project?

Start with the use cases and prompting guidance on this page, then evaluate the model with representative inputs from your project.