# OCR a reMarkable PDF
Transcribe the most recent PDF in `plugins/remarkable/` and save the results to a
note in `plugins/claude-output/`.
## Steps
1. **Find the latest PDF.** List `plugins/remarkable/` sorted by modification time
and pick the newest `.pdf`. (`ls -lat <vault>/plugins/remarkable/` — ignore
non-PDF files, sync logs, and subfolders.)
2. **Get the page count and render each page to an image.** Use `pdfinfo` for the
page count, then `pdftoppm -r 200 -png <pdf> <prefix>` to render every page to
PNG. Render at ~200 DPI for legible handwriting. (reMarkable PDFs may emit
harmless `ExtGState 'GSa' is unknown` warnings — ignore them.)
3. **Read every page image and OCR it.** Open each PNG with the Read tool so the
page is visually inspected. For each page:
- Transcribe **all** text faithfully — handwritten cursive, handwritten print,
and printed text alike. Preserve math notation, symbols, and layout where it
matters (use inline code/LaTeX-style for formulas).
- For **diagrams**, write a clear prose description: what is drawn, how elements
connect, and any labels. Describe each distinct diagram separately.
- Note the ink color or visual grouping if it helps distinguish sections.
4. **Write the findings to a note.** Save a markdown note in
`plugins/claude-output/` using **the same base filename as the source PDF**
(e.g. `2026-06-21 Noel.pdf` → `2026-06-21 Noel.md`). Structure it with:
- YAML frontmatter recording the `source` path and `created` date.
- A "Transcribed text" section (broken out per page).
- A "Diagram descriptions" section.
- Any closing notes/context.
5. **Verify and present.** Confirm the note was written, then present the file to
the user.
## Notes
- Paths: the vault's remarkable folder is `plugins/remarkable/`; output goes to
`plugins/claude-output/`.
- Always preserve the original PDF; this skill only reads it.
- If the PDF has many pages, render and transcribe them all, page by page.
- If a page is blank, say so rather than omitting it.