2672243194/dsh-tally1

dsh-tally

Personal bookkeeping plugin for DeepSeek Harness: record expenses/income (single or batch), list, monthly/annual stats with month-over-month trend, budgets with progress/over-limit alerts, soft-delete with restore, CSV export and self-contained HTML reports. Zero runtime dependencies, local JSON storage, token-efficient output.

AI 分析

适合希望在对话中直接进行个人财务记账与统计的用户。支持批量记账、预算预警和数据导出,数据保存在本地,安全且节省 Token。

パッケージ
dsh-tally
バージョン
0.4.0
ライセンス
MIT
最終更新
2026/08/16

インストール

$npx -p @deepseek-ai/dsh dsh plugin --profile web add github:2672243194/dsh-tally

ドキュメント

README 全文を読む ↗

使用

直接对话:

记一笔:今天午饭 28 元,餐饮
帮我把这几笔记上:昨天奶茶 15、打车 12、周三聚餐 85
这个月花了多少钱?统计一下
查一下上个月"交通"类目
记错了,删掉那笔 id 是 a1b2c3 的
刚才删错了,恢复那笔 id 是 a1b2c3 的
这个月预算 3000 元
看看这个月预算还剩多少
统计一下今年
把这个月的账导出成 CSV

工具

tally_add(amount, type?, category?, note?, date?) — 记一笔

参数类型默认说明
amountnumber必填金额(元,>0,最多两位小数)
typestringexpenseexpense 支出 / income 收入
categorystring其他内置分类或自定义
notestring备注(≤50 字,可搜索)
datestring今天YYYY-MM-DD

tally_batch(entries) — 批量记账:一次写多笔(每项字段同 tally_addamount 必填);合法项整体写入,非法项跳过并按序号报告

tally_list(month?, category?, keyword?, limit?, includeDeleted?) — 查账(默认当月、日期倒序、每笔一行含短 id;includeDeleted: true 显示已删条目并带 [已删] 标记)

tally_stats(month?, year?) — 汇总

  • month:月度汇总(紧凑单块),自动带上月环比与预算状态:
[2026-08] 支出 ¥186.00 · 收入 ¥8,000.00 · 结余 +¥7,814.00 · 12 笔 · 日均支出 ¥75.50
类别 Top:餐饮 ¥860 · 交通 ¥420 · 购物 ¥380
较上月 +12.3%(上月 ¥165.60)
预算 ¥3,000.00 · 剩余 ¥2,814.00        (用掉 80% 显示 ⚠️ 提醒;超支显示超支额)
  • year(不带 month):全年报告,逐月列出 + 全年总计:
[2026] 全年支出 ¥15,432.00 · 收入 ¥96,000.00 · 结余 +¥80,568.00 · 215 笔
  1月 支出 ¥1,200.00 · 收入 ¥8,000.00 · 结余 +¥6,800.00 · 18 笔
  ...

tally_remove(id, confirm?) — 删错账:首次调用返回待删详情,confirm: true 才会删除;删除为软删除,可随时用 tally_restore 恢复

tally_restore(id) — 恢复已删账目(先用 tally_list(includeDeleted: true) 找到 id)

tally_budget(month?, amount?) — 预算:传 amount 设置/覆盖当月预算,省略则查询(预算/已支出/剩余/是否超支);tally_stats 同步显示预算状态

tally_export(month?, path?, format?) — 导出

  • format: "csv"(默认):真正写文件(默认 /exports/tally-YYYY-MM.csv),带 UTF-8 BOM(Excel/WPS 双击打开中文正常),返回文件路径 + 前 3 行预览;
  • format: "html":生成自包含 HTML 账目报告tally-report-YYYY-MM.html,浏览器双击即开):统计卡片(支出/收入/结余/环比/预算进度)、类别占比图、月份/类别筛选 + 搜索、显示已删开关——嵌入全部月份数据,无需服务;
  • path 自定义输出位置(相对路径基于 DSH home 解析)。