Agent Skills
› rcarmo/piclaw
› schedule
schedule
GitHub提供任务调度功能,支持单次、定时或间隔执行。优先使用结构化工具创建计划任务,兼容旧版别名及 IPC 文件回退机制,并包含验证查询与响应格式规范。
Trigger Scenarios
用户要求设置定时提醒
需要安排周期性或延迟执行的任务
Install
npx skills add rcarmo/piclaw --skill schedule -g -y
SKILL.md
Frontmatter
{
"name": "schedule",
"description": "Schedule a task to run later or on a recurring basis. Prefer the scheduled_tasks tool; use the schedule_task compatibility alias or IPC fallback only if needed.",
"distribution": "public"
}
Schedule a Task
Prefer the built-in scheduling tool.
Preferred method
Use scheduled_tasks with action: "create".
Example:
scheduled_tasks({
action: "create",
chat_jid: "web:default",
schedule_type: "once",
schedule_value: "2026-03-09T09:00:00Z",
task_kind: "agent",
prompt: "Post a reminder to review the deployment"
})
Compatibility note: schedule_task(...) is the older alias if the structured tool is unavailable.
Key fields
schedule_type:once|cron|intervalschedule_value:once: ISO timestamp (UTC recommended)cron: cron expressioninterval: milliseconds
task_kind:agentorshellpromptfor agent taskscommandfor shell tasks- optional
cwd,timeout_sec,model
IPC fallback
If tool access is unavailable, write an IPC JSON file to $PICLAW_DATA/ipc/tasks/:
cat > "$PICLAW_DATA/ipc/tasks/schedule_$(date +%s)_$$.json" <<EOF
{
"type": "schedule_task",
"chatJid": "$PICLAW_CHAT_JID",
"task_kind": "agent",
"prompt": "Describe what should happen when this task fires",
"schedule_type": "once",
"schedule_value": "2026-03-09T09:00:00Z"
}
EOF
For a shell task, keep the same envelope and change only the task-specific fields:
{
"task_kind": "shell",
"command": "ls -la /workspace",
"cwd": ".",
"timeout_sec": 30,
"schedule_type": "interval",
"schedule_value": "3600000"
}
Verify it was scheduled
SELECT id, chat_jid, task_kind, schedule_type, schedule_value, status, next_run
FROM scheduled_tasks
ORDER BY created_at DESC
LIMIT 5;
Execution history:
SELECT task_id, run_at, duration_ms, status
FROM task_run_logs
ORDER BY id DESC
LIMIT 10;
Response requirements
After creating a schedule, respond with:
- task ID
- schedule type
- schedule value
- next run time in human-readable local time, if available
Notes
- Shell tasks are pre-validated: no newlines, no destructive patterns, and
cwdmust stay inside/workspace. - Use UTC for human-facing schedules unless the user asked for another timezone.
Environment
PICLAW_DATA— piclaw data directory (containsipc/,sessions/)PICLAW_CHAT_JID— JID of the triggering chat
Version History
- 5fa0ce5 Current 2026-07-25 10:25


