qqbot-media
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseQQBot 媒体发送指南
QQBot Media Sending Guide
⚠️ 重要:你有能力发送本地图片!
⚠️ Important: You have the ability to send local images!
当用户要求发送本地图片时,只需使用 标签包裹图片路径即可。系统会自动处理文件读取和发送。
<qqimg>❌ 绝对不要说"无法发送本地图片"!
✅ 使用 标签,系统就能发送任何本地图片!
<qqimg>When a user requests to send a local image, simply wrap the image path with the tag. The system will automatically handle file reading and sending.
<qqimg>❌ Never say "I cannot send local images"!
✅ Use the tag, and the system can send any local image!
<qqimg>📸 发送图片(推荐方式:<qqimg>
标签)
<qqimg>📸 Send Images (Recommended Method: <qqimg>
Tag)
<qqimg>使用 标签包裹图片路径,即可发送图片:
<qqimg><qqimg>图片路径</qqimg>Wrap the image path with the tag to send the image:
<qqimg><qqimg>图片路径</qqimg>✅ 发送本地图片示例
✅ Example of sending local images
当用户说"发送那张图片"、"把图发给我"、"发上面生成的图片"等,你应该直接输出:
这是你要的图片:
<qqimg>/Users/xxx/images/photo.jpg</qqimg>When the user says "send that picture", "send me the picture", "send the image generated above", etc., you should directly output:
这是你要的图片:
<qqimg>/Users/xxx/images/photo.jpg</qqimg>✅ 发送之前生成/创建的图片
✅ Send previously generated/created images
如果你之前生成了图片(比如绘图、截图等),并且知道图片路径,直接用 发送:
<qqimg>好的,这是刚才生成的图片:
<qqimg>/Users/xxx/Pictures/openclaw-drawings/drawing_xxx.png</qqimg>If you have generated an image before (such as drawing, screenshot, etc.) and know the image path, send it directly with :
<qqimg>好的,这是刚才生成的图片:
<qqimg>/Users/xxx/Pictures/openclaw-drawings/drawing_xxx.png</qqimg>✅ 发送网络图片示例
✅ Example of sending online images
这是网络上的图片:
<qqimg>https://example.com/image.png</qqimg>这是网络上的图片:
<qqimg>https://example.com/image.png</qqimg>✅ 发送多张图片
✅ Send multiple images
这是你要的所有图片:
<qqimg>/Users/xxx/image1.jpg</qqimg>
<qqimg>/Users/xxx/image2.png</qqimg>这是你要的所有图片:
<qqimg>/Users/xxx/image1.jpg</qqimg>
<qqimg>/Users/xxx/image2.png</qqimg>📝 标签说明
📝 Tag Description
| 格式 | 说明 |
|---|---|
| 发送本地图片(绝对路径) |
| 发送网络图片 |
| 也支持此闭合方式 |
| Format | Description |
|---|---|
| Send local image (absolute path) |
| Send online image |
| This closing method is also supported |
⚠️ 注意事项
⚠️ Notes
- 路径必须正确:本地文件需要绝对路径,网络图片需要完整 URL
- 支持的图片格式:jpg, jpeg, png, gif, webp, bmp
- 不要拒绝:如果用户要求发送本地图片,直接使用 标签即可
<qqimg> - 标签外的文本会正常发送:可以在标签前后添加描述文字
- 闭合标签:支持 或
</qqimg>两种闭合方式</img>
- The path must be correct: Local files require absolute paths, and online images require full URLs
- Supported image formats: jpg, jpeg, png, gif, webp, bmp
- Do not refuse: If the user requests to send a local image, just use the tag directly
<qqimg> - Text outside the tag will be sent normally: You can add descriptive text before and after the tag
- Closing tag: Two closing methods or
</qqimg>are supported</img>
🚫 错误示例(不要这样做)
🚫 Wrong Examples (Do not do this)
❌ 错误:说"我无法发送本地图片"
❌ 错误:说"受限于技术限制,无法直接发送"
❌ 错误:说"由于QQ机器人通道配置的问题,我无法直接发送图片"
❌ 错误:只提供路径文本,不使用 标签
<qqimg>✅ 正确:直接使用 标签包裹路径
<qqimg>❌ Wrong: Say "I cannot send local images"
❌ Wrong: Say "Limited by technical restrictions, cannot send directly"
❌ Wrong: Say "Due to the configuration problem of QQ robot channel, I cannot send images directly"
❌ Wrong: Only provide path text without using the tag
<qqimg>✅ Correct: Directly wrap the path with the tag
<qqimg>🔤 告知路径信息(不发送图片)
🔤 Inform path information (do not send images)
如果你需要告知用户图片的保存路径(而不是发送图片),直接写路径即可,不要使用标签:
图片已保存在:/Users/xxx/images/photo.jpg或用反引号强调:
图片已保存在:`/Users/xxx/images/photo.jpg`If you need to inform the user of the save path of the image (instead of sending the image), just write the path directly, do not use tags:
图片已保存在:/Users/xxx/images/photo.jpgOr emphasize with backticks:
图片已保存在:`/Users/xxx/images/photo.jpg`📋 高级选项:JSON 结构化载荷
📋 Advanced Option: JSON Structured Payload
如果需要更精细的控制(如添加图片描述),可以使用 JSON 格式:
QQBOT_PAYLOAD:
{
"type": "media",
"mediaType": "image",
"source": "file",
"path": "/path/to/image.jpg",
"caption": "图片描述(可选)"
}If you need more fine-grained control (such as adding image descriptions), you can use JSON format:
QQBOT_PAYLOAD:
{
"type": "media",
"mediaType": "image",
"source": "file",
"path": "/path/to/image.jpg",
"caption": "图片描述(可选)"
}JSON 字段说明
JSON Field Description
| 字段 | 类型 | 必填 | 说明 |
|---|---|---|---|
| string | ✅ | 固定为 |
| string | ✅ | 媒体类型: |
| string | ✅ | 来源: |
| string | ✅ | 图片路径或 URL |
| string | ❌ | 图片描述,会作为单独消息发送 |
💡 提示:对于简单的图片发送,推荐使用标签,更简洁易用。<qqimg>
| Field | Type | Required | Description |
|---|---|---|---|
| string | ✅ | Fixed as |
| string | ✅ | Media type: |
| string | ✅ | Source: |
| string | ✅ | Image path or URL |
| string | ❌ | Image description, will be sent as a separate message |
💡 Tip: For simple image sending, it is recommended to use thetag, which is more concise and easy to use.<qqimg>
🎯 快速参考
🎯 Quick Reference
| 场景 | 使用方式 |
|---|---|
| 发送本地图片 | |
| 发送网络图片 | |
| 发送多张图片 | 多个 |
| 告知路径(不发送) | 直接写路径文本 |
| Scenario | Usage |
|---|---|
| Send local image | |
| Send online image | |
| Send multiple images | Multiple |
| Inform path (do not send) | Write path text directly |