๐Ÿ”ฌ Generate AI document titles for Paperless-ngx with GPT-4o Mini

โšก 573 views ยท ๐Ÿ”ฌ Document Extraction & Analysis

Description

What it does

This template automatically generates a professional, structured title for newly-ingested Paperless-ngx documents using AI (OpenAI GPT), then removes a processing tag to mark the document as handled.

How it works

  1. A webhook fires when a document needs titling (e.g., from a Paperless post-consumption script)
  2. The document URL is validated, then the OCR text is fetched from the Paperless API
  3. All PII is scrubbed from the text using n8nโ€™s Guardrails node before sending to AI
  4. GPT generates a title using the format: [YYYY-MM-DD] - [Document Type] - [Subject]
  5. The specified processing tag is looked up and removed, then the document is updated

Requirements

How to use

Needs to be set up in conjunction with a running Paperless-ngx instance. See Paperless-ngx instructions here

Customization

๐Ÿ”— Nodes Used

HTTP Request, Webhook, Stop and Error, AI Agent, OpenAI Chat Model, Guardrails

๐Ÿ“ฅ Import

Download workflow.json and import into n8n: Workflow menu โ†’ Import from File

๐Ÿ“– Importing guide ยท ๐Ÿ”‘ Credential setup