paperless-ai

clusterzxMIT活跃维护

给 Paperless-ngx 文档库接上大模型,自动分析文档内容并打标签,支持 OpenAI、Ollama、DeepSeek-r1、Azure 等兼容接口。

An automated document analyzer for Paperless-ngx using OpenAI API, Ollama, Deepseek-r1, Azure and all OpenAI API compatible Services to automatically analyze and tag your documents.

v3.0.9发布于 2025-11-04 07:28 UTC5,991star331fork同步于 2026-11-10 23:35 UTC

怎么上手

由 README 提炼,执行前请确认
npm install
npm run test
硬件要求按 README 说明

README 未说明显存或 GPU 要求;模型可跑在 Ollama 或各类 OpenAI 兼容的远程 API 上,本地硬件取决于所选后端。

下载:源码 zip·GitHub Releases(安装包)本站不镜像安装包

项目说明

由 README 自动翻译提炼

给 Paperless-ngx 加 AI 自动分类打标和 RAG 问答的扩展

给 Paperless-ngx 文档库接上大模型,自动分析文档内容并打标签,支持 OpenAI、Ollama、DeepSeek-r1、Azure 等兼容接口。

核心能力

  • 自动检测 Paperless-ngx 新文档并分析内容
  • 自动生成标题、标签、文档类型和对应人
  • 基于 RAG 对全库文档做语义搜索与自然语言问答
  • 支持 OpenAI、Ollama、DeepSeek、Gemini 等多种后端
  • 提供 /manual 网页界面手动审核敏感文档打标

容易踩的坑

首次安装完成 API key 和偏好设置后需重启容器以构建 RAG 索引;仓库目前不再维护,作者正重写且可能随 Paperless-ngx 官方 AI 集成而停止;需先有可用的 Paperless-ngx 实例和所选 AI 后端。

内容由模型根据 README 生成,可能不完整或不准确,以官方文档为准。看原文 README

最近发版

5 个版本v3.0.9
  1. v3.0.9v3.0.9 | fix tag caching Issue from latest security fix breaking PP-AI最新正式版2025-11-04 · 2025-11-04 07:28 UTC
  2. v3.0.8Release v3.0.8 | Security Fix | Updates | Merges2025-11-03 · 2025-11-03 14:04 UTC
    查看更新说明

    What's Changed

    New Contributors

    Full Changelog: https://github.com/clusterzx/paperless-ai/compare/v3.0.7...v3.0.8

  3. v3.0.72025-06-22 · 2025-06-22 17:49 UTC
    查看更新说明

    News:

    This release refactors the prompt handling to support user-customized placeholders in the system message. It introduces a dedicated RestrictionPromptService for placeholder replacement, removes legacy prompt-building logic from multiple services, and updates the associated test scripts.

    Now you can define with %RESTRICTED_CORRESPONDENTS% and %RESTRICTED_TAGS% placeholders where in the prompt the existing Data is injected.

    What's Changed

    New Contributors

    Full Changelog: https://github.com/clusterzx/paperless-ai/compare/v3.0.6...v3.0.7

  4. v3.0.6v3.0.6 | Critical fix for Custom Providers2025-06-18 · 2025-06-18 14:18 UTC
    查看更新说明

    What's Changed

    Full Changelog: https://github.com/clusterzx/paperless-ai/compare/v3.0.5...v3.0.6

  5. v3.0.5v3.0.5 | Introduce fine-grained restrictions for tags and correspondents2025-06-16 · 2025-06-16 13:25 UTC
    查看更新说明

    What's Changed

    Introduce fine-grained restrictions for tag and correspondent creation, along with the ability to fetch external data via an API. Update settings management and ensure proper handling of new features.

    Full Changelog: https://github.com/clusterzx/paperless-ai/compare/v3.0.4...v3.0.5

用户点评

登录用户的真实使用记录,可按版本和硬件筛选
共 0 条

    还没有人点评。第一个说出真实体验的人最有价值。

    README 原文

    未翻译

    📄 Paperless-AI

    GitHub commit activity Docker Pulls GitHub Stars License

    ⚠️ IMPORTANT NOTICE:

    This repo is currently not maintained. I appreciate all the efforts from the community pushing PRs and creating issues. I'm currently rewriting the entire codebase with a more stable, up-to-date architecture. But I'm limited to evenings, and doing support here while also working on the rewrite just isn't feasible for me. With the upcoming official AI integration in Paperless-ngx itself, I'm also not sure if I'll complete the rewrite or continue maintaining this repo at all.


    Paperless-AI is an AI-powered extension for Paperless-ngx that brings automatic document classification, smart tagging, and semantic search using OpenAI-compatible APIs and Ollama.

    It enables fully automated document workflows, contextual chat, and powerful customization — all via an intuitive web interface.

    💡 Just ask:
    “When did I sign my rental agreement?”
    “What was the amount of the last electricity bill?”
    “Which documents mention my health insurance?”

    Powered by Retrieval-Augmented Generation (RAG), you can now search semantically across your full archive and get precise, natural language answers.


    ✨ Features

    🔄 Automated Document Processing

    • Detects new documents in Paperless-ngx automatically
    • Analyzes content using OpenAI API, Ollama, and other compatible backends
    • Assigns title, tags, document type, and correspondent
    • Built-in support for:
      • Ollama (Mistral, Llama, Phi-3, Gemma-2)
      • OpenAI
      • DeepSeek.ai
      • OpenRouter.ai
      • Perplexity.ai
      • Together.ai
      • LiteLLM
      • VLLM
      • Fastchat
      • Gemini (Google)
      • ...and more!

    🧠 RAG-Based AI Chat

    • Natural language document search and Q&A
    • Understands full document context (not just keywords)
    • Semantic memory powered by your own data
    • Fast, intelligent, privacy-friendly document queries
      RAG_CHAT_DEMO

    ⚙️ Manual Processing

    • Web interface for manual AI tagging
    • Useful when reviewing sensitive documents
    • Accessible via /manual

    🧩 Smart Tagging & Rules

    • Define rules to limit which documents are processed
    • Disable prompts and apply tags automatically
    • Set custom output tags for tracked classification
      PPAI_SHOWCASE3

    🚀 Installation

    ⚠️ First-time install: Restart the container after completing setup (API keys, preferences) to build RAG index.
    🔁 Not required for updates.

    📘 Installation Wiki


    🐳 Docker Support

    • Health monitoring and auto-restart
    • Persistent volumes and graceful shutdown
    • Works out of the box with minimal setup

    🔧 Local Development

    # Install dependencies
    npm install
    
    # Start development/test mode
    npm run test
    

    🧭 Roadmap Highlights

    • ✅ Multi-AI model support
    • ✅ Multilingual document analysis
    • ✅ Tag rules and filters
    • ✅ Integrated document chat with RAG
    • ✅ Responsive web interface

    🤝 Contributing

    We welcome PRs and contributions!

    # Fork, clone, then:
    git checkout -b feature/YourFeature
    # After changes:
    git commit -m "Add YourFeature"
    git push origin feature/YourFeature
    

    Then open a Pull Request via GitHub.


    🆘 Support & Community


    📄 License

    This project is licensed under the MIT License. See LICENSE for details.


    🙏 Support Development

    Patreon PayPal BuyMeACoffee Ko-Fi