npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@uploadista/flow-documents-nodes

v0.1.1

Published

Document processing nodes for Uploadista Flow

Readme

@uploadista/flow-documents-nodes

Document processing nodes for Uploadista flows. Process PDFs with text extraction, OCR, splitting, merging, and conversion.

Installation

npm install @uploadista/flow-documents-nodes
# or
pnpm add @uploadista/flow-documents-nodes

Quick Start

import {
  createOcrNode,
  createExtractTextNode,
  createSplitPdfNode,
  createMergePdfNode,
  createDescribeDocumentNode,
  createConvertToMarkdownNode,
} from "@uploadista/flow-documents-nodes";

Node Types

OCR Node

AI-powered text extraction from scanned documents.

import { createOcrNode } from "@uploadista/flow-documents-nodes";

// Convert scanned document to markdown
const ocrNode = yield* createOcrNode("ocr-1", {
  taskType: "convertToMarkdown",
  resolution: "gundam",
  credentialId: "my-replicate-credential",
});

// Free-form OCR for plain text extraction
const freeOcrNode = yield* createOcrNode("ocr-2", {
  taskType: "freeOcr",
  resolution: "base",
});

// Locate specific content in document
const locateNode = yield* createOcrNode("ocr-3", {
  taskType: "locateObject",
  referenceText: "Invoice Total",
  resolution: "small",
});

Parameters

| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | taskType | "convertToMarkdown" \| "freeOcr" \| "parseFigure" \| "locateObject" | Yes | - | OCR task type | | resolution | "tiny" \| "small" \| "base" \| "gundam" \| "large" | No | - | Model resolution | | credentialId | string | No | - | AI service credential ID | | referenceText | string | No | - | Text to locate (for locateObject task) | | keepOutput | boolean | No | false | Keep output in flow results |

Task Types

| Task Type | Description | |-----------|-------------| | convertToMarkdown | Structured markdown output with headings, lists | | freeOcr | Unstructured plain text extraction | | parseFigure | Analyze charts and diagrams | | locateObject | Find specific content using reference text |

Extract Text Node

Fast text extraction from searchable PDFs.

import { createExtractTextNode } from "@uploadista/flow-documents-nodes";

// Extract text from searchable PDF
const extractNode = yield* createExtractTextNode("extract-1");

// With keepOutput option
const keepOutputNode = yield* createExtractTextNode("extract-2", {
  keepOutput: true,
});

Parameters

| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | keepOutput | boolean | No | false | Keep output in flow results |

Output: Adds extractedText to file metadata.

Split PDF Node

Split PDFs by page range or into individual pages.

import { createSplitPdfNode } from "@uploadista/flow-documents-nodes";

// Extract pages 3-5 as single PDF
const rangeNode = yield* createSplitPdfNode("split-1", {
  mode: "range",
  startPage: 3,
  endPage: 5,
});

// Split each page into separate PDF
const individualNode = yield* createSplitPdfNode("split-2", {
  mode: "individual",
});

Parameters

| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | mode | "range" \| "individual" | Yes | - | Split mode | | startPage | number | No | - | Start page (for range mode) | | endPage | number | No | - | End page (for range mode) | | keepOutput | boolean | No | false | Keep output in flow results | | naming | FileNamingConfig | No | - | File naming configuration |

Merge PDF Node

Combine multiple PDFs into a single document.

import { createMergePdfNode } from "@uploadista/flow-documents-nodes";

// Merge PDFs with default settings
const mergeNode = yield* createMergePdfNode("merge-1");

// With custom naming
const namedMergeNode = yield* createMergePdfNode("merge-2", {
  naming: { mode: "auto" },
});

Parameters

| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | inputCount | number | No | - | Expected number of input files | | keepOutput | boolean | No | false | Keep output in flow results | | naming | FileNamingConfig | No | - | File naming (auto suffix: merged) |

Note: Requires a Merge utility node upstream to provide multiple files.

Describe Document Node

Extract PDF metadata (page count, author, title, etc.).

import { createDescribeDocumentNode } from "@uploadista/flow-documents-nodes";

// Extract document metadata
const describeNode = yield* createDescribeDocumentNode("describe-1");

Parameters

| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | keepOutput | boolean | No | false | Keep output in flow results |

Output Metadata:

{
  "pageCount": 10,
  "format": "pdf",
  "author": "John Doe",
  "title": "Document Title",
  "subject": "Document Subject",
  "creator": "Adobe Acrobat",
  "creationDate": "2023-01-01T00:00:00Z",
  "modifiedDate": "2023-01-02T00:00:00Z",
  "fileSize": 1024000
}

Convert to Markdown Node

Intelligent document-to-markdown conversion.

import { createConvertToMarkdownNode } from "@uploadista/flow-documents-nodes";

// Convert with default settings
const convertNode = yield* createConvertToMarkdownNode("convert-1");

// With custom resolution and credential
const customNode = yield* createConvertToMarkdownNode("convert-2", {
  resolution: "gundam",
  credentialId: "my-ai-credential",
});

Parameters

| Parameter | Type | Required | Default | Description | |-----------|------|----------|---------|-------------| | resolution | "tiny" \| "small" \| "base" \| "gundam" \| "large" | No | "gundam" | OCR model resolution | | credentialId | string | No | - | AI service credential ID | | keepOutput | boolean | No | false | Keep output in flow results |

How it Works:

  1. Tries text extraction first (fast, for searchable PDFs)
  2. Falls back to OCR if no text found (for scanned PDFs)
  3. Returns structured markdown in metadata.markdown

Requirements

  • DocumentPlugin: Required for PDF operations (split, merge, extract text, metadata)
  • DocumentAiPlugin: Required for OCR and AI-powered conversion

License

MIT