npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

dsh-daily-tasks

v0.1.0

Published

dsh plugin: tasks (developer preview)

Readme

tasks

dsh(DeepSeek Harness)插件。跨会话的持久个人待办清单(GTD):本地 JSON 文件存储,支持优先级、截止日期、标签、备注与来源标记,提供增/查/改/列表/四桶总览五个工具。

状态:developer preview。尚未在真实 dsh 运行时中验证,手动验证步骤见下文。

定位:与内置 todo_write 的分工

dsh 内置的 todo_write 是 agent 单次任务的执行计划:把当前回合要做的事拆成清单,会话结束即止。本插件是 跨会话的长期个人待办:今天记下"周五前交周报",三天后开一个新会话它还在。两者互补——典型用法是由 agent 用内置 todo 规划"如何完成",用本插件记录"要做什么"。

Provider 分层

所有工具只面向统一的 TaskProvider 接口(list/get/add/update,全异步签名)。v1 只实现 local(JSON 文件持久化,tmp+rename 原子写,零网络、零凭证);接口与 config 的 provider 判别字段已为 v2 的远程后端(Todoist / Microsoft To Do)预留插位——远程后端的写操作届时将单独做权限门控,不沿用本地 L1 的开放策略。

工具

| 工具 | 作用 | | --- | --- | | task_add | 新增待办:标题(必填)、优先级(none/low/medium/high)、截止日期(YYYY-MM-DD,本地时区)、标签、备注、来源标记。 | | task_list | 过滤列表:状态(默认只看 open,all 看全部)/标签/优先级/截止日期范围(含边界)/关键词(不区分大小写,匹配标题/备注/标签)。排序固定:截止日期(无日期排最后)> 优先级 > 创建时间。 | | task_update | 改任意字段并迁移状态:open→done 记录完成时间,done→open 重开清除完成时间,cancelled 不带完成时间。可选字段传空字符串清除;标签传入则整体替换。 | | task_get | 单条详情(含全部时间戳与来源)。 | | task_summary | 四桶总览:逾期 / 今日到期 / 本周(至本周日)/ 无日期,各桶给出进行中任务的数量与前 N 条——为 daily-briefing 类组合流程准备。 |

领域模型:Task{ id, title, notes?, priority, due?, tags[], status(open/done/cancelled), createdAt, updatedAt, completedAt?, source? }。source 是自由文本来源标记,为组合流程预留。

安装与配置

# dsh 配置示例
- id: tasks
  name: dsh-daily-tasks
  config:
    enabled: true
    provider: local            # v1 仅 local;todoist / microsoft-todo 为 v2 预留
    local:
      dataFile: tasks-store.json   # 存储文件,相对路径相对 dsh 工作目录
    # defaultListLimit: 50     # task_list 默认返回上限
    # summaryMaxItems: 5       # task_summary 每桶默认列出条数

权限透明

本插件对宿主环境的影响面,逐条交代清楚:

  • 读写位置:仅写配置的 local.dataFile 一个 JSON 文件(tmp+rename 原子写);不读取其他任何文件。
  • 网络域名:无。local Provider 不发起任何网络请求。
  • 凭证:不持有任何凭证(v2 远程 Provider 的凭证将只从环境变量读取,配置里只放变量名)。
  • 确认点:无新增确认点。本地待办的增删改属本地 L1 写,正常开放。
  • 日志内容:仅加载时写一行启动日志(任务数与存储路径);存储文件损坏时写一行警告(原文件保留,不覆盖)。

组合示例

source 字段让本插件成为其他插件的"落点":

  • 与 mail 组合:"把主题含『账单』的未读邮件各建一条待办,来源记邮件 id,截止下周五。"——agent 用 mail_search 找到邮件,task_add 时带上 source: mail:<id>。
  • 与 watcher 组合:"这个 RSS 出现含『发布』的新条目时提醒我,并转一条待办。"——watcher 投递后 agent 调 task_add 记录跟进事项。
  • 晨报流程:会话开场让 agent 调 task_summary,把"逾期/今日到期"两桶念给你听。

已知限制

  • 无重复任务/提醒:v1 没有 recurring 任务,也没有到点提醒(提醒属 scheduler 的职责,可组合使用)。
  • 截止日期精度到天:due 是 YYYY-MM-DD 本地日历日,不带时刻与时区。
  • 单文件整体读写:每次变更重写整个 JSON 文件;个人 GTD 清单量级(千条以内)没有问题,不适合当高并发数据库用。
  • 无删除工具:v1 用 task_update 的 cancelled 状态表达"不做",已完成/已取消任务保留在文件中(可手动编辑 JSON 清理)。
  • 存储明文:待办内容明文落盘,不要写入口令、密钥等敏感内容。

手动验证

本仓库的 CI 只覆盖类型检查与纯函数单测(node:test + 临时目录)。接入真实 dsh 后请手动验证:

  1. 在 dsh 配置中启用本插件,确认启动日志出现 tasks: loaded(provider local,任务 N 条,存储 …)。
  2. 调用 task_add 新增两条不同优先级/截止日期的待办,确认返回的 task 字段完整,且 tasks-store.json 已写入。
  3. 调用 task_list(默认)确认只看 open;用 tag/keyword/dueBefore 过滤确认结果正确。
  4. 调用 task_update 把一条置为 done,确认返回带 completedAt;再置回 open 确认 completedAt 消失。
  5. 调用 task_summary,确认逾期/今日到期/本周/无日期四桶数量与手工清点一致。
  6. 重启 dsh,确认 task_list 仍能看到之前新增的待办(跨会话持久化)。
  7. 手动把存储文件改坏(写入非 JSON 文本),重启确认插件以空清单启动、日志出现损坏警告,且原文件未被覆盖。

许可

MIT