Layout Analyzer for Openclaw

Analyze and detect document structures, text blocks, tables, and reading order using the surya document understanding system.

lijie420461340
v1.0.0
Jan 30, 2026
0
0
0

Install & Download

1. ClawHub CLI

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

npx clawhub@latest install layout-analyzer

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 layout-analyzer 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 Layout Analyzer?

The Layout Analyzer is a specialized tool designed to bring deep document understanding to your AI workflows. As a featured part of the Openclaw Skills ecosystem, it leverages the surya library to accurately identify and classify structural elements within images and PDFs. This includes everything from standard text paragraphs and titles to complex components like mathematical formulas, tables, and figures.

Beyond simple detection, this skill excels at understanding the context of a page. It can determine the logical reading order in multi-column layouts, making it indispensable for digitizing academic papers, legal documents, or news articles. By providing precise bounding boxes and classification labels, the Layout Analyzer transforms raw pixels into structured, actionable data for downstream processing.

Layout Analyzer Use Cases

  • Extracting structured data from multi-column academic journals and research papers.
  • Identifying and cropping table regions for automated financial data entry.
  • Defining logical reading sequences for screen readers or text-to-speech applications.
  • Automating form field detection and document classification for enterprise archives.

How Layout Analyzer Works

  1. The user provides a document in image format (PNG/JPG) or a PDF file.
  2. The skill initializes the surya LayoutPredictor to analyze the spatial structure of the document.
  3. Detected regions are classified into specific types such as Section-header, Table, or Figure.
  4. If requested, the ReadingOrderPredictor determines the sequence in which a human would read the text.
  5. The skill returns a detailed metadata object containing bboxes, labels, and confidence scores for each element.

Layout Analyzer Setup

To integrate this capability into your project using Openclaw Skills, you must install the surya-ocr package and its dependencies. For PDF support, pdf2image is also required:

pip install surya-ocr pdf2image

Ensure you have the appropriate model weights downloaded as specified in the surya documentation for optimal performance.

Layout Analyzer Data Schema & Taxonomy

The Layout Analyzer organizes its findings into a structured taxonomy. Below is the primary data organization:

Element Type Description
Text Regular paragraph or body text
Title / Section-header Main titles and hierarchical headings
Table / Figure Tabular data regions and graphical illustrations
Formula Mathematical and scientific equations
Page-header / Footer Recurring elements at the top or bottom of pages
Bounding Box (bbox) [x1, y1, x2, y2] coordinate array of the region

Layout Analyzer Advanced Features

  • Hierarchical document structure extraction for mapping titles to their respective sections.
  • Multi-column logic that intelligently groups elements into left, right, or full-width columns.
  • Confidence-score filtering to ensure only high-accuracy detections are used in production.
  • Integrated OCR bridging to map specific text content to its corresponding layout block.
  • Visualization hooks to export annotated images showing the detected structure.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*