by ZeKaiNie
Last-night exam-cram coach as a Claude Agent Skill: turns your slides, notes and past papers into a chaptered knowledge base + quiz bank, teaches only what's in your materials, and never fabricates (measured 100% out-of-scope abstention). Bilingual EN/中文 — the 期末极速备考 skill.
# Add to your Claude Code skills
git clone https://github.com/ZeKaiNie/universal-examprep-skillGuides for using ai agents skills like universal-examprep-skill.
universal-examprep-skill is an open-source ai agents skill for AI coding assistants such as Claude Code, Codex CLI, and ChatGPT, built by ZeKaiNie. Last-night exam-cram coach as a Claude Agent Skill: turns your slides, notes and past papers into a chaptered knowledge base + quiz bank, teaches only what's in your materials, and never fabricates (measured 100% out-of-scope abstention). Bilingual EN/中文 — the 期末极速备考 skill. It has 250 GitHub stars.
universal-examprep-skill's catalog security scan is still queued. You can run an instant dependency and prompt-injection check now with the "Scan for vulnerabilities" button above.
Clone the repository with "git clone https://github.com/ZeKaiNie/universal-examprep-skill" and add it to your Claude Code skills directory (see the Installation section above). universal-examprep-skill ships a SKILL.md manifest, so compatible agents can discover and load it automatically.
universal-examprep-skill is primarily written in Python. It is open-source under ZeKaiNie on GitHub, so you can review or fork the full source.
Yes. SkillsLLM lists many other AI Agents skills you can browse and compare side by side. Open the AI Agents category from the badge at the top of this page, or use the Related Skills and comparison links further down to weigh universal-examprep-skill against similar tools.
No comments yet. Be the first to share your thoughts!
Unlocks once the catalog security scan passes (runs nightly).
The deep catalog scan for this skill is still queued. Run an instant dependency check now instead.
此技能将 AI 智能体配置为一名以 LLM Wiki 为核心记忆载体的极速备考专家。通过本地物理文件切片、标准题库抽题和一键式冷启动,在保证 100% 物理防幻觉的同时,将长对话的 token 消耗降低 90%。
当用户导入一个科目的复习资料(如:复习大纲、教材章节、微信划重点图片或历年真题)时,智能体必须严格按照以下五步法启动辅导:
ingest.py 要求的 raw_input.json 格式数据,并将其以 raw_input.json 写入到临时目录(例如 scratch/ 目录)中。绝对禁止要求或提示用户去手动创建、修改此 JSON 文件。
source_file/source_pages、必要时 assets(放 references/assets/ 下)、requires_assets / maybe_requires_assets、question_text_status(见 docs/file-format.md §4)。只有当你确实把图片文件写到 <工作区>/references/assets/ 后,才设 requires_assets=true 或 maybe_requires_assets=true(ingest.py 不会创建/拷贝该目录,要你自己写盘);只有原页引用、没有图片时用 question_text_status="page_reference" 且不设视觉必需标记。这样测验/复盘才不会让学生做看不到图的题。python scripts/ingest.py --input <temp_json_path>(Claude Code 中可用 python "${CLAUDE_SKILL_DIR}/scripts/ingest.py" --input <temp_json_path>)。
parse_report.json 的 warnings 与 skipped、ai_review_manifest.json 的 entries、以及工作区 ingest_report.json 的 missing_answer_ids,逐条处理:能补救的(转存 UTF-8、重命名加 chNN/sol 记号、多模态直读 PDF/图片补录知识点或题目)立即处理;不能补救的必须向学生明确说明哪些材料未导入、为什么。严禁静默略过任何一条——程序侧的每一条警报都默认「AI 会接手」,你不接手它就永远丢了。~/.claude/skills/universal-exam-cram-coach/ 或项目内 .claude/skills/universal-exam-cram-coach/;早先文档中的 .agents/skills/ 仅是 Codex/Cursor 的约定,Claude Code 不会扫描该路径。python is not recognized 或环境限制),智能体 必须立即且无感地自动执行降级逻辑:write_to_file / write_file 工具,手动在工作区创建 references/wiki/ 目录,将章节知识切片分别写入 ch1_xxx.md 等,写入 references/quiz_bank.json,并依据 templates/ 目录下的模板生成 study_plan.md 与 study_progress.md。study_state.json(一条命令:update_progress.py set --mode <模式> --time-budget <档> --language <语言>):
mode):零基础从头讲(从第一章第一个知识点顺讲,讲完即把该点全部关联题从易到难讲透)/ 某章起步补弱(已会章节罗列知识点各配一道较难题、不会的按零基础展开)/ 查缺补漏(全章知识点各一道较难题,困惑再展开)。time_budget,叠加在模式上,决定提问节奏):≤1天 / 1-3天 / 3-7天 / >7天。language):English(缺省——学生用中文开场则 中文)/ 中文 / 双语——提问时语言行三语呈现「语言 / Language:中文 / English / 双语」,模式/档位选项在语言确定前附英文对照(首问是唯一允许的混语言点——语言未定时英文学生也要能读懂选项);别名(zh/en/bilingual 等)由脚本归一。零基础从头讲 + ≤1天 + 学生开场所用语言;绝不推断 双语——双语只能显式选择或会话中 set --language 双语 切换)后立即开讲。在 ≤1天 档,向用户提任何澄清/偏好问题本身就是违约(浪费复习时间)。update_progress.py window-add / window-set-status,存 knowledge_window);>7天 窗口外的点用对应难题实测(会→归窗口、不会→重讲)。normal/sprint/panic/mock 由 set --mode 自动迁移并警告(panic→零基础从头讲+≤1天、sprint→查缺补漏+1-3天、normal/mock→查缺补漏)。模式/宽裕度显示在进度面板,与「讲解模板」偏好(preferences)分离。view_file 工具读取该阶段关联的 Wiki 文件(例如 references/wiki/ch1_concepts.md)。严禁一次性读取或将全书知识塞入上下文。skills/exam-tutor/SKILL.md):
[lecture03.pdf 第 12 页](../lecture03.pdf#page=12));来源不明就如实写「来源未知」,绝不编造。题目来源:…|答案来源:…|<🟢/🟡/⚠️ canonical 标签>,默认输出到此为止。【易错点】/【3分钟速记】/【现在轮到你】默认不输出,仅学生主动要求或已存偏好时才给(旧版【考点拆解】/【标准答题模板/步骤】已并入 ②/④⑤,不再单列)。学习目标不变:「能在考场上默写出这道题的答题框架」。study_state.json 的 preferences(update_progress.py set --pref 讲解模板=…,与 --mode 分离),进度面板 ⚙️ 偏好区随时可见、随时可改。references/quiz_bank.json 中过滤并提取属于当前章节的题目。禁止现场随机编造不符合大纲的题目。
fail-closed:题项可带 requires_assets / maybe_requires_assets / assets / question_text_status(见 docs/file-format.md §4)。出 requires_assets=true 或 maybe_requires_assets=true 的题前,必须先把所有题面侧图片(question_context/figure/diagram/table)真正渲染/显示出来给学生看,并标成「题面图」(图片替代文本与可见说明都用它);只打印路径不算。不得先显示答案侧图片(answer_context/worked_solution),答案侧图片只能在解答/复盘阶段、题面图已显示之后再展示,并标成「答案图」。图缺失/不可读、Markdown 链接不渲染、路径写成斜杠开头的盘符伪路径这类无法显示格式、或网页端无法显示图时,绝不出这道题,改从题库另选 full 全文题;不得假装图片已经展示。stub/page_reference 题须先呈现原页/资源上下文,无法呈现则跳过。source_type 的题在限定范围内一律排除并报告数量(官方选题工具 scripts/select_questions.py)。scripts/select_hard_questions.py——按 难度(scripts/score_difficulty.py 的结构启发式下界,非语义)× 错题/疑难/知识点窗口掌握状态 × 学习模式 确定性排序(查缺补漏 薄弱点先易后难→已掌握点先难;零基础全局先易后难);默认全库,检查点务必带 --chapter <当前章>(--from-chapter N 是「≥N 的所有章」,只给「某章起步补弱」用,别拿来做检查点);范围/越界声明照常生效(--source-type all 可一次性覆盖为混合池,须先声明)。study_state.json 时它是唯一事实源——一律经 scripts/update_progress.py 更新(set/add-mistake/add-confusion/render),study_progress.md 是生成视图、严禁手改(下次渲染即丢);状态写入失败必须告知用户,绝不当作已保存继续。状态文件缺失时先分辨两种情况:Python 可用(新建工作区尚未初始化)→ 先跑 python "${CLAUDE_SKILL_DIR}/scripts/update_progress.py" --workspace <ws> init 建立事实源再更新(脚本按技能包根解析——学生工作区里没有 scripts/),别停在手改 study_progress.md 的路径;真无法运行 Python 才降级为手写 study_progress.md(照常有效)。keywords 和解题步骤,只要意思对即判定通过,给出相似度反馈。type: "diagram"):若题目类型为画图题(如二叉树/平衡二叉树旋转、红黑树、B 树、图遍历、哈夫曼树、状态机等),智能体禁止凭记忆手绘或用文字脑补最终图形,必须遵循以下流程,让图的正确性由确定性程序保证:
matplotlib / graphviz 等),真实运行得到结构,再渲染成图片供学生查看。绝不直接「想象」最终形态。explanation(解析)及提示。study_state.json 时从其 mistake_archive/confusion_log 读取(事实源;study_progress.md 是可能过期的生成视图),否则读 study_progress.md——再重新调取 references/quiz_bank.json 中的原题,进行扫雷测试。重做错题时同样遵守第三步的「依赖图的题视觉优先 + fail-closed」门禁:requires_assets=true / maybe_requires_assets=true / stub / page_reference 的错题,须先把题面侧图/原页上下文真正显示出来;显示不了就跳过,不让学生重做一道看不到题面的题。walkthrough.md,内含该科目的考前极简速记小抄。本技能强制推行以 LLM Wiki 为基础的物理文件锁定规则,以根除计算/知识幻觉:
references/wiki/):
references/quiz_bank.json):
study_state.json / study_progress.md):
study_state.json(结构化状态)时它是唯一事实源——一律经 python "${CLAUDE_SKILL_DIR}/scripts/update_progress.py"(set / add-mistake / add-confusion / set-*-status / set-check)更新,study_progress.md 会自动重渲染、严禁手改;无状态文件时:Python 可用就先跑 python "${CLAUDE_SKILL_DIR}/scripts/update_progress.py" --workspace <ws> init 建立事实源再更新(ingest.py 新建的工作区只有 study_progress.md、没有状态文件,正是这一步补上),真无法运行 Python 才直接更新 study_progress.md。每次会话重启时,第一步先读 study_state.json(存在时),否则读 study_progress.md,以此重置 AI 的记忆位置。本技能的防幻觉地基是「把 AI 锁死在 Wiki 文件里」。但 Wiki 与答案的内容可能有两个来源:学生上传的资料,或 AI 自己补充的背景知识。若不加区分,学生会把 AI 编的内容当成老师的重点,这本身就是一种幻觉。因此智能体必须对每一段知识与每一个答案标注来源:
[来自教材] / [AI补充]),让学生一眼分清哪些必须信、哪些要核对。study_state.json language 单语言派发:中文(缺省=简体中文,零英文)/ English(零中文,用英文规范词表)/ 双语(逐块 中文 前置 + > EN: 英文镜像、每侧各自单语言)。持久化文件与脚本输出在所有模式下保持中文规范词汇(机器词汇,不随学生语言漂移);面向代理的控制指令保持英文、精确。完整语言策略(含单语言纯净原则与英文词表)见 docs/language-policy.md;子技能文件里的旧版英文渲染示例正分批对齐本口径,对齐完成前一律以该策略文件为准。若用户在纯网页端(无法读写本地文件、无法运行 Python 脚本的环境,如 Claude 的项目或网页版 ChatGPT)使用此技能,请遵循以下流程运行:
quiz_bank.json,并指示用户手动将其作为“挂载文件/知识库文件”上传到当前的网页会话中。study_progress,并开始对应阶段的复习”。为便于移植与维护,本技能的行为也被整理成了 skills/ 下的可移植技能集合,但既有用法与行为完全不变:
SKILL.md)仍是默认 / 兼容入口,承载完整防编题与来源标注规则;已经安装本技能的用户无需做任何改动。skills/exam-cram/SKILL.md;它与本文件描述的是同一套行为。exam-ingest(建库)/ exam-tutor(授课)/ exam-quiz(抽题判分)/ exam-review(复盘)/ exam-cheatsheet(小抄)/ exam-audit(只读体检)/ exam-help(速查)/ confusion-tracker(概念疑难追踪),均在 skills/ 下。AGENTS.md(一屏防幻觉浓缩契约)。docs/skill-architecture.md 与 docs/agent-portability.md。One night left. You studied nothing. It won't make anything up.
English · 中文
Never fabricates: 100% honest abstention · in-your-materials-not-the-model's-head 11% → ~99% · context −90% · 6 agents
You know him. Night before the exam, hair a mess, eyes wide open, hasn't read a single page of the course. This skill is for him — it doesn't pour in more "knowledge" that it isn't sure about; it teaches only what's actually in your materials, and says "not in the materials" for everything else.
30-second start — clone the repo, then say one line to your agent:
git clone https://github.com/ZeKaiNie/universal-examprep-skill .claude/skills/universal-exam-cram-coach
# In Claude Code / Cursor, say: "use this skill to set up my exam-prep space", then drop in your materials
With the skill — every claim carries its source, so you can check it:
[#vis_q1] In the figure, which set relation does the shaded region show? The intersection of A and B.
Question: hw02.pdf p.3 | Answer: hw02_sol.pdf | 🟢 from your materials
Closed-book / plain agent — sounds just as confident, but you can't tell if it's true:
The shaded region is the union. (It's actually the intersection; no source label, nothing to check against — this is where hallucination happens.)
The difference isn't tone. It's whether each claim lands back in your materials.
The skill's value is grounding: connecting what's in your materials but not in the model's head — accurately, and never fabricated. Two real measurements (judge: Sonnet):
① In your materials, not in the model — the skill goes from 11% up to 100%. Details mined from course transcripts (the professor's examples, obscure studies, exact numbers) that world knowledge can't answer; closed-book collapses, hand the materials back and it returns:
| Course · Model | Closed-book | Raw files + generic agent | With the skill |
|---|---|---|---|
| PSYC 110 · Opus 4.8 | 11% | 98% | 100% |
| PSYC 110 · Sonnet 4.6 | 13% | 100% | 100% |
| PSYC 110 · Haiku 4.5 | 11% | 98% | 100% |
| 6.006 · Haiku 4.5 | 45% | 89% | 91% |
② Not in the materials at all — the skill says "not covered" 100% of the time. On out-of-scope probes, with the skill (and raw files) all three models, both courses, abstain honestly 100%; closed-book only 60%–90% (it fabricates a plausible answer). This is the most direct anti-hallucination measure.
The skill matches a "raw files agent" on accuracy but costs less — it pulls only the compressed relevant chapters instead of re-scanning the whole file pile each question:
| Cost / question | Closed-book | Raw files agent | With the skill |
|---|---|---|---|
| PSYC 110 | $0.033 | $0.117 | $0.102 |
| 6.006 | $0.034 | $0.066 | $0.063 |
Full method, three-arm design, judge calibration, cost, limitations → test report.
A ladder of "don't make it up unless you have to":
quiz_bank.json, never improvised.🟢 from your materials / 🟡 AI-supplemented, may differ from your teacher / ⚠️ AI-generated answer, never passed off as the textbook.The skill adapts how deep it teaches, how fast, and whether it asks you questions — all kept in study_state.json, persistent across chats.
3 study modes (how it teaches):
| Mode | For |
|---|---|
| Teach from scratch | Haven't studied at all — walk every chapter from zero, 7-step walkthrough per key question |
| Start mid-course, shore up weak spots | Know some — start from a chapter you name, target the weak parts |
| Fill the gaps | Mostly covered — just quiz to find blind spots, mistakes first |
4 time budgets (how fast):
| Budget | Behavior |
|---|---|
| ≤ 1 day | All-out sprint — never asks you anything, silently infers defaults (teach-from-scratch), goes straight in |
| 1–3 days | Hits the essentials, compresses the rest |
| 3–7 days | Normal pace, asks which chapters you're solid on |
| > 7 days | Relaxed — for chapters you say you know, it quizzes to verify rather than taking your word |
Preferences (remembers your habits): whether walkthroughs append the "common mistakes" / "3-minute recap" closing blocks, reply language (Chinese / English / bilingual), and per-chapter mastery windows (window-add / window-set-status) — all persisted, changed by a single line anytime. See docs/language-policy.md and docs/skill-architecture.md.
git clone https://github.com/ZeKaiNie/universal-examprep-skill .claude/skills/universal-exam-cram-coach
Works from a project-local .claude/skills/ or global ~/.claude/skills/.
Clone the repo; have the agent read AGENTS.md (a one-screen fallback contract) or load skills/. These tools write files and run scripts directly.
Can't write local files — use the drop-in prompt instead: copy prompts/web_prompt.en.md and send it, then paste your materials.
Full load matrix (per-agent support, entry files) in
docs/agent-portability.md. The behavior source of truth isSKILL.md;SKILL.en.mdis its English rendering.
The monolith is split into 9 single-purpose sub-skills the agent loads on demand:
| Sub-skill | What it does |
|---|---|
exam-cram |
Orchestrator — runs the 4-step workflow + study-mode routing |
exam-ingest |
Builds the workspace from your materials (knowledge base + quiz bank + progress) |
exam-tutor |
Lazy per-chapter teaching (7-step walkthroughs, draw-it-runs-algorithm-first) |
exam-quiz |
Draws & grades from the bank (6 question types: MC / short / draw / fill / T-F / code) |
exam-review |
Mistakes and concept-confusion review |
exam-cheatsheet |
Pre-exam cheat sheet |
exam-audit |
Read-only workspace health check |
exam-help |
One-screen quick reference (workflow / modes / file conventions) |
confusion-tracker |
Logs concept questions as you go into a pre-exam blind-spot list |
All nine live under skills/ (e.g. skills/confusion-tracker/SKILL.md), loaded on demand.
Zero-cost structured checks you can run often (no API spend):
python -m unittest discover -s tests -v # unit tests (pure stdlib, in CI)
python scripts/validate_workspace.py path/to/ws # validate a built exam-prep workspace
The real paid benchmark is expensive (tens of dollars / hours per matrix), run manually only — see benchmark/docs/running-real-runs.md and the tiering in benchmark/docs/test_tiers.md. Workspace file format: docs/file-format.md.
No Python installed? Fine. When the agent finds no Python it silently switches to "manual write mode", creating the knowledge-base tree itself — no difference to you.
Only photos / scanned PDFs / a recording? First transcribe with any free web multimodal AI ("extract the highlights and questions as plain text, keep the star/underline markers"), paste into a .txt, then have the agent build the workspace; the rest is plain-text and smooth. Recordings: transcribe first, then feed.
Stuck on one quiz question? Just say "this is too hard / I want to skip" — it files the item to your mistake log, lets you through, and revisits it at the end.
How is this different from just dropping a folder at an AI? Similar accuracy, but the skill is cheaper (only the relevant chapters per question, not the whole pile) and helps weaker models more. See the report.
MIT. PRs for more subjects' templates or scripts welcome. Good luck on the cram. 🎓