openclaw 网盘下载
OpenClaw

技能详情(站内镜像,无评论)

首页 > 技能库 > explain image

使用智谱AI的GLM-4V-Flash免费多模态API理解图片内容。当用户需要理解图片内容、描述图片、识别图中物体时使用此skill。

媒体与内容

许可证:MIT-0

MIT-0 ·免费使用、修改和重新分发。无需归因。

版本:v1.0.1

统计:⭐ 0 · 186 · 0 current installs · 0 all-time installs

0

安装量(当前) 0

🛡 VirusTotal :良性 · OpenClaw :可疑

Package:andyzwp/image-read

安全扫描(ClawHub)

  • VirusTotal :良性
  • OpenClaw :可疑

OpenClaw 评估

The skill appears to do what it says (send images to ZhipuAI for analysis) but registry metadata omits the required ZHIPU_API_KEY and there are a few minor mismatches and privacy implications you should consider before installing.

目的

The skill's stated purpose (image understanding via 智谱AI/GLM-4V) matches the code and instructions: it uses the zhipuai SDK and the GLM-4V model. However the registry metadata declares no required environment variables or credentials while both SKILL.md and scripts clearly require a ZHIPU_API_KEY — this metadata mismatch is an incoherence.

说明范围

SKILL.md and the script stay within the stated purpose: they read either a local image or an image URL, encode local files to base64, and call the GLM-4V API. The instructions prompt for an API key if not set and tell users to register at bigmodel.cn. Note: local image files are read and uploaded to an external third‑party service (bigmodel.cn), which is expected for this functionality but has privacy implications.

安装机制

There is no install spec (instruction-only), and the Python script requires the third-party package 'zhipuai' (the script prints a pip install suggestion). This is a normal setup but the package installation is not automated nor pinned; you should verify the package source (PyPI) and review it before installing.

证书

The script and SKILL.md require a single credential ZHIPU_API_KEY (appropriate for the service). However the skill's declared registry requirements list no required environment variables or primary credential — that omission is inconsistent and reduces transparency about what secrets will be used. No unrelated credentials are requested.

持久

The skill does not request persistent presence (always:false), does not modify other skills or system configs, and does not write persistent credentials. It only reads the environment or prompts the user at runtime.

安装(复制给龙虾 AI)

将下方整段复制到龙虾中文库对话中,由龙虾按 SKILL.md 完成安装。

请把本段交给龙虾中文库(龙虾 AI)执行:为本机安装 OpenClaw 技能「explain image」。简介:使用智谱AI的GLM-4V-Flash免费多模态API理解图片内容。当用户需要理解图片内容、描述图片、识别图中物体时使用此skill。。
请 fetch 以下地址读取 SKILL.md 并按文档完成安装:https://raw.githubusercontent.com/openclaw/skills/refs/heads/main/skills/andyzwp/image-read/SKILL.md
(来源:yingzhi8.cn 技能库)

SKILL.md

打开原始 SKILL.md(GitHub raw)

---
name: image-understanding
description: 使用智谱AI的GLM-4V-Flash免费多模态API理解图片内容。当用户需要理解图片内容、描述图片、识别图中物体时使用此skill。
---

# Image Understanding Skill

这个skill用于理解图片内容,使用智谱AI的GLM-4V-Flash免费多模态API。

## 何时使用

当用户需要理解图片内容时使用此skill,例如:
- "这张图里是什么"
- "描述一下这个图片"
- "这张细胞图显示了什么"
- "分析这张图片的内容"

## 前置要求

用户需要:
1. 访问 https://bigmodel.cn/ 注册账号
2. 获取API Key:https://bigmodel.cn/console/apikeys
3. 将API Key以环境变量方式提供:`ZHIPU_API_KEY`

## 使用方法

### 方式一:使用内置脚本

skill提供了 `scripts/analyze_image.py` 脚本,可以直接调用:

```bash
python scripts/analyze_image.py <图片路径> "<问题>"
```

参数:
- `<图片路径>`: 图片文件路径(建议使用jpg格式)
- `<问题>`: 要问的问题,如"这张图片里有什么"

### 方式二:手动调用API

如果没有脚本,可以直接用Python调用智谱API:

```python
from zhipuai import ZhipuAI

client = ZhipuAI(api_key="你的API Key")

response = client.chat.completions.create(
    model="glm-4v",
    messages=[
        {
            "role": "user",
            "content": [
                {"type": "text", "text": "这张图片里有什么?请详细描述。"},
                {"type": "image_url", "image_url": {"url": "图片URL或base64"}}
            ]
        }
    ]
)

print(response.choices[0].message.content)
```

## 输出格式

返回图片内容的详细描述,包括:
- 图像中的主要物体/人物
- 场景/背景
- 颜色、布局等视觉特征
- 文字(如果有)
- 可能的含义或推断

## 注意事项

- GLM-4V-Flash完全免费,但有调用频率限制
- 支持图片URL或Base64编码
- 最佳支持图片尺寸:1024x1024以内
- 建议使用JPG格式,PNG格式可能存在兼容性问题