universal-pdf-study
Skill0 starsChanged 7 days agoMITView on GitHub
Inspect, OCR, render, crop, white-halo annotate, generate SVG image-occlusion masks, and co-pilot live interactive study from any research paper, textbook, slide deck, or scanned PDF.
In this repository18 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- chapter-autopilotSkill
- exam-simulatorSkill
- grade-handwritingSkill
- harness-self-improveSkill
- ingest-chapterSkill
- knowledge-graphSkill
- manim-animatorSkill
- organic-chemistry-tutorSkill
- physical-chemistrySkill
- physics-circuits-and-unitsSkill
- practice-drillSkill
- revision-sheetsSkill
- subagent-orchestratorSkill
- teach-chapterSkill
- topic-onboardingSkill
- visual-and-demoSkill
The file
We split this skill into the rules it gives an agent
7 rules. About 0 are common, 1 is distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 13
Use syntopik run pdf_studio ...
- Distinctive: line 20
Use Mode A by default whenever the learner brings a paper, slide deck, textbook chapter, handwritten note PDF, or problem sheet to …
- Very specific: line 27
Teacher-First Law: if instructor lecture/whiteboard notes are paired with a textbook or exercise bank, follow the instructor's contiguous …
- Very specific: line 30
Medium (
11–40pages): check tree-index, extract only target ranges, and visually inspect flagged needs_vision pages (<= 6 rendered pages … - Very specific: line 33
Put cropped figures directly into the lesson with crisp white-halo (DejaVuSans-Bold) callouts — and pass --occlude whenever a labeled …
- Very specific: line 46
Mandatory Unlooked-Finish Gate: ALWAYS inspect --out-png via read_file / Read BEFORE showing the learner.
- Very specific: line 55
Use ONLY on explicit request to map/outline a full chapter, paper, or problem pack into chapters/<slug>.md — follow …
≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Universal PDF Studio — Live Co-Piloted Reading, OCR, Callouts & SVG Occlusion
Standard text extractors silently drop scanned/handwritten pages and mangle equations, circuits, plots, and architecture diagrams — while dumping a 150-page PDF into chat blows up context and focus. Never dump a whole raw PDF into chat.
Use syntopik run pdf_studio ... (or .venv/bin/python -B scripts/pdf_studio.py ... in direct clones) across every harness.
Dual Entry Modes
Mode A — Live Co-Piloted Study (DEFAULT)
Use Mode A by default whenever the learner brings a paper, slide deck, textbook chapter, handwritten note PDF, or problem sheet to understand concepts or solve exercises interactively. Do NOT stall to write a giant static chapters/<slug>.md summary first.
- Triage First (
inspect—< 2s, NEVER read/render before this):
Reportssyntopik run pdf_studio inspect "sources/<file.pdf>"size_class(short <= 10p,medium 11..40p,long > 40p),recommended_strategy,visionPages, and per-pagekind,images,math_density(0.0..1.0), andneeds_vision(kind == "image-only"ORimages > 0ORmath_density >= 0.03).- Teacher-First Law: if instructor lecture/whiteboard notes are paired with a textbook or exercise bank, follow the instructor's contiguous page order (
p.1 → p.N) as the#1spine.
- Teacher-First Law: if instructor lecture/whiteboard notes are paired with a textbook or exercise bank, follow the instructor's contiguous page order (
- Size-Tiered Reading Doctrine (Zero Context Bloat):
- Short (
<= 10pages):extractall pages; visually inspect everyneeds_visionpage viarender+read_file/Read. - Medium (
11–40pages): checktree-index, extract only target ranges, and visually inspect flaggedneeds_visionpages (<= 6rendered pages per pass). For> 15-page spans, delegate to a background subagent (invoke_subagent/Agent/spawn_agent) returning a 2–6 sentence(p. N)-cited brief +Pages consulted:list (never summarize unread pages!). - Long (
> 40pages): never read front-to-back. Runtree-index+searchfirst, then extract and visually read ONLY hit pages.
- Short (
- Crop, White-Halo Annotate & 1-Click SVG Image Occlusion (
annotate [--occlude]) + Vision Gate: Put cropped figures directly into the lesson with crisp white-halo (DejaVuSans-Bold) callouts — and pass--occludewhenever a labeled diagram, circuit, pathway, or architecture figure should double as an interactive spatial recall flashcard:syntopik run pdf_studio annotate \ --pdf "sources/<file.pdf>" --page 7 --crop 0.08,0.12,0.92,0.68 --dpi 260 \ --marks '[{"type":"arrow","from":[0.20,0.28],"to":[0.46,0.52],"label":"Key invariant","color":"#e11d48"},{"type":"box","rect":[0.55,0.40,0.82,0.72],"label":"Bottleneck stage","color":"#2563eb","propId":"systems/bottleneck"}]' \ --occlude \ --out "sources/_extracted/<slug>/fig-p7-ann.svg" \ --out-png "sources/_extracted/<slug>/fig-p7-ann.png" \ --out-html "sources/_extracted/<slug>/fig-p7-ann.html" \ --title "Page 7 — Annotated Figure" --json- Marks (
0..1normalized default, or"coords": "px"):arrow,box,circle,label. Also accepts--image "<photo.jpg>". --occludeOutput: emits declarative SVG occlusion JSON (masks: [{id, bbox, label, propId}]) alongside the white-halo PNG/SVG, ready to attach directly toproposition.media/srs_engine.py add-cuefor clickable reveal masks in Syntopik Studio,dashboard.html(syntopik serve), and Anki Image Occlusion export!- Mandatory Unlooked-Finish Gate: ALWAYS inspect
--out-pngviaread_file/ReadBEFORE showing the learner; adjust coordinates if any label or mask clips or misses its target. - Multi-Harness Inline Display:
- Antigravity 2.0: write
--out-htmlto<artifactDir>/<slug>-fig.htmlviawrite_file(ArtifactMetadata: {UserFacing: true, RequestFeedback: false}) and embed<agent-embed src="file:///<artifactDir>/<slug>-fig.html"></agent-embed>directly above your prompt. - Claude Code / Codex / Other Agents: display/link the verified PNG/SVG (
sources/_extracted/<slug>/fig-p7-ann.png) or HTML artifact, referencing callout labels by name in<= 160words of prose!
- Antigravity 2.0: write
- Marks (
- Immediate Live Transition: step straight into
teach-chapterorpractice-drillciting(p. N).
Mode B — Full Chapter / Paper Map Ingestion
Use ONLY on explicit request to map/outline a full chapter, paper, or problem pack into chapters/<slug>.md — follow .agents/skills/ingest-chapter/SKILL.md (Mode B).
Core pdf_studio.py Reference
syntopik run pdf_studio inspect "sources/<file.pdf>"
syntopik run pdf_studio tree-index "sources/<file.pdf>"
syntopik run pdf_studio search "sources/<file.pdf>" "raft leader election"
syntopik run pdf_studio extract "sources/<file.pdf>" --pages 1-15 --dpi 180
syntopik run pdf_studio tables "sources/<file.pdf>" --pages 1-5
syntopik run pdf_studio render "sources/<file.pdf>" --pages 7 --dpi 260 --crop 0.0,0.45,1.0,0.95extract outputs clean Markdown (pymupdf4llm with C-stdout chatter silenced), runs offline RapidOCR (Tesseract fallback) on image-only pages, renders needs_vision PNGs, and extracts embedded figures.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

