GLM-OCR Text Extraction for Openclaw

A professional-grade OCR skill for extracting structured text, LaTeX formulas, and complex tables from images and PDF documents.

jaredforreal
v1.0.4
Apr 15, 2026
2
1.9k
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install glmocr

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install glmocr using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is GLM-OCR Text Extraction?

The GLM-OCR skill is a high-performance document parsing utility designed for the Openclaw Skills ecosystem. It leverages the GLM-OCR layout parsing API to transform visual data—including screenshots, photos, and scanned PDFs—into clean, actionable Markdown text. Unlike standard OCR tools, this skill excels at preserving document structure, making it ideal for developers and researchers who need to digitize complex layouts.

By integrating this skill into your workflow, you gain access to state-of-the-art recognition capabilities for handwriting, mathematical notations, and multi-column document structures. It serves as a reliable bridge between physical or static digital documents and your AI-driven automation pipelines, ensuring that no data is lost in translation.

GLM-OCR Text Extraction Use Cases

  • Converting screenshots of code or documentation into editable Markdown text.
  • Digitizing handwritten notes and archival documents with high precision.
  • Extracting complex tables from financial reports and converting them directly to Markdown format.
  • Parsing academic papers to capture LaTeX-formatted mathematical formulas accurately.
  • Automating the processing of scanned PDF invoices or receipts for data entry.

How GLM-OCR Text Extraction Works

  1. The user provides a local file path or a remote URL pointing to an image (PNG, JPG) or a PDF document.
  2. The Openclaw Skills runner executes the GLM-OCR CLI script with the specified input parameters.
  3. The skill sends the document to the GLM-OCR layout parsing API for deep analysis.
  4. The API identifies text blocks, tables, and formulas, applying layout recognition to maintain logical flow.
  5. The skill returns a structured JSON response containing the extracted text in Markdown and raw layout details.

GLM-OCR Text Extraction Setup

To get started with GLM-OCR in your Openclaw Skills environment, follow these steps:

  1. Obtain your API key from the Zhipu AI Platform.
  2. Configure the skill using the provided setup utility:
# Replace YOUR_KEY with your actual Zhipu API key
python scripts/config_setup.py setup --api-key YOUR_KEY
  1. Ensure the ZHIPU_API_KEY is available in your environment variables.

GLM-OCR Text Extraction Data Schema & Taxonomy

The skill produces a structured JSON output to ensure compatibility with downstream AI agents. The following table describes the primary fields:

Field Type Description
ok Boolean Indicates if the extraction process was successful.
text String The primary extracted content formatted in Markdown.
layout_details Array Detailed coordinates and structural metadata of the document layout.
source String The original path or URL of the processed file.
error String/Null Contains error details if the extraction failed.

GLM-OCR Text Extraction Advanced Features

  • Formula Extraction: Automatically detects and converts mathematical symbols into LaTeX syntax.
  • Table Recognition: Intelligent detection of tabular data, rendering it into standard Markdown tables.
  • Handwriting Support: Specialized model training for high-accuracy recognition of non-printed text.
  • Flexible Input: Supports seamless switching between local file processing and remote URL fetching.
  • Pretty-Print Mode: Optional flag to output human-readable JSON for easier debugging during development.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*