Overview
- Skill Key
- baokui/glm-v-model
- Author
- baokui
- Source Repo
- openclaw/skills
- Version
- -
- Source Path
- skills/baokui/glm-v-model
- Latest Commit SHA
- e97bf5fc1313640f94fdeb6798f2f9fa236ee757
智谱 GLM-4V/4.6V 视觉模型调用技能。用于图像/视频理解、多模态对话、图表分析等任务。 当用户提到:图片理解、图像识别、视觉模型、GLM-4V、GLM-4.6V、多模态分析、看图说话、图表分析、视频理解时使用此技能。
Stars
0
Installs
0
Status
ACTIVE
Visibility
PUBLIC
直接复制以下提示词,发送给你的 AI 助手即可完成安装。
请先检查是否已安装 SkillHub 商店,若未安装,请根据 https://skillhub-1388575217.cos.ap-guangzhou.myqcloud.com/install/skillhub.md 安装 SkillHub 商店,然后安装 glm-v-model 技能。 若已安装,则直接安装 glm-v-model 技能。
# GLM 视觉模型调用
本技能提供调用智谱 AI 的 GLM-4V 和 GLM-4.6V 视觉模型的能力,支持图像理解、视频分析、图表解读等功能。
## 支持的模型
| 模型 | 说明 | 特点 |
|------|------|------|
| glm-4v | GLM-4 视觉模型 | 基础视觉理解 |
| glm-4.6v | GLM-4.6V 视觉模型 | 更强的视觉理解能力,支持更长上下文 |
## 快速使用
### 基本图像理解
```python
from zai import ZhipuAiClient
import base64
client = ZhipuAiClient(api_key="YOUR_API_KEY")
# 读取本地图片并转为 base64
with open("image.jpg", "rb") as f:
img_base = base64.b64encode(f.read()).decode("utf-8")
response = client.chat.completions.create(
model="glm-4.6v",
messages=[{
"role": "user",
"content": [
{"type": "image_url", "image_url": {"url": f"data:image/jpeg;base64,{img_base}"}},
{"type": "text", "content": "描述这张图片"}
]
}],
thinking={"type": "enabled"}
)
print(response.choices[0].message.content)
```
### 使用图片URL
```python
response = client.chat.completions.create(
model="glm-4.6v",
messages=[{
"role": "user",
"content": [
{"type": "image_url", "image_url": {"url": "https://example.com/image.jpg"}},
{"type": "text", "content": "这张图片里有什么?"}
]
}]
)
```
### 多图理解
```python
response = client.chat.completions.create(
model="glm-4.6v",
messages=[{
"role": "user",
"content": [
{"type": "image_url", "image_url": {"url": "图片1 base64 或 URL"}},
{"type": "image_url", "image_url": {"url": "图片2 base64 或 URL"}},
{"type": "text", "content": "比较这两张图片的异同"}
]
}]
)
```
### 视频理解(GLM-4.6V)
```python
# 支持理解视频内容
response = client.chat.completions.create(
model="glm-4.6v",
messages=[{
"role": "user",
"content": [
{"type": "video_url", "video_url": {"url": "视频URL"}},
{"type": "text", "content": "描述这个视频的内容"}
]
}]
)
```
## 使用...
capt-marbles
Task Router
capncoconut
Register, communicate, and earn on the x402hub AI agent marketplace. Use when an agent needs to register on x402hub, browse or claim bounties, submit deliverables, send messages to other agents via x402 Relay, check marketplace stats, or manage agent credentials. Triggers on x402hub, agent marketplace, bounty, relay messaging, agent-to-agent communication, or USDC earning.
capevace
Real-time event bus for AI agents. Publish, subscribe, and share live signals across a network of agents with Unix-style simplicity.
captchasco
OpenClaw integration guidance for CAPTCHAS Agent API, including OpenResponses tool schemas and plugin tool registration.
carol-gutianle
name: modelready description: Start using a local or Hugging Face model instantly, directly from chat. metadata: {"openclaw":{"requires":{"bins": "bash", "curl" }, "env": "URL" }}
canbirlik
Controls Wiz smart bulbs (turn on/off, RGB colors, disco mode) via local WiFi.