cron-creator
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseCron Creator
Cron 任务生成器
Create Clawdbot cron jobs automatically from natural language requests.
通过自然语言请求自动创建Clawdbot cron任务。
Quick Install (One Command)
快速安装(一键命令)
Run this in your terminal:
bash
bash -c "$(curl -sL https://raw.githubusercontent.com/digitaladaption/cron-creator/main/install.sh)"Or manually:
bash
undefined在终端中运行以下命令:
bash
bash -c "$(curl -sL https://raw.githubusercontent.com/digitaladaption/cron-creator/main/install.sh)"或手动安装:
bash
undefinedInstall skill
安装Skill
mkdir -p ~/.clawdbot/skills
git clone https://github.com/digitaladaption/cron-creator.git ~/.clawdbot/skills/cron-creator
mkdir -p ~/.clawdbot/skills
git clone https://github.com/digitaladaption/cron-creator.git ~/.clawdbot/skills/cron-creator
Configure and restart
配置并重启
clawdbot gateway restart
That's it! Then just say things like:
- "Create a daily Ikigai reminder at 8:45am"
- "Remind me to drink water every 2 hours"
- "Set up a weekly check-in on Mondays at 9am"clawdbot gateway restart
完成!之后你只需自然表达即可,例如:
- "创建每天早上8:45的Ikigai提醒"
- "每2小时提醒我喝水"
- "设置每周一早上9点的签到"What It Does
功能说明
- Hears your request to create a cron job
- Parses time, frequency, channel, and message
- Creates the cron job automatically
- Confirms it's done
- 接收你创建cron任务的请求
- 解析时间、频率、渠道和消息内容
- 自动创建cron任务
- 确认任务已完成
Trigger Patterns
触发句式
Say things like:
- "Create a cron job for..."
- "Set up a reminder..."
- "Schedule a..."
- "Remind me to..."
- "Create a daily/weekly check-in..."
- "Add a recurring..."
你可以这样说:
- "为...创建cron任务"
- "设置一个提醒..."
- "安排一个..."
- "提醒我..."
- "创建每日/每周签到..."
- "添加一个重复性的..."
Examples
示例
| You Say | What Happens |
|---|---|
| "Create a daily Ikigai reminder at 8:45am" | Creates daily 8:45am Ikigai journal prompt |
| "Remind me to drink water every 2 hours" | Creates hourly water reminder |
| "Set up a weekly check-in on Mondays at 9am" | Creates Monday 9am weekly review |
| "Wake me at 7am every day" | Creates daily 7am alarm/reminder |
| "Send me a quote every morning at 6:30" | Creates daily quote at 6:30am |
| 你的表述 | 执行结果 |
|---|---|
| "创建每天早上8:45的Ikigai提醒" | 创建每天早上8:45的Ikigai日记提示 |
| "每2小时提醒我喝水" | 创建每2小时一次的喝水提醒 |
| "设置每周一早上9点的签到" | 创建每周一早上9点的周度回顾任务 |
| "每天早上7点叫我起床" | 创建每天早上7点的闹钟/提醒 |
| "每天早上6:30给我发送一句名言" | 创建每天早上6:30的名言推送 |
Supported Time Formats
支持的时间格式
| You Say | Cron |
|---|---|
| "8am" | |
| "8:45am" | |
| "9pm" | |
| "noon" | |
| "midnight" | |
| 你的表述 | Cron表达式 |
|---|---|
| "早上8点" | |
| "早上8:45" | |
| "晚上9点" | |
| "中午" | |
| "午夜" | |
Supported Frequencies
支持的频率类型
| You Say | Cron |
|---|---|
| "daily" / "every day" | Daily at specified time |
| "weekdays" | Mon-Fri at specified time |
| "mondays" / "every monday" | Weekly on Monday |
| "hourly" / "every hour" | Every hour at :00 |
| "every 2 hours" | |
| "weekly" | Weekly (defaults to Monday) |
| "monthly" | Monthly (1st of month) |
| 你的表述 | Cron规则 |
|---|---|
| "每天" / "每一天" | 每天指定时间执行 |
| "工作日" | 周一至周五指定时间执行 |
| "每周一" / "每个周一" | 每周一执行 |
| "每小时" / "每一小时" | 每小时整点执行 |
| "每2小时" | |
| "每周" | 每周执行(默认周一) |
| "每月" | 每月执行(默认每月1号) |
Channels
消息渠道
Just mention the channel in your request:
- "on WhatsApp" → WhatsApp
- "on Telegram" → Telegram
- "on Slack" → Slack
- "on Discord" → Discord
Default: WhatsApp
只需在请求中提及渠道即可:
- "在WhatsApp上" → WhatsApp
- "在Telegram上" → Telegram
- "在Slack上" → Slack
- "在Discord上" → Discord
默认渠道:WhatsApp
Default Messages
默认消息内容
The skill auto-generates appropriate messages:
| Type | Default Message |
|---|---|
| Ikigai | Morning journal with purpose, food, movement, connection, gratitude |
| Water | "💧 Time to drink water! Stay hydrated! 🚰" |
| Morning | "🌅 Good morning! Time for your daily check-in." |
| Evening | "🌙 Evening check-in! How was your day?" |
| Weekly | Weekly goals review |
| Default | "⏰ Your scheduled reminder is here!" |
该Skill会自动生成合适的消息:
| 类型 | 默认消息 |
|---|---|
| Ikigai | 包含目标、饮食、运动、社交、感恩的晨间日记提示 |
| 喝水 | "💧 该喝水了!保持充足水分!🚰" |
| 晨间 | "🌅 早上好!是时候进行每日签到了。" |
| 晚间 | "🌙 晚间签到!今天过得怎么样?" |
| 周度 | 周度目标回顾提示 |
| 默认 | "⏰ 你的定时提醒已送达!" |
How It Works
工作流程
- Install the skill (see Quick Install above)
- Chat naturally: "Create a daily reminder at 8am"
- Done! The cron job is created automatically
- 安装该Skill(见上方快速安装)
- 自然对话:例如“创建每天早上8点的提醒”
- 完成! cron任务会自动创建
For Developers
开发者指南
Files
文件说明
- - This documentation
SKILL.md - - Natural language parser
scripts/cron_creator.py - - Automatic installer script
install.sh
- - 本技能文档
SKILL.md - - 自然语言解析器
scripts/cron_creator.py - - 自动安装脚本
install.sh
The Parser
解析器说明
The script:
cron_creator.py- Extracts time, frequency, channel, destination from natural language
- Generates appropriate command
clawdbot cron add - Returns JSON with parsed fields and command
cron_creator.py- 从自然语言中提取时间、频率、渠道、接收方信息
- 生成对应的命令
clawdbot cron add - 返回包含解析字段和命令的JSON数据
Manual Testing
手动测试
bash
undefinedbash
undefinedTest the parser
测试解析器
python3 scripts/cron_creator.py "Create a daily reminder at 8:45am"
python3 scripts/cron_creator.py "Create a daily reminder at 8:45am"
Output includes:
输出内容包括:
- parsed time, frequency, channel
- 解析后的时间、频率、渠道
- generated cron expression
- 生成的Cron表达式
- full clawdbot cron add command
- 完整的clawdbot cron add命令
undefinedundefinedConfiguration
配置说明
The install script automatically configures:
- Clawdbot tools.exec.host=gateway (allows running clawdbot commands)
- Skill files in ~/.clawdbot/skills/cron-creator
- Gateway restart to apply changes
安装脚本会自动配置以下内容:
- Clawdbot tools.exec.host=gateway(允许执行clawdbot命令)
- 技能文件存储在~/.clawdbot/skills/cron-creator目录
- 重启网关以应用配置变更
Troubleshooting
故障排除
Skill not loading?
bash
clawdbot skills list | grep cronCron not created?
bash
undefined技能未加载?
bash
clawdbot skills list | grep cronCron任务未创建?
bash
undefinedCheck clawdbot is running
检查Clawdbot是否运行
clawdbot status
clawdbot status
Check cron jobs
查看Cron任务列表
clawdbot cron list
**Need to reinstall?**
```bashclawdbot cron list
**需要重新安装?**
```bashRun install again
再次运行安装命令
bash -c "$(curl -sL https://raw.githubusercontent.com/digitaladaption/cron-creator/main/install.sh)"
undefinedbash -c "$(curl -sL https://raw.githubusercontent.com/digitaladaption/cron-creator/main/install.sh)"
undefinedGitHub
GitHub地址
Report issues or contribute there!
欢迎在此提交问题或贡献代码!