lex-document-ocr

Extract and structure legal data from PDFs and images into JSON or Markdown.

Updated Aug 27, 2026
One-click install
npx skills add https://github.com/fbmoulin/lex-intelligentia-skills --skill lex-document-ocr
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: lex-document-ocr
Source: https://github.com/fbmoulin/lex-intelligentia-skills/tree/main/skills/automacao/lex-document-ocr
Command: npx skills add https://github.com/fbmoulin/lex-intelligentia-skills --skill lex-document-ocr

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

This Skill automates the extraction, structuring, and analysis of legal documents in PDF and image formats, significantly reducing manual data entry and review time for legal professionals.

Core Features & Use Cases

  • Multi-format OCR: Extracts text from scanned and digital PDFs, images, and even handwritten notes.
  • Structured Data Extraction: Identifies and extracts key legal entities and fields (e.g., process numbers, party names, dates, contract clauses) based on document type.
  • Document Type Specialization: Tailored extraction schemas for certificates, petitions, decisions, contracts, and official publications.
  • Integration Ready: Designed to integrate with automation platforms like n8n for batch processing.
  • Use Case: Upload a scanned court petition, and the skill will extract the case number, parties involved, court, and key claims into a structured JSON format.

Quick Start

Use the lex-document-ocr skill to extract and structure the information from the attached scanned court decision.

Frequently Asked Questions about lex-document-ocr

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I extract text from scanned Brazilian legal documents in PDF format?

You can extract text from scanned Brazilian legal PDFs using multi-layered OCR and AI models that recognize entities like process numbers and party names, outputting the results as structured JSON or Markdown files.

Can I use n8n to automate batch processing of legal document images?

Yes, you can automate batch processing of legal document images by integrating the extraction workflow with n8n, allowing you to handle multiple scanned petitions, certificates, and contracts automatically.

What is the best way to structure data from court petitions and official gazette publications?

The best way to structure data from court petitions and official gazettes is using AI-driven entity recognition to extract case numbers, dates, and claims into tailored schemas formatted as JSON.

Does AI OCR work for extracting key fields from handwritten legal notes and contracts?

AI OCR effectively extracts key fields and clauses from handwritten legal notes and contracts by leveraging specialized extraction schemas designed for various Brazilian legal document types.

How does entity recognition handle different Brazilian legal document types like certificates and decisions?

Entity recognition handles different Brazilian legal document types by applying tailored extraction schemas that specifically identify and normalize fields relevant to certificates, decisions, and contracts.

What output formats are generated when processing legal documents with AI?

Processing legal documents with AI generates normalized output in JSON or Markdown formats, ensuring that extracted entities and text from PDFs and images are structured for immediate integration.