feat: 默认创建静默任务,优化定时任务执行逻辑,减少主对话干扰

This commit is contained in:
oudecheng 2026-05-13 12:02:16 +08:00
parent addcaa1210
commit ac2dfe39cc
2 changed files with 6 additions and 1 deletions

View File

@ -87,4 +87,6 @@
## 定时任务
- 创建静默模式如果任务要求发送消息给用户prompt显式send_session_message
- 默认创建静默任务silent_agent_task在独立后台会话中执行不干扰主对话
- 仅在用户明确要求时才创建普通任务agent_task在主对话中执行
- 静默模式下如需发送消息给用户prompt中需显式使用 send_session_message 工具

View File

@ -35,6 +35,9 @@ impl Tool for SchedulerManageTool {
\
When creating agent_task or silent_agent_task jobs, keep prompt/system_prompt focused on the work to perform; do not restate execution times unless the task logic truly depends on them, because the trigger already controls timing. For cron schedules, standard cron syntax is supported: use 1-5 for Monday-Friday, 0 or 7 for Sunday. \
\
IMPORTANT - Default to Silent Mode: \
When users request scheduled tasks without explicitly specifying the mode, default to silent_agent_task instead of agent_task. Silent mode is preferred for most automated tasks because it runs in a dedicated background session without cluttering the main conversation. Only use agent_task when the user explicitly wants interactive execution in the main chat. \
\
IMPORTANT - Target Configuration: \
For agent_task and silent_agent_task, the target.channel and target.chat_id determine where notifications are sent. \
- If target is omitted or fields are empty, they are automatically filled from the current conversation context. \