Extract JSON from PDFs with Natural Language Using Unstract – No More Regex
Unstract is an open‑source platform that lets you describe desired fields in plain language and leverages LLMs to turn invoices, bank statements, KYC forms and other unstructured PDFs into clean JSON ready for database ingestion, eliminating the need for regex or custom templates.
Why traditional extraction falls short
Invoices, bank statements, KYC forms and tax documents often exist as PDFs, but downstream systems require the data in structured JSON for databases. Historically this required hand‑crafted regular expressions, custom templates, per‑vendor model training, or costly commercial APIs.
Unstract’s LLM‑driven approach
Unstract is an open‑source project that replaces those pipelines with a large language model. Users upload a document and receive a JSON object directly. The core idea is to describe the desired fields in natural language and let the LLM perform the extraction.
Typical use cases
Finance, insurance, medical, and KYC/compliance teams—any workflow that must pull data from unstructured documents—can adopt Unstract.
How it works
Prompt Studio is the entry point. Users write a prompt that defines the extraction schema, for example “invoice total amount, invoice date, supplier name”, then run the job. The system supports PDF, image files, scanned documents, and even handwriting, depending on the underlying LLM’s capabilities. The output is a clean JSON object that can be inserted straight into a database.
Deployment options
API deployment : send a REST request and receive JSON.
ETL pipeline : pull documents from a folder and automatically write results to a data warehouse.
MCP server : integrate with Claude or other AI agents.
n8n node : embed directly into existing automation workflows.
Supported models and sinks
Unstract works with almost any LLM – OpenAI, Anthropic, Bedrock, Gemini, Mistral, Ollama (local) and more. Extraction results can be sent to S3, GCS, Snowflake, BigQuery, Postgres, MySQL, etc.
Architecture overview
┌────────────────────────────────────────────────────────────┐
│ Unstract │
├─────────────┬─────────────┬─────────────┬──────────────────┤
│ Frontend │ Backend │ Worker │ Platform Service │
│ (React) │ (Django) │ (Celery) │ (FastAPI) │
├─────────────┴─────────────┴─────────────┴──────────────────┤
│ Cache (Redis) │
├────────────────────────────────────────────────────────────┤
│ Message Queue (RabbitMQ) │
├────────────────────────────────────────────────────────────┤
│ Database (PostgreSQL) │
├────────────────────────────────────────────────────────────┤
│ LLM Adapters │ Vector DBs │ Text Extractors │
│ (OpenAI, etc.) │ (Qdrant, etc.) │ (LLMWhisperer) │
└────────────────────────────────────────────────────────────┘Quick start (5 minutes)
git clone https://github.com/Zipstack/unstract.git
cd unstract
./run-platform.shThen open http://frontend.unstract.localhost in a browser; the default username and password are both unstract.
Repository: https://github.com/Zipstack/unstract
Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
AI Engineering
Focused on cutting‑edge product and technology information and practical experience sharing in the AI field (large models, MLOps/LLMOps, AI application development, AI infrastructure).
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
