agentleFS
texra-aitexra-ai/texra-scientific-skills/skills/math-ocr/SKILL.md

math-ocr

Skill4 starsChanged 7 months agoMITView on GitHub

Convert handwritten or image-based mathematical content into notation-consistent LaTeX. Use when Codex needs to transcribe equations from notes, screenshots, whiteboards, or scans, reconcile ambiguous symbols against an existing document, or clean up OCR output into compilable mathematical LaTeX.

The file

We split this skill into the rules it gives an agent

6 rules. About 0 are common, 6 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈6

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this skill when the input is handwritten math, a screenshot of equations, or rough symbolic content that must become clean LaTeX …

    line 10
  2. Distinctive:

    Read the surrounding LaTeX context first when it exists.

    line 14
  3. Distinctive:

    If the expression belongs inside a larger derivation, preserve the intended structure rather than producing a flat symbol dump.

    line 18
  4. Distinctive:

    Ensure delimiters, fractions, and indices are syntactically sound and compile cleanly.

    line 25
  5. Distinctive:

    Prefer standard LaTeX environments already used by the target document.

    line 26
  6. Distinctive:

    Call out unresolved ambiguity instead of silently inventing a precise symbol.

    line 27

≈ “Common” is an estimate: at least 1 in 5 of the 372,429 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.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Math OCR

When to use this skill

Use this skill when the input is handwritten math, a screenshot of equations, or rough symbolic content that must become clean LaTeX matching an existing paper, note set, or slide deck.

Workflow

  1. Read the surrounding LaTeX context first when it exists. Reuse the document's notation, macro names, environment style, and equation conventions.
  2. Inspect the image carefully before transcribing. Identify ambiguous glyphs, line breaks, superscripts, subscripts, delimiters, and alignment structure.
  3. Translate math into the simplest correct LaTeX that matches the target document's style.
  4. Mark uncertainty mentally and resolve it against context instead of guessing in isolation.
  5. If the expression belongs inside a larger derivation, preserve the intended structure rather than producing a flat symbol dump.
  6. Review the transcription once for likely OCR confusions such as similar letters, missing braces, swapped indices, or incorrect nesting.

Quality Bar

  • Notation consistency beats literal shape matching when the handwriting is ambiguous.
  • Preserve mathematical structure, not just token order.
  • Ensure delimiters, fractions, and indices are syntactically sound and compile cleanly.
  • Prefer standard LaTeX environments already used by the target document.
  • Call out unresolved ambiguity instead of silently inventing a precise symbol.

For ambiguity-heavy input, use references/ocr-checklist.md when the handwriting is messy, symbols are overloaded, or the result must fit strict manuscript notation.

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.