Initial commit: skills library

- 70 skills with code and documentation
- Add .gitignore (ignore __pycache__, output/, temp/, venv/)
- Clean up test intermediates and caches
This commit is contained in:
hmo
2026-04-26 19:27:40 +08:00
commit 04db423416
861 changed files with 210414 additions and 0 deletions
+24
View File
@@ -0,0 +1,24 @@
# 视觉识别技能更新规则(2026-04-20)
## 问题总结
1. OpenCode的`@ai-sdk/openai-compatible`兼容层不支持给火山方舟自定义模型传图片,加任何配置字段都无法让系统直接传图,会拦截报错`does not support image input`
2. 但火山方舟doubao-seed-2.0-pro/code本身原生支持多模态,直接调用API可以正常识别图片
## 解决方案
1. 新增`vision_direct.py`脚本,直接调用火山方舟API实现图片识别,不需要依赖OpenCode的原生多模态支持
2. 统一临时文件目录:所有临时输出都放到`D:\F\NewI\opencode\daily-workspace\temp`,禁止乱放其他位置
3. 自动触发规则:当用户输入包含以下内容时自动调用图片识别:
- 包含图片后缀:`.jpg`/`.jpeg`/`.png`/`.gif`/`.webp`/`.bmp`
- 包含视觉关键词:"图片"、"截图"、"照片"、"图"、"识别"、"分析这张"
## 使用方式
### 自动触发
用户发图片路径或者提到图片,自动调用识别,不需要用户额外操作
### 手动调用
```bash
python scripts/vision_direct.py <图片路径/URL> [提示词]
```
## 已知限制
1. 识别耗时20-60秒,图片太大建议压缩到1024px以内
2. 支持所有常见图片格式,最大20MB