Read Ocr logo

Read Ocr

Community
SpaceZephyr
read-ocr

Use this skill when users need to extract text from images, PDFs, or documents. Supports URLs and local files, with adaptive quality modes. Returns structured JSON containing recognized text, confidence scores, and quality metrics.

Overview

PublisherSpaceZephyr
Repositoryread-buddy
Skill nameread-ocr
Stars
85
Forks
25
Bundled files
Instructions only
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by SpaceZephyr on GitHub. Read the source before you install it.

Installation

Install the Read Ocr AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/SpaceZephyr/read-buddy/tree/main/read-ocr
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/SpaceZephyr/read-buddy.git /tmp/read-buddy
mkdir -p .claude/skills
cp -r /tmp/read-buddy/read-ocr .claude/skills/read-ocr
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Read Ocr in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Read Ocr on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Read Ocr is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

PP-OCRv5 API Skill

When to Use This Skill

Invoke this skill in the following situations:

  • Extract text from images (screenshots, photos, scans, charts)
  • Read text from PDF or document images
  • Perform OCR on any visual content containing text
  • Parse structured documents (invoices, receipts, forms, tables)
  • Recognize text in photos taken by mobile phones
  • Extract text from URLs pointing to images or PDFs

Do not use this skill in the following situations:

  • Plain text files that can be read directly with the Read tool
  • Code files or markdown documents
  • Tasks that do not involve image-to-text conversion

How to Use This Skill

Basic Workflow

  1. Identify the input source:

    • User provides URL: Use the --file-url parameter
    • User provides local file path: Use the --file-path parameter
    • User uploads image: Save it first, then use --file-path
  2. Execute OCR:

    bash
    python scripts/ocr_caller.py --file-url "URL provided by user" --pretty

    Or for local files:

    bash
    python scripts/ocr_caller.py --file-path "file path" --pretty
  3. Parse JSON response:

    • Check the ok field: true means success, false means error
    • Extract text: result.full_text contains all recognized text
    • Get quality: quality.quality_score indicates recognition confidence (0.0-1.0)
    • Handle errors: If ok is false, display error.message
  4. Present results to user:

    • Display extracted text in a readable format
    • If quality score is low (<0.5), alert the user
    • If structured output is needed, use result.pages[].items[] to get line-by-line data

Mode Selection

Always use --mode auto (default) unless the user explicitly requests otherwise:

User RequestUse ModeCommand Flag
Default/unspecifiedAuto (adaptive)--mode auto (or omit)
"Quick recognition" / "fast"Fast--mode fast
"High precision" / "accurate"Quality--mode quality

Auto mode (recommended): Automatically tries 1-3 times, progressively increasing correction levels, returning the best result.

Usage Mode Examples

Mode 1: Simple URL OCR

bash
python scripts/ocr_caller.py --file-url "https://example.com/invoice.jpg" --pretty

Mode 2: Local File OCR

bash
python scripts/ocr_caller.py --file-path "./document.pdf" --pretty

Mode 3: Fast Mode for Clear Images

bash
python scripts/ocr_caller.py --file-url "URL" --mode fast --pretty

Understanding the Output

The script outputs JSON structure as follows:

json
{
  "ok": true,
  "result": {
    "full_text": "All recognized text here...",
    "pages": [...]
  },
  "quality": {
    "quality_score": 0.85,
    "text_items": 42
  }
}

Key fields to extract:

  • result.full_text: Complete text for the user
  • quality.quality_score: 0.72+ is good, <0.5 is poor
  • error.message: If ok is false, provides error description

First-Time Configuration

If the user has not configured API credentials, run:

bash
python scripts/configure.py

This will prompt for:

  • API_URL: Paddle AI Studio endpoint
  • PADDLE_OCR_TOKEN: User's access token

Configuration is saved to the .env file, only needs to be configured once.

Error Handling

Configuration missing:

Error: API_URL not configured

→ Run python scripts/configure.py

Authentication failed (403):

error_code: PROVIDER_AUTH_ERROR

→ Token is invalid, reconfigure with correct credentials

Quota exceeded (429):

error_code: PROVIDER_QUOTA_EXCEEDED

→ Daily API quota exhausted, inform user to wait or upgrade

No text detected:

quality_score: 0.0, text_items: 0

→ Image may be blank, corrupted, or contain no text

Quality Interpretation

When presenting results to users, consider the quality score:

Quality ScoreExplanation to User
0.90 - 1.00Excellent recognition quality
0.72 - 0.89Good recognition quality (default target)
0.50 - 0.71Fair recognition quality, may have some errors
0.00 - 0.49Poor recognition quality or no text detected

If quality is below 0.5, mention to the user and suggest:

  • Try using --mode quality for better accuracy
  • Check if the image is clear and contains text
  • Provide a higher resolution image if possible

Advanced Options

Use only when explicitly requested by the user:

Include raw provider response (for debugging):

bash
python scripts/ocr_caller.py --file-url "URL" --return-raw-provider

Request visualization (show detection regions):

bash
python scripts/ocr_caller.py --file-url "URL" --visualize

Adjust auto mode parameters:

bash
python scripts/ocr_caller.py --file-url "URL" \
  --max-attempts 2 \
  --quality-target 0.80 \
  --budget-ms 20000

Reference Documentation

For in-depth understanding of the OCR system, refer to:

  • references/agent_policy.md - Auto mode strategy and quality scoring
  • references/normalized_schema.md - Complete output schema specification
  • references/provider_api.md - Provider API contract details

Load these reference documents into context when:

  • Debugging complex issues
  • User asks about quality scoring algorithm
  • Need to understand adaptive retry mechanism
  • Customizing auto mode parameters

Testing the Skill

To verify the skill is working properly:

bash
python scripts/smoke_test.py

This tests configuration and API connectivity.

Frequently asked questions

What does the Read Ocr AI skill do?

Use this skill when users need to extract text from images, PDFs, or documents. Supports URLs and local files, with adaptive quality modes. Returns structured JSON containing recognized text, confidence scores, and quality metrics.

Why use Read Ocr on TypingMind?

Because you install it once and use it with any model. Read Ocr is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Read Ocr in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/SpaceZephyr/read-buddy/tree/main/read-ocr. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Read Ocr?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Read Ocr?

As many as you like. As long as a model supports skills, you can use Read Ocr with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Read Ocr AI skill free?

It is published on GitHub by SpaceZephyr. Check the repository for licensing terms. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇