Inherit agent presets and auto-bind IM delivery targets (0.1.7).

Cron jobs created from WhatsApp can omit bot/target ids and reuse chat overrides; sidebar/agent preset pins persist on fire.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
oliver 2026-09-06 02:31:43 +08:00
parent 2f08136adf
commit 2e690c30c8
15 changed files with 830 additions and 82 deletions

View file

@ -1,8 +1,8 @@
# dsh-ops-cron
Ops fork of [dsh-cron-tasks](https://github.com/Whale-Zhang/dsh-cron-tasks) for DeepSeek Harness.
Scheduled-task plugin for DeepSeek Harness (fork of [dsh-cron-tasks](https://github.com/Whale-Zhang/dsh-cron-tasks)).
- Sidebar **运维定时** under New Session
- Sidebar **定时任务** under New Session
- Agent tools: `cron_create` / `cron_list` / `cron_pause` / `cron_resume` / `cron_delete`
- Per-job delivery: **DSH** (new root session) or **IM** (`ctx.dshIm.send`)
@ -20,11 +20,21 @@ dsh plugin --profile web add -w "github:hansjone/dsh-ops-cron"
| Created from | Default delivery |
|--------------|------------------|
| WhatsApp / IM session (peer resolved + matching 投递目标) | `im` → that `botId`+`targetId` |
| WhatsApp / IM session | `im` → reuse or **auto-create** a 投递目标 for that chat (group→group, DM→DM) |
| Web / plain DSH session | `dsh` → sidebar history session |
| Explicit `delivery` / `im_bot_id`+`im_target_id` | as specified |
Create IM targets first in IM → 投递设置 → 复制调用参数 when you need a stable target for WhatsApp.
You usually do **not** need to paste botId/targetId when creating from WhatsApp — omit `delivery` and the job binds to the current chat.
## Agent preset
| Source | Behavior |
|--------|----------|
| Explicit `agent_preset` / sidebar field | pinned on the job |
| WhatsApp / IM create (omit) | inherit chat/group override → bot preset → Host default |
| Sidebar leave empty | Host default at each fire |
Scheduled runs mount `job.agentPreset` (or Host default when empty).
## License