ParseFloe
Local, open-source MCP server that converts PDFs and Office documents to Markdown, extracts PDF text and metadata, and runs offline OCR on scanned PDFs. Uses stdio; no hosted endpoint required.
Documentation
ParseFloe
Documents in. Structured text out.
Private, multi-engine document conversion for browsers and self-hosted edge runtimes.
An experimental open-source document converter for browsers and self-hosted Cloudflare Workers. Convert documents to Markdown, extract native PDF text and page metadata, or recognize scanned PDF text locally with WebAssembly — without a dedicated document-processing server.
Built by ScaleMesh. Part of the LeadsFarmer developer portfolio.
Try ParseFloe Online
Open the free browser converter →
Choose files or a folder, convert them locally with Smart Router (or a manual engine), and download Markdown, text, JSON or a ZIP archive. AnyDoc and LiteParse run in a Web Worker; no server or account is required. The initial parser downloads come from the static site. The browser accepts files up to 50 MiB. Experimental local OCR for scanned PDFs supports 17 languages and combinations of two (up to 20 pages), and extraction quality depends on the document and device. The Cloudflare Worker API remains limited to 5 MiB and has no OCR.
| Capability | ParseFloe Online | Self-hosted Workers |
|---|---|---|
| Document input limit | 50 MiB | 5 MiB |
| Automatic engine selection | Smart Router with PDF inspection and fallback | Manual engine selection |
| Batch conversion | Up to 20 files / 200 MiB total, sequential; ZIP export | Individual API requests |
| Document to Markdown | AnyDoc or Docling.rs | AnyDoc |
| Install / offline pack | PWA in supported browsers | Not applicable |
| PDF native text and JSON | LiteParse, up to 50 pages | LiteParse, up to 50 pages |
| Scanned PDF OCR | Experimental Tesseract.js, 17 languages, up to 20 pages | Not implemented |
| Account or API token | None | Own Cloudflare account and runtime API token |
| Processing location | Your device | Your own Worker |
Privacy: the browser downloads the parser runtime and language assets from the static site. Offline caching is limited to release assets, not documents or results. Documents are processed on the user's device, not uploaded to a conversion service. No shared processing API is involved.
Free tools: PDF to Markdown · Word to Markdown · PDF to JSON · Scanned PDF OCR.
See browser architecture and local development. The 50 MiB limit is an acceptance cap, not a guarantee of successful conversion on every device.
Install and work offline
Open ParseFloe Online, use your browser's Install app or Add to Home Screen option, and explicitly download the offline pack. The app shell is cached automatically; the full pack downloads the local parsing runtimes and OCR assets. The interface verifies cache completeness before reporting offline readiness. Browser storage may be evicted; recheck after updates. Documents and extracted results are not persisted by the service worker.
Smart Router and batch mode
Auto mode routes non-PDFs to AnyDoc (Docling.rs fallback) and inspects PDF pages with LiteParse. Readable native PDFs prefer Markdown; sparse text alone is not treated as sufficient evidence of a scan when the inspection metadata indicates readable text without image or garbling signals. Pages recommended for OCR trigger a native/OCR comparison within the 20-page OCR cap. Smart Router v2 conservatively checks native-word retention and order before replacing usable native Markdown with OCR; it retains a warning when native output may be incomplete. Parsing failures may fall back to Docling.rs or LiteParse native text. If OCR cannot run, warnings indicate the possibility of incomplete output. The JSON routing object records the selected mode and engine, reason, attempts and warnings for successful conversions. This is deterministic routing, not an external AI service or a guarantee of extraction quality. See Smart Router v2 policy and independent validation protocol.
Select up to 20 files or a supported folder (200 MiB total, 50 MiB per file). The browser processes them sequentially to limit concurrent memory use, keeps successful results when another file fails, and exports both text/Markdown and JSON with a manifest in a local ZIP. A 64 MiB estimated retained-output budget limits large batches; this is not a bound on total browser memory use. Cancellation keeps completed results. Choose a completed file to preview and download it individually, or use Download all ZIP. See the usage, routing and ZIP format guide.
Extraction quality indicators and Compare engines
Every browser result now carries a versioned, reference-free quality report with corruption, repetition and available OCR-coverage indicators. Smart Router checks Docling.rs once when AnyDoc output contains severe text corruption. Choose Compare engines to inspect alternative results, timings and word overlap (up to five files, 10 MiB each), then select the output you want to export. The score is a heuristic, not measured accuracy. See the rules and limitations.
International interface and localized tools
ParseFloe Online supports English, French, Spanish, German, Italian, Portuguese, Turkish and Arabic interface languages, including RTL for Arabic. Browser language detection and a manual selector share one local application, preserve conversion results, and do not change OCR language. Localized tool pages are generated at build time with canonical/hreflang links and sitemap entries. See internationalization.
Multilingual OCR
17 locally hosted OCR language models: English, French, Spanish, German, Italian, Portuguese, Dutch, Polish, Turkish, Arabic, Russian, Ukrainian, Hindi, Simplified Chinese, Traditional Chinese, Japanese and Korean. Choose one or two distinct languages (for example ara+fra in MCP). The browser downloads only models used during conversion; the optional full offline pack and local MCP v0.2.1 include all 17. See language codes, tests and limitations. This is OCR language selection, not translation, automatic language detection or UI localization.
Local MCP for AI agents
Browse the Glama server listing for available tools and its published quality indicators. You can also use MCP Inspector to explore MCP tool schemas. ParseFloe itself runs locally with an explicitly allowed document directory.
Official registry ID: io.github.LeadsFarmer/parsefloe. The registry lists the tested local MCPB release, not a hosted endpoint.
ParseFloe MCP is a local read-only stdio process for Claude Desktop, Codex and other compatible MCP hosts. It provides document conversion, inspection, heuristic quality, engine comparison, batch conversion and RAG chunks. All parsing runs on the user's own machine; the host may transmit extracted text to its configured AI provider. See the installation and safety guide. No shared conversion server or API key.
Install or launch the verified public npm release (Node.js >=22.12):
npx -y parsefloe-mcp@0.2.1 --allow-dir /absolute/path/to/documents
For Codex CLI:
codex mcp add parsefloe -- npx -y parsefloe-mcp@0.2.1 --allow-dir /absolute/path/to/documents
Choose a dedicated local folder. The first npm installation needs internet access; the installed parsers and bundled OCR models run locally. See the release and integrity details.
Deploy to Cloudflare
Deploy either engine into your own Cloudflare account. The two Workers are independent.
| Engine | Deploy |
|---|---|
| AnyDoc — document detection and Markdown conversion | |
| LiteParse — PDF native-text extraction (OCR disabled) |
Cloudflare imports the selected public GitHub project, configures Workers Builds and deploys to your account. Set a unique runtime secret API_TOKEN during setup (generate it with openssl rand -hex 32). If the setup form does not configure the runtime secret, add it afterwards in the Worker dashboard. The example value is deliberately rejected by both engines.
The Worker uses a public workers.dev URL by default; document processing requires the bearer token. See the deployment guide for authentication checks, manual deployment and plan limitations.
Why ParseFloe?
Document ingestion is a common bottleneck in RAG, knowledge bases and agent workflows. ParseFloe combines a deterministic parser router, a private browser workflow, a sequential batch queue and self-hosted HTTP integrations around existing WebAssembly engines. It exposes explicit limitations and requires no shared parsing server.
What is included
| Engine | Purpose | Status |
|---|---|---|
| AnyDoc WASM | Detect document formats and convert documents into Markdown | Experimental |
| LiteParse WASM | Extract native PDF text and inspect pages for potential OCR needs | Experimental; OCR optional in browser, disabled on Workers |
| Tesseract.js | Recognize text in scanned PDF page images | Experimental; browser and local MCP, 17 languages |
| Docling.rs WASM | Markdown and native Docling JSON from Office documents and text-layer PDFs | Experimental; browser only, lightweight conversion, no Docling ML models |
This repository contains the Worker and browser integration layers, not a new parser implementation. The actual parsing is provided by Firecrawl AnyDoc and LlamaIndex LiteParse, with Tesseract.js for local OCR. The lightweight browser-only Docling.rs converter is also included. Their packages and models retain their own licenses.
Architecture
flowchart LR
A[Document or batch] --> B[Browser Web Worker / Smart Router]
A --> C[Self-hosted Cloudflare Worker]
B --> D[AnyDoc / LiteParse / Docling.rs WASM]
B --> E[Tesseract.js local OCR]
C --> F[AnyDoc / LiteParse WASM]
D --> G[Markdown / text / JSON]
E --> G
F --> H[Authenticated API response]
The browser runs parsing in an isolated Web Worker with cancellation and a separate local OCR worker. The main Cloudflare Worker uses an injectable parser interface, bearer-token authentication, a streamed 5 MiB input limit, and JSON responses with caching disabled. The LiteParse experiment is a separate Worker with native-text extraction and per-page complexity inspection.
Quick start: AnyDoc
Requirements: Node.js 22, npm.
git clone https://github.com/LeadsFarmer/parsefloe.git
cd parsefloe
npm install
npm test
npm run build
npx wrangler dev --local --port 8787 --inspector-port 9229 --var API_TOKEN:local-test-only
Use a document you have permission to process. The example token is for local development only.
curl -fsS http://localhost:8787/health
curl -fsS http://localhost:8787/detect \
-H 'Authorization: Bearer local-test-only' \
-H 'Content-Type: application/octet-stream' \
--data-binary @sample.pdf
curl -fsS http://localhost:8787/parse?format=pdf \
-H 'Authorization: Bearer local-test-only' \
-H 'Content-Type: application/pdf' \
--data-binary @sample.pdf
API
| Method | Path | Purpose |
|---|---|---|
| GET | /health | Check parser initialization |
| POST | /detect | Detect input format |
| POST | /parse | Convert raw document bytes to Markdown |
The optional format hint accepts pdf, doc, docx, ppt, pptx, xls, xlsx, odt, ods, odp, rtf, epub and csv. This is the handler's accepted hint list, not a guarantee of extraction quality or compatibility for every file.
If the parser reports a page requiring OCR, the Worker returns HTTP 422 with an explicit ocr_required response rather than pretending extraction succeeded.
LiteParse experiment
cd liteparse-lab
npm install
npm run build
npx wrangler dev --local --port 8789 --inspector-port 9230 --var API_TOKEN:local-test-only
curl -fsS http://localhost:8789/parse \
-H 'Authorization: Bearer local-test-only' \
-H 'Content-Type: application/pdf' \
--data-binary @sample.pdf
The experimental response includes native text, page information, complexity and OCR recommendations. OCR is disabled, extraction is marked incomplete, and a 50-page limit is configured. Do not treat the output as verified full-document extraction.
ParseFloe Benchmarks
Browse the measured browser results → · Raw JSON · Download synthetic corpus
The browser benchmark evaluates the actual converter across AnyDoc, Docling.rs, LiteParse native, LiteParse + Tesseract, and Smart Router (five modes, four integrated engines). Seven original synthetic fixtures cover native multipage PDF, PDF tables, DOCX/CSV tables, English and French image-only PDFs and mixed native/scanned PDF. It measures normalized WER/CER, reference scores, row-content and Markdown pipe-row proxies, failures, and end-to-end latency over three measured trials per applicable case. Rankings are separate by document family; the synthetic corpus is not a universal accuracy or performance claim. The Pages workflow generates the report from measured results. See benchmark methodology.
Full DP-Bench corpus (200 pages, 600 attempts)
Full evaluation and raw measurements → · Raw JSON · Reproduction run.
| Mode | Mean reference score | Completed | Median latency (descriptive) |
|---|---|---|---|
| Smart Router v2 | 90.19% | 200/200 | 949 ms |
| AnyDoc alone | 87.36% | 197/200 | 232 ms |
| Smart Router v1 | 85.66% | 200/200 | 819.5 ms |
On the 197 pages completed by both AnyDoc and v2, mean normalized WER fell from 11.31% to 9.46% (16.32% relative reduction). On the 157 jointly successful pages among the 160 previously unevaluated pages, it fell by 14.29%. Across all 200 pages, v2 improved 59, tied 116 and degraded 25 reference scores versus AnyDoc, including failures scored zero. Versus frozen v1, mean WER fell 31.62%; 22 improved, 176 tied, 2 degraded.
No router tuning during this evaluation. One measured trial per mode and page, 10 interleaved shards; pooled latency is descriptive across runners, not a controlled cross-runner speed claim. This is normalized reference-text scoring, not the official DP-Bench NID/TEDS leaderboard, and does not establish universal superiority. AnyDoc alone remains faster.
Smart Router v2 validation — initial 40 pages
Paired validation report — 120 conversions on two disjoint 20-page DP-Bench samples. On the fixed holdout: v2 90.55%, frozen v1 82.07%, AnyDoc 86.77% on our normalized reference-text metric. Four pages improved and none regressed vs v1; median latency 1,371 ms vs 1,181 ms. This is a bounded diagnostic, not official DP-Bench scoring. Policy and full measurements.
External reference benchmark
Measured DP-Bench pilot → · Raw JSON. The first run completed 100/100 conversions across 20 fixed pages. AnyDoc scored 93.18%, Smart Router 92.42% on our normalized reference-text metric; automatic routing improved 8 pages, tied 11 and degraded 1. This is a subset diagnostic, not official DP-Bench NID/TEDS.
The external corpus guide documents a pinned 20-page DP-Bench pilot and a local-only OmniDocBench research adapter. The external pilot uses separate normalized text metrics, not official leaderboard scores. The restricted OmniDocBench data is never downloaded or run in CI.
Try it with a reproducible sample
Generate a synthetic PDF with no external downloads or customer data:
npm run sample:pdf
Start both local Workers as described above, then run npm run benchmark from the repository root. The script validates expected text, performs a warm-up and measures five sequential HTTP requests per engine. See benchmark methodology and CI runs for actual results. This is a smoke benchmark, not a general performance claim.
Verification
Browser and Pages workflow exercises actual PDF conversion with both engines, CSV conversion, English OCR on an image-only PDF, conversion of a PDF larger than 6 MiB, JSON export, rejection above 50 MiB, automatic selection for native and scanned PDFs, a mixed four-file batch (three successes and one empty-file rejection), duplicate-name-safe ZIP export with a manifest, and network request restrictions before deployment. The December 5, 2026 browser run and Worker run passed; Pages deployment also succeeded. French OCR models are available but French recognition accuracy, conversion at the full 50 MiB cap, and Safari/iPhone compatibility still need dedicated validation. See Worker CI for API tests and benchmarks.
The Docling and PWA workflow passed on December 5, 2026: four router unit tests, real Docling native PDF and CSV conversions, and a Chromium offline reload followed by native PDF conversion, Docling CSV conversion and English OCR while the network was disabled. The release's static offline pack contained 42 assets totaling 89.7 MiB uncompressed. The cache check verified static assets only. Real-device installation on Safari/iPhone, French OCR accuracy and maximum-size inputs still need dedicated validation. The Worker CI also passed; the Cloudflare Workers are unchanged.
The quality and comparison workflow passed its build and browser test job on December 5, 2026: 11 router/quality unit tests, real native-PDF comparisons with AnyDoc, Docling.rs and LiteParse, alternative JSON download, batch manifest and network checks, and offline CSV comparison. The Worker tests also passed. These checks verify functionality, not the accuracy of the heuristic. The release's offline pack is 89.8 MiB uncompressed.
Roadmap
- Initial synthetic native-text PDF fixture and reproducible smoke benchmark.
- Public browser converter with locally hosted WASM engines and 50 MiB input cap.
- Cloudflare deployment buttons and self-hosting guide.
- English OCR smoke test on an image-only PDF.
- Dedicated French OCR, full-limit file and Safari/iPhone tests.
- Smart Router and sequential batch processing with ZIP export.
- Offline PWA with opt-in static asset pack and Chromium offline conversion tests.
- Local read-only MCP implementation and release packaging.
- Verify desktop-host installation and broader platform compatibility.
- Lightweight Docling.rs WASM converter as a manual engine and fallback, with PDF/CSV browser tests.
- Evaluate Docling ML layout/table models separately; no advanced Docling OCR is shipped.
- Reference-free extraction indicators, conservative quality guard and selectable multi-engine comparisons.
- Reproducible synthetic ground-truth corpus and browser benchmark reports.
- Evaluate and calibrate quality indicators against a broader licensed ground-truth corpus.
- Broader benchmarks with scanned, mixed-content and multi-page documents.
- Better detection of scanned and mixed-content documents.
- Experimental browser and MCP OCR with 17 locally hosted Tesseract.js language models.
- Explore lightweight OCR strategies within edge runtime limits.
- Add integration tests for real documents and compare extraction quality and resource usage.
- Harden deployment guidance, privacy and resource controls.
Security and deployment
This is a research prototype, not a production-ready public document service. Worker CI runs unit tests, dry-run builds and a local smoke benchmark; it does not deploy Workers. The separate Pages workflow tests and publishes the static browser application. The Worker configurations enable workers.dev for user-owned deployments and disable preview URLs. Parsing fails closed until a non-placeholder API_TOKEN is set. The public health endpoint does not expose document data. Consider Cloudflare Access or rate limits for additional protection. Do not upload confidential documents to shared environments.
Contributing
Issues and pull requests are welcome, especially reproducible parser failures, test fixtures with clear redistribution rights and benchmark results. Please remove private documents and credentials from reports.
License
MIT for the integration code in this repository. Upstream parsing engines and dependencies are governed by their respective licenses.