/paideia:course-builderfrom paideia
Ingests course materials (lecture notes, textbook chapters, HW problems/solutions) and builds a structured knowledge base with patterns, coverage maps, and topic summaries. Invoked via /ingest and /analyze.
Ships in paideia. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
This skill turns raw course materials into a structured knowledge base that downstream drilling commands (/twin, /blind, /chain, /pattern, /hwmap) can query. It is domain-general — the same pipeline works for a Linear Algebra course as for a Quantum Mechanics course.
Two-phase pipeline:
Phase 1: /ingest
materials/**/*.pdf → converted/**/*.md (via pdf skill)
materials/**/*.md → (copied as-is)
Phase 2: /analyze
converted/** + materials/*.md → course-index/patterns.md
course-index/coverage.md
course-index/summary.md
/ingest or /analyze/twin, /blind, /pattern, /hwmap) need course-index/ data that doesn't exist yetScan materials/ recursively. Classify each file by path and extension:
materials/lectures/*.pdf|.md — lecture notesmaterials/textbook/*.pdf|.md — textbook chaptersmaterials/homework/*.pdf|.md — HW problem sets (rename for consistency: hw1.pdf, hw2.pdf, ...)materials/solutions/*.pdf|.md — HW solutions (hw1_sol.pdf, etc.) or worked examplesAmbiguous location (e.g., a PDF in materials/ root)? Ask user once to categorize, then remember.
All .pdf files in materials/** go through the vision pipeline. pdfplumber was tried as a fast path and proved unreliable on course materials — even prose-heavy textbook pages silently word-salad when they mix equations or multi-column figures. Routing everything uniformly through vision is simpler than maintaining per-category heuristics with fallbacks. Full pipeline in skills/pdf/VISION.md; the short form:
skills/pdf/SKILL.md and skills/pdf/VISION.md.dpi=160 (via pdf2image) into converted/<category>/_pages/<stem>/.general-purpose agent per PDF. Each agent reads its own pages sequentially (not in parallel batches — same dimension limit) and transcribes to clean LaTeX markdown ($...$ / $$...$$). Unreadable symbols get [?].converted/<category>/<stem>.md with provenance: <!-- SOURCE: materials/<category>/<stem>.pdf, extracted <YYYY-MM-DD>, method: vision -->._pages/ scratch dirs.For each .md already in materials/: copy to converted/<category>/<stem>.md unchanged with a method: passthrough provenance comment.
If converted/X.md exists and is newer than source, skip unless user passes --force. Log skip count.
After ingest completes, print a summary table:
| Category | Converted | Skipped (already done) | Failed |
|---|---|---|---|
| lectures | N | M | F |
| textbook | ... | ... | ... |
| homework | ... | ... | ... |
| solutions | ... | ... | ... |
And (in INTERFACE_LANG from .course-meta, default en): "Next: run /analyze to generate the patterns / coverage indexes."
This is the core generalization. Given converted/**/*.md (or a subset selected via --files=, --since=, or --lectures-only), produce three index files. Fan-out agents run in parallel batches sized to the concurrency ceiling (~10 slots); a single sequential pass is forbidden. The first batch is capped small (3–4 files) so it provably commits inside the window; later batches widen to the ceiling. When a subset is active, the index reflects a partial re-run — existing entries outside the subset are preserved (merged, not overwritten). The Reduce phase is entered as soon as any batch completes: after each batch, the accumulated index is written atomically to disk (.partial then rename for all three files) before the next batch spawns, so an interrupt always preserves the last committed batch on disk. A --resume invocation reads the on-disk index and the files=A/N COVERAGE line and fans out only the not-yet-processed converted files, merging into the existing index without renumbering existing pattern cards.
course-index/summary.mdTopic tree of the course. Structure:
# Course Summary
## Scope
Inferred from lecture notes: <one paragraph>.
## Topic tree
- §1 <topic>
- §1.1 <subtopic> — covered in: lectures/ch01.md, textbook/ch01.md
- §1.2 ...
- §2 <topic>
...
## Difficulty ordering (inferred from lecture progression)
Early → foundational definitions. Middle → core theorems. Late → applications/advanced.
How to build. Parse section headers (##, ###) from lecture notes, in order. Cross-reference with textbook headers. Use section numbers if present; if not, auto-number by order of appearance.
course-index/patterns.mdRecurring solution techniques extracted from HW solutions and worked examples.
How to extract. For each solution (converted/solutions/*.md and examples in lecture notes):
Format each pattern card:
### Pk. <short name>
**Recognition signal.** <1-2 lines: what triggers this pattern>
**Move.** <1-3 lines: the operation>
**Appears in.** <HW problem IDs, textbook example numbers>
**Topic.** <§ numbers from summary.md>
Target pattern count: 15–30 (too few misses important ones; too many becomes noise). If you find <10, the course is too small or you missed patterns — re-scan. If you find >40, merge similar patterns.
course-index/coverage.mdBidirectional map between HW/example problems and course sections.
Core premise (do not break). HW coverage is a signal of exam probability, not a completeness metric. The professor has already told you, via HW, where the exam will be drawn from: sections with heavy HW emphasis are where the exam points live. Sections with no HW are unlikely to produce problems worth drilling — they become reference-only.
Structure:
## Forward map: problem → sections
| Problem | Primary § | Secondary § | Patterns |
|---|---|---|---|
| HW1-P1 | §2.3 | §2.1 | P1, P3 |
| ...
## Reverse map: section → exam-probability (from HW density)
| § | Title | HW coverage | Exam tier |
|---|---|---|---|
| §2 | ... | HW1-P1, HW2-P3, HW3-P1 | 🔥🔥 Exam-primary |
| §1 | ... | HW1-P2, HW2-P1 | 🔥 Exam-likely |
| §4 | ... | HW3-P5 | 🟡 Exam-possible |
| §5 | ... | — | ⚪ Low-risk (reference only) |
Exam tiers (based on HW problem count targeting the section):
A section in the user's declared weak zones gets a trailing ⚠weak flag after its tier (e.g. ⚪ Low-risk ⚠weak). The flag never upgrades the tier — it is a drill-priority tie-breaker only.
This 🔥/⚪ + ⚠weak vocabulary is the only one. Earlier drafts used ✅✅/✅/🟡/🔴/🔴🔴 "coverage strength" markers in coverage.md; that scheme is retired — hwmap, weakmap, chain, and alt regex on the 🔥 tiers and would not see 🔴 rows.
Do not invert this. Sections with no HW are NOT "blind spots that the exam will bite" — they are sections the professor chose not to test, by omission. Drilling them steals time from exam-primary sections.
At end of analyze, print to chat:
When analyzing, watch for common mathematical patterns (applicable broadly):
And common physics patterns:
These are hints — only add a pattern if it actually appears ≥2 times in the user's solutions.
After a full ingest + analyze run, the paideia directory contains:
converted/ ← all PDFs as MD
course-index/
├── summary.md ← topic tree
├── patterns.md ← P1..Pk recognition cards
└── coverage.md ← HW↔§ map, 🔥 exam tiers + ⚠weak flags
All downstream commands (/twin, /blind, /chain, /pattern, /hwmap) read from these three index files, not from the raw materials. This makes re-analysis cheap (edit index manually if needed) and keeps commands domain-agnostic.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
course-materials, knowledge-base, study-tools, pdf-ingestion
npx claudepluginhub optimeta/paideia --plugin paideia6 skills in this plugin
/alt-importParse an Exam Radar (OPTIMETA Alt plugin) export and fold its lecture-emphasis exam-probability signal into the PAIDEIA course index — write course-index/radar.md, annotate course-index/coverage.md with a lecture-emphasis column and divergence flags, and seed a gold-zone weakmap. Invoked by /paideia:alt. The export form is fixed (exam-radar:v1 marker)./answer-processingUse whenever the user uploads a hand-written or scanned answer PDF to be graded against a reference solution. Converts answer PDFs in `answers/*.pdf` to markdown in `answers/converted/*.md` using the pdf skill (OCR as needed), then performs strategy-based grading against `converted/solutions/*.md` or `quizzes/*_answers.md`. Invoked by `/grade`./exam-drillUse when the user wants exam-focused drilling from the course's analyzed material. Generates twin variants of known problems (`/twin`), runs strategy-level blind drills on known problems (`/blind`), creates integration problems chaining multiple patterns (`/chain`), surfaces pattern cards (`/pattern`), and shows coverage/exam-tier maps (`/hwmap`). Reads from `course-index/patterns.md`, `course-index/coverage.md`, and `converted/solutions/*.md`. Works for any math/physics course that has been ingested and analyzed./pdfUse whenever the user works with PDF files — reading/extracting text from PDFs (lecture notes, textbook chapters, HW problems, HW solutions, hand-written answers), converting PDFs to markdown for downstream analysis, merging/splitting PDFs, or creating PDFs. For scanned or hand-written PDFs, OCR is required (pytesseract + pdf2image). Based on Anthropic's official PDF skill (github.com/anthropics/skills/tree/main/skills/pdf)./vision-ocrUse whenever a hand-written or scanned answer PDF needs transcription to markdown for /grade. Three tiers — Claude native vision (default, no extra install), local Qwen3-VL 8B via ollama (opt-in privacy mode), pytesseract fallback. The engine is selected via `OCR_ENGINE` in `.course-meta` (written by /paideia:init-course) and can be overridden per-call with `/paideia:grade --ocr=<engine>`.Other plugins' skills for the same job