查询 64 场中国考试(高考/考研/四六级/CPA/法考…)的规则日期(第二个周六、第一个周日)与倒计时。
安装
# GitHub 源码(首次需按提示配置 allowBuilds 构建授权后重试)
dsh plugin --profile web add github:zimai233/dsh-exam-countdown
GitHub 来源的插件在安装时会在你的机器上执行构建脚本。请只安装可信来源,并尽量锁定 commit(github:owner/repo#sha)。
README
为 DeepSeek Harness 提供的中国考试倒数日插件。
内置 64 场中国主要考试(高考、考研、国考、四六级、教资、CPA、法考、一建、软考、护士执业……), 把纯日期计算封装成两个 agent 可调用的工具。日期一旦过去,自动顺延到下一年(循环滚动); 四六级等按「每年 6 月/12 月第二个周六」、JLPT 按「每年 7 月/12 月第一个周日」精确计算。
纯 ESM,零构建步骤 —— 发布的 npm 包本身就是运行时代码。
为什么需要它
DSH 生态里 教育 / 考试类目非常单薄:现成的插件多集中在工具链、媒体与设计领域,
没有任何一个提供中国考试的日程数据与倒数计算。这个插件补上了这块空白:
把「考程」网页应用(china-exam-countdown)的数据与日期数学移植为服务端工具,
agent 可以直接回答「高考还有多少天」「下一次 CPA 是什么时候」这类问题。
功能特性
- 64 场内置考试,覆盖 9 大分类:升学考试、公务员、英语考试、教师资格、会计金融、法律工程、医学健康、计算机、其他
- 精确规则日期:
2nd-sat(第二个周六)与1st-sun(第一个周日)由纯日期数学计算 - 循环滚动:日期已过自动顺延到下一年同一天,
days >= 0只返回未过期的场次 - 灵活查询:按
id精确查找、按名称关键字模糊搜索、按分类筛选,结果按临近排序 - 两个工具:
exam_countdown(倒数查询)+exam_categories(分类清单) - 零构建、零 DOM/localStorage —— 纯服务端数据 + 日期数学
安装
# 从 npm
dsh plugin --profile myprofile add dsh-exam-countdown
使用
直接用自然语言让 agent 查询,例如:
「高考还有多少天?」
agent 会调用 exam_countdown,例如:
{
"id": "gaokao"
}
返回:
[
{
"id": "gaokao",
"name": "高考",
"cat": "升学考试",
"dateLabel": "6月7日",
"days": 327,
"nextOccurrence": "2027-06-07"
}
]
再如:
「帮我看看最近要考的英语类考试,列出 5 个」
{
"query": "英语",
"limit": 5
}
「有哪些考试分类?」
agent 调用 exam_categories,返回各分类及其考试数量,用来发现 category 参数的合法取值。
工具参考
| 工具 | 参数 | 说明 |
|---|---|---|
exam_countdown |
id (string, 可选) — 精确 slug,如 gaokao、kaoyan、cpa、cet-6;query (string, 可选) — 名称/id/备注子串匹配;category (string, 可选) — 分类名;limit (number, 可选, 默认 10) |
返回 JSON 数组,每项 { id, name, cat, dateLabel, days, nextOccurrence },按剩余天数升序,仅含未过期场次 |
exam_categories |
无 | 返回 [{ category, count }],按考试数量降序 |
可用的 id(64 场)
gaokao zhongkao kaoyan kaoyan-2 chengkao zikao-4 zikao-10 zsb guokao shengkao
wendui xuanxiao shiye cet-6 cet-12 tem4 tem8 pets-3 pets-9 putonghua
jlpt-7 jlpt-12 topik jzb-3 jzb-9 jzm-1 jzm-5 chuji gaoji zhongji
cpa sws jjs zcpg sjs yinhang jijin zq fakao-k fakao-z
yjzs ejzs zjzs xf jzs ytjg jl zx gh yishi-b
yishi-j hushi yaoshi weish sg rk-5 rk-11 ncre-3 ncre-9 catti-6
catti-11 chuban zhuanli daoyou
日期说明
- 固定日期的考试按全国统一日期收录;时间不固定的(如考研、省考、事业单位)使用历年典型日期
- 四六级 = 每年 6 月 / 12 月第二个周六;JLPT = 每年 7 月 / 12 月第一个周日,由程序精确计算
- 所有日期仅供参考,最终以各考试主办方官方公告为准
开发
npm install
npm test # 纯核心逻辑测试(ruleDate / nextOccurrence / queryExams / 数据集)
License
MIT
dsh-exam-countdown
Chinese exam countdown for DeepSeek Harness.
A port of the 考程 / china-exam-countdown app into a DSH tool plugin: the 64-exam dataset and the pure date math, exposed as agent-callable tools. No UI, no DOM — just data + countdown computation on the server side.
Why
The DSH plugin ecosystem's education category is thin: most plugins target tooling, media and design. None provide Chinese exam schedules or countdown math. This plugin fills that gap so agents can answer questions like "how many days until gaokao?" or "when is the next CPA exam?" directly from conversation.
Features
- 64 built-in exams across 9 categories: 升学考试, 公务员, 英语考试, 教师资格, 会计金融, 法律工程, 医学健康, 计算机, 其他
- Exact rule dates:
2nd-sat(second Saturday) and1st-sun(first Sunday) computed by pure date math (CET-4/6, JLPT) - Rolling recurrence: once a date passes it rolls to the same date next year; only upcoming (
days >= 0) results are returned - Flexible queries: exact
id, substringqueryagainst name/id/note, orcategoryfilter, sorted by days ascending - Two tools:
exam_countdown+exam_categories - Zero build step — pure ESM, the published package is the runtime code
Install
# from npm
dsh plugin --profile myprofile add dsh-exam-countdown
Usage
Ask the agent in natural language:
"How many days until gaokao?"
The agent calls exam_countdown with:
{ "id": "gaokao" }
Result:
[
{
"id": "gaokao",
"name": "高考",
"cat": "升学考试",
"dateLabel": "6月7日",
"days": 327,
"nextOccurrence": "2027-06-07"
}
]
More examples:
"List 5 English-language exams coming up soon"
{ "query": "英语", "limit": 5 }
"Which exam categories do you have?"
The agent calls exam_categories, which returns each category with its exam count —
use it to discover valid category values.
Tool Reference
| Tool | Parameters | Description |
|---|---|---|
exam_countdown |
id (string, optional) — exact slug e.g. gaokao, kaoyan, cpa, cet-6; query (string, optional) — substring match against name/id/note; category (string, optional) — category name; limit (number, optional, default 10) |
Returns a JSON array of { id, name, cat, dateLabel, days, nextOccurrence } sorted by days ascending, upcoming only |
exam_categories |
— | Returns [{ category, count }] sorted by count descending |
Available ids (64)
gaokao zhongkao kaoyan kaoyan-2 chengkao zikao-4 zikao-10 zsb guokao shengkao
wendui xuanxiao shiye cet-6 cet-12 tem4 tem8 pets-3 pets-9 putonghua
jlpt-7 jlpt-12 topik jzb-3 jzb-9 jzm-1 jzm-5 chuji gaoji zhongji
cpa sws jjs zcpg sjs yinhang jijin zq fakao-k fakao-z
yjzs ejzs zjzs xf jzs ytjg jl zx gh yishi-b
yishi-j hushi yaoshi weish sg rk-5 rk-11 ncre-3 ncre-9 catti-6
catti-11 chuban zhuanli daoyou
Dates
- Fixed-date exams use the national unified date; flexible ones (考研, 省考, 事业单位) use typical dates from recent years
- CET-4/6 = 2nd Saturday of June / December; JLPT = 1st Sunday of July / December — computed exactly
- All dates are for reference only — always confirm with official announcements
Development
npm install
npm test # runs the pure-core tests (ruleDate / nextOccurrence / queryExams / dataset)
License
MIT
链接
同类插件
liustack/modlens★ 1199
为纯文本模型架起视觉桥梁:粘贴图片,输出结构化 JSON 证据(OCR、版面、语义)。
Anionex/dsh-vision-toolkit★ 308
让纯文本模型更好地做视觉任务:带意图的图片问答、长截图 OCR、UI 还原等。
zhaoolee/notes★ 138
将 DSH 对话导出为锤子便签风格 PNG,或在配置的账号工作区中新建和更新 Markdown 便签。
liustack/modsearch★ 85
纯文本 agent 的联网搜索桥:搜索网页与 X,返回结构化 JSON 证据(search/fetch/引用)。
Lum1104/dsh-browser★ 80
Chrome 侧边栏扩展,让 DSH 直接操控你的浏览器,无需视觉能力。
taxueseek/argo★ 69
专为 agent 打造的搜索工具:多语言,覆盖中文/英文/学术/代码/购物/金融/新闻/百科。