glm-4v 参数
每项参数后的角标指向出处,未公布的项目不做推测。
glm-4v 价格
单位:人民币 / 百万 Token。
| 计费项 | 官方价 | DMXAPI 价 |
|---|---|---|
| 输入 | — | ¥34.25 |
| 输出 | — | ¥34.25 |
官方当前定价页未列出 glm-4v,无法核验官方价格。第三方报道称 2024 年 6 月曾由 100 元降至 50 元每百万 Tokens,仅供参考。 查看 DMXAPI 完整价格表
如何调用 glm-4v
DMXAPI 提供 OpenAI 兼容接口,现有代码只需改地址、令牌和模型名。
- 接口地址
https://www.dmxapi.cn/v1- 模型名
glm-4v
cURL
curl https://www.dmxapi.cn/v1/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $DMXAPI_KEY" \
-d '{
"model": "glm-4v",
"messages": [
{"role": "user", "content": "用三句话介绍你自己"}
]
}'
Python
import os
from openai import OpenAI
client = OpenAI(
base_url="https://www.dmxapi.cn/v1",
api_key=os.environ["DMXAPI_KEY"],
)
resp = client.chat.completions.create(
model="glm-4v",
messages=[{"role": "user", "content": "用三句话介绍你自己"}],
)
print(resp.choices[0].message.content)
Node.js
import OpenAI from "openai";
const client = new OpenAI({
baseURL: "https://www.dmxapi.cn/v1",
apiKey: process.env.DMXAPI_KEY,
});
const resp = await client.chat.completions.create({
model: "glm-4v",
messages: [{ role: "user", content: "用三句话介绍你自己" }],
});
console.log(resp.choices[0].message.content);
glm-4v 相关新闻与资料
按时间倒序,最后核对于 2026-11-19。
资料来源
以下为与该模型相关的延伸阅读。
- [1]
- [2]
- [3]
- [4]
- [5]
- [6]
- [7]
- [8]
- [9]
- [10]
glm-4v 常见问题
国内如何调用 glm-4v?
在 DMXAPI 创建令牌后,把 base_url 设为 https://www.dmxapi.cn/v1,模型名填 glm-4v,即可用 OpenAI 兼容格式调用,无需改动其他代码。
glm-4v 和开源的 GLM-4V-9B 是同一个模型吗?
不是。GLM-4V-9B 是开源权重的多模态模型,glm-4v 是通过智谱开放平台 API 提供的闭源服务。