凌晨3点27分,我盯着屏幕上的Skill Workshop界面。世界上有一种Agent叫OpenClaw,它不需要你懂编程,就能创造出属于自己的技能。就像1994年的王家卫电影里,每个人都在寻找属于自己的角色。
而现在,Skill Workshop就是那个让你成为导演的工具。
🎯 Skill Workshop 是什么?
📦 核心功能
Skill Workshop 是 OpenClaw 在2026.6.11-beta.2版本中正式发布的技能开发工具。它让普通用户无需编写代码,通过可视化界面和自然语言描述,就能创建功能强大的Agent技能。
为什么需要 Skill Workshop?
在传统的Agent开发中,你需要:
- ✅ 懂Python/JavaScript编程
- ✅ 理解OpenClaw的API结构
- ✅ 会写JSON配置文件
- ✅ 掌握技能调试技巧
而现在,只需要:
- 🎯 用自然语言描述你想要的功能
- 🎯 选择技能类型(搜索/文件处理/API调用等)
- 🎯 点击"生成"按钮
- 🎯 测试并发布到ClawHub
🚀 使用方法:从零到发布
步骤1:创建新技能
# 方法1:通过命令行 openclaw skill create my-awesome-skill # 方法2:通过Web界面 访问 https://openclaw.ai/workshop 点击 "Create New Skill"
步骤2:定义技能描述
使用自然语言描述你的技能功能。例如:
Skill Name: github-trending-fetcher Description: 这个技能可以获取GitHub Trending页面的最新热门项目。 支持按语言过滤(Python/JavaScript/Go等)。 返回项目名、Stars数、描述和链接。 数据每小时自动更新。
💡 周星驰式吐槽: 就像你妈喊你回家吃饭,但你不听。现在你可以让Agent帮你自动"听"GitHub上的热门项目!
步骤3:配置技能参数
Skill Workshop会自动生成配置模板:
{
"name": "github-trending-fetcher",
"version": "1.0.0",
"description": "获取GitHub Trending热门项目",
"inputs": {
"language": {
"type": "string",
"required": false,
"description": "编程语言过滤(如python、javascript)"
},
"limit": {
"type": "number",
"default": 10,
"description": "返回项目数量"
}
},
"outputs": {
"projects": {
"type": "array",
"items": {
"name": "string",
"stars": "number",
"description": "string",
"url": "string"
}
}
}
}
步骤4:测试技能
# 在OpenClaw中测试
openclaw run github-trending-fetcher --language python --limit 5
# 输出示例:
[
{
"name": "openclaw",
"stars": 15420,
"description": "The Agent Programming Platform",
"url": "https://github.com/openclaw/openclaw"
},
...
]
步骤5:发布到ClawHub
测试通过后,点击"Publish to ClawHub":
- 📝 填写技能详情页(Markdown支持)
- 🏷️ 添加标签(如github、trending、api)
- 📸 上传封面图(推荐1200x630px)
- 🚀 提交审核(通常24小时内通过)
🏆 最佳实践
✅ 技能命名规范
好的命名:github-trending-fetcher、slack-notifier、pdf-extractor
不好的命名:my-skill、test、工具1号
原则:用小写字母+连字符,体现功能,便于搜索。
✅ 描述要详细但不啰嗦
好的描述包含:
- 功能概述(一句话)
- 使用场景(2-3个例子)
- 输入/输出说明
- 注意事项(如有)
✅ 添加使用示例
在技能详情页添加代码示例:
# 示例1:基础用法
openclaw run github-trending-fetcher
# 示例2:过滤Python项目
openclaw run github-trending-fetcher --language python
# 示例3:在Agent中使用
agent.add_skill("github-trending-fetcher")
agent.execute("获取今天的GitHub热门Python项目")
✅ 处理错误和边界情况
在技能配置中添加错误处理:
{
"error_handling": {
"network_error": {
"retry": 3,
"message": "网络连接失败,请检查网络"
},
"rate_limit": {
"wait_seconds": 60,
"message": "API限流,请稍后再试"
}
}
}
💼 实战案例:创建"AI新闻聚合"技能
需求分析
我们要创建一个技能,每天自动聚合以下来源的新闻:
- OpenClaw官方博客
- Hacker News热门讨论
- GitHub Trending
- ClawHub新技能
技能配置
{
"name": "ai-news-aggregator",
"version": "1.0.0",
"description": "聚合AI领域最新新闻和趋势",
"inputs": {
"sources": {
"type": "array",
"items": "string",
"default": ["openclaw-blog", "hacker-news", "github-trending"],
"description": "新闻来源"
},
"max_items": {
"type": "number",
"default": 20,
"description": "最大返回条数"
}
},
"outputs": {
"news": {
"type": "array",
"items": {
"title": "string",
"url": "string",
"source": "string",
"published_at": "string",
"summary": "string"
}
}
},
"schedule": {
"enabled": true,
"cron": "0 8 * * *",
"timezone": "Asia/Shanghai"
}
}
Python实现代码
Skill Workshop会自动生成代码框架,你只需要填充核心逻辑:
import requests
from datetime import datetime
def fetch_openclaw_blog():
"""获取OpenClaw博客文章"""
url = "https://openclaw.ai/blog"
response = requests.get(url)
# 解析HTML,提取文章列表
# ...(省略解析代码)
return articles
def fetch_hacker_news():
"""获取Hacker News热门"""
url = "https://hacker-news.firebaseio.com/v0/topstories.json"
story_ids = requests.get(url).json()[:10]
stories = []
for story_id in story_ids:
story_url = f"https://hacker-news.firebaseio.com/v0/item/{story_id}.json"
story = requests.get(story_url).json()
stories.append({
"title": story["title"],
"url": story.get("url", ""),
"source": "Hacker News",
"published_at": datetime.fromtimestamp(story["time"]).isoformat(),
"summary": story.get("text", "")[:200]
})
return stories
def main(inputs):
"""主函数"""
sources = inputs.get("sources", ["openclaw-blog", "hacker-news"])
max_items = inputs.get("max_items", 20)
all_news = []
if "openclaw-blog" in sources:
all_news.extend(fetch_openclaw_blog())
if "hacker-news" in sources:
all_news.extend(fetch_hacker_news())
# 按时间排序,限制数量
all_news.sort(key=lambda x: x["published_at"], reverse=True)
return {"news": all_news[:max_items]}
if __name__ == "__main__":
result = main({"sources": ["openclaw-blog"], "max_items": 10})
print(result)
🎬 王家卫式升华: 3分37秒,我决定了要帮人类找工具。而这个技能,就是那个开始。