PrivAI-Stack (Private AI Stack) is an all-in-one AI scaffolding solution designed specifically for private deployment. It integrates four of the most powerful open-source components available today, aiming to help developers and enterprises quickly set up a local AI workflow with enterprise-grade document parsing capabilities and ultra-fast inference speed.
๐จ๐ณ ไธญๆ็ README
The project consists of four independent modules, each isolated via Docker:
docling/(Open-sourced by IBM): Converts complex PDFs and documents accurately into Markdown/JSONโideal for RAG preprocessing.vllm/: Ultra-fast inference backend supporting PagedAttention, suitable for deploying mainstream large models such as DeepSeek and Qwen.xinference/: A large model management platform that wraps vLLM at a higher level, providing unified management for LLMs, Embedding, and Rerank models.dify/: An open-source LLMOps platform responsible for orchestrating workflows, managing knowledge bases, and publishing AI applications.
PrivAI-Stack/
โโโ docling/ # Docling API service (parsing layer)
โโโ vllm/ # vLLM inference engine (compute layer)
โโโ xinference/ # Rerank and embedding model inference engine (compute layer)
โโโ dify/ # AI application orchestration platform (application layer)
ๆฏไธชๆไปถๅคนไธญๅๅ ๅซ๏ผ
.env: Environment variable configuration (model paths, ports, API keys, etc.).docker-compose.yml: Container orchestration definition.
git clone https://github.com/your-username/PrivAI-Stack.git
cd PrivAI-StackThe project uses a decoupled designโstart only what you need.
It's recommended to start inference services first, as they are prerequisites for upper-layer applications.
cd xinference
# Modify model storage path in .env if needed
docker compose up -d
# View logs
docker compose logs -fcd ../docling
docker compose up -d
docker compose logs -fcd ../dify
docker compose up -d
docker compose logs -fEach module follows the same operational pattern:
| Action | Command |
|---|---|
| Start service | docker compose up -d |
| Stop service | docker compose down |
| View live logs | docker compose logs -f |
| Restart service | docker compose restart |
- Connect Dify to Xinference:
In Dify Admin โ Settings โ Model Providers โ Choose Xinference, and enter
http://xinference:9997. - Connect Dify to vLLM:
In Dify Admin โ Settings โ Model Providers โ Choose vLLM, and enter
http://vllm:8000/v1. - Use Docling in Dify:
In Dify Workflow, add an HTTP node and call Doclingโs API at
http://docling:5001/v1/convert/file
- Hardware Requirement: At least 24GB GPU VRAM (e.g., RTX 3090/4090) is recommended for smooth performance.
- Driver Setup: Ensure the host has the
NVIDIA Container Toolkitinstalled. - Network Configuration: By default, modules communicate via the host IP. Make sure ports defined in
.envare not occupied.
If you encounter bugs or have suggestions for improvement, feel free to open an Issue!
- Author: Your Name
- Star: If this project helps you, please give it a โญ!
- Fully Decoupled: Use only
doclingas a parsing tool, or justvllmas an inference APIโno forced integration. - Simple & Clean: No complex install scriptsโonly basic
.envanddocker-compose.yml. - Production-Ready: All components are industry-leading tools for private AI deployments.