[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-73773":3},{"id":4,"name":5,"fullName":6,"owner":5,"repo":5,"description":7,"homepage":8,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":14,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":15,"forks30d":15,"starsTrendScore":19,"compositeScore":20,"rankGlobal":9,"rankLanguage":9,"license":21,"archived":22,"fork":22,"defaultBranch":23,"hasWiki":24,"hasPages":22,"topics":25,"createdAt":9,"pushedAt":9,"updatedAt":31,"readmeContent":32,"aiSummary":33,"trendingCount":15,"starSnapshotCount":15,"syncStatus":34,"lastSyncTime":35,"discoverSource":36},73773,"rag-web-ui","rag-web-ui\u002Frag-web-ui","RAG Web UI is an intelligent dialogue system based on RAG (Retrieval-Augmented Generation) technology.","",null,"TypeScript",3034,341,41,15,0,6,11,37,18,80.8,"Apache License 2.0",false,"main",true,[26,27,28,29,30],"ai","deepseek","langchain","ollama","rag","2026-06-12 04:01:11","\u003Cdiv align=\"center\">\n  \u003Cimg src=\".\u002Fdocs\u002Fimages\u002Fgithub-cover-new.png\" alt=\"RAG Web UI Demo\">\n  \u003Cbr \u002F>\n  \u003Cp>\n    \u003Cstrong>Knowledge Base Management Based on RAG (Retrieval-Augmented Generation)\u003C\u002Fstrong>\n  \u003C\u002Fp>\n\n  \u003Cp>\n    \u003Ca href=\"https:\u002F\u002Fgithub.com\u002Frag-web-ui\u002Frag-web-ui\u002Fblob\u002Fmain\u002FLICENSE\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fgithub\u002Flicense\u002Frag-web-ui\u002Frag-web-ui\" alt=\"License\">\u003C\u002Fa>\n    \u003Ca href=\"#\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fpython-3.9+-blue.svg\" alt=\"Python\">\u003C\u002Fa>\n    \u003Ca href=\"#\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fnode-%3E%3D18-green.svg\" alt=\"Node\">\u003C\u002Fa>\n    \u003Ca href=\"#\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FPRs-welcome-brightgreen.svg\" alt=\"PRs Welcome\">\u003C\u002Fa>\n    \u003Ca href=\"#\">\u003Cimg src=\"https:\u002F\u002Fgithub.com\u002Frag-web-ui\u002Frag-web-ui\u002Factions\u002Fworkflows\u002Ftest.yml\u002Fbadge.svg\" alt=\"CI\">\u003C\u002Fa>\n  \u003C\u002Fp>\n\n  \u003Cp>\n    \u003Ca href=\"#features\">Features\u003C\u002Fa> •\n    \u003Ca href=\"#quick-start\">Quick Start\u003C\u002Fa> •\n    \u003Ca href=\"#deployment-guide\">Deployment\u003C\u002Fa> •\n    \u003Ca href=\"#architecture\">Architecture\u003C\u002Fa> •\n    \u003Ca href=\"#development\">Development\u003C\u002Fa> •\n    \u003Ca href=\"#contributing\">Contributing\u003C\u002Fa> •\n    \u003Ca href=\"https:\u002F\u002Fdeepwiki.com\u002Frag-web-ui\u002Frag-web-ui\" target=\"_blank\">DeepWiki\u003C\u002Fa>\n  \u003C\u002Fp>\n\u003C\u002Fdiv>\n\n## 📖 Introduction\nRAG Web UI is an intelligent dialogue system based on RAG (Retrieval-Augmented Generation) technology that helps build intelligent Q&A systems based on your own knowledge base. By combining document retrieval and large language models, it achieves accurate and reliable knowledge-based question answering services.\n\nThe system supports multiple **LLM** deployment options, including cloud services like **OpenAI**, **DeepSeek**, and **[MiniMax](https:\u002F\u002Fwww.minimax.io)**, as well as local model deployment through **Ollama**, meeting privacy and cost requirements in different scenarios.\n\nIt also provides OpenAPI interfaces for convenient knowledge base access via API calls.\n\n## ✨ Features\n- 📚 **Intelligent Document Management**\n  - Support for multiple document formats (PDF, DOCX, Markdown, Text)\n  - Automatic document chunking and vectorization\n  - Support for async document processing and incremental updates\n\n- 🤖 **Advanced Dialogue Engine**\n  - Precise retrieval and generation based on RAG\n  - Support for multi-turn contextual dialogue\n  - Support for reference citations in conversations\n\n- 🎯 **Robust Architecture**\n  - Frontend-backend separation design\n  - Distributed file storage\n  - High-performance vector database: Support for ChromaDB, Qdrant with easy switching through Factory pattern\n\n## 🖼️ Screenshots\n\n\u003Cdiv align=\"center\">\n  \u003Cimg src=\".\u002Fdocs\u002Fimages\u002Fscreenshot1.png\" alt=\"Knowledge Base Management\" width=\"800\">\n  \u003Cp>\u003Cem>Knowledge Base Management Dashboard\u003C\u002Fem>\u003C\u002Fp>\n  \n  \u003Cimg src=\".\u002Fdocs\u002Fimages\u002Fscreenshot2.png\" alt=\"Chat Interface\" width=\"800\">\n  \u003Cp>\u003Cem>Document Processing Dashboard\u003C\u002Fem>\u003C\u002Fp>\n  \n  \u003Cimg src=\".\u002Fdocs\u002Fimages\u002Fscreenshot3.png\" alt=\"Document Processing\" width=\"800\">\n  \u003Cp>\u003Cem>Document List\u003C\u002Fem>\u003C\u002Fp>\n  \n  \u003Cimg src=\".\u002Fdocs\u002Fimages\u002Fscreenshot4.png\" alt=\"System Settings\" width=\"800\">\n  \u003Cp>\u003Cem>Intelligent Chat Interface with References\u003C\u002Fem>\u003C\u002Fp>\n  \n  \u003Cimg src=\".\u002Fdocs\u002Fimages\u002Fscreenshot5.png\" alt=\"Analytics Dashboard\" width=\"800\">\n  \u003Cp>\u003Cem>API Key Management\u003C\u002Fem>\u003C\u002Fp>\n\n  \u003Cimg src=\".\u002Fdocs\u002Fimages\u002Fscreenshot6.png\" alt=\"Analytics Dashboard\" width=\"800\">\n  \u003Cp>\u003Cem>API Reference\u003C\u002Fem>\u003C\u002Fp>\n\u003C\u002Fdiv>\n\n ##  Project Flowchart\n \n```mermaid\ngraph TB\n    %% Role Definitions\n    client[\"Caller\u002FUser\"]\n    open_api[\"Open API\"]\n    \n    subgraph import_process[\"Document Ingestion Process\"]\n        direction TB\n        %% File Storage and Document Processing Flow\n        docs[\"Document Input\u003Cbr\u002F>(PDF\u002FMD\u002FTXT\u002FDOCX)\"]\n        job_id[\"Return Job ID\"]\n        \n        nfs[\"NFS\"]\n\n        subgraph async_process[\"Asynchronous Document Processing\"]\n            direction TB\n            preprocess[\"Document Preprocessing\u003Cbr\u002F>(Text Extraction\u002FCleaning)\"]\n            split[\"Text Splitting\u003Cbr\u002F>(Segmentation\u002FOverlap)\"]\n            \n            subgraph embedding_process[\"Embedding Service\"]\n                direction LR\n                embedding_api[\"Embedding API\"] --> embedding_server[\"Embedding Server\"]\n            end\n            \n            store[(Vector Database)]\n            \n            %% Internal Flow of Asynchronous Processing\n            preprocess --> split\n            split --> embedding_api\n            embedding_server --> store\n        end\n        \n        subgraph job_query[\"Job Status Query\"]\n            direction TB\n            job_status[\"Job Status\u003Cbr\u002F>(Processing\u002FCompleted\u002FFailed)\"]\n        end\n    end\n    \n    %% Query Service Flow  \n    subgraph query_process[\"Query Service\"]\n        direction LR\n        user_history[\"User History\"] --> query[\"User Query\u003Cbr\u002F>(Based on User History)\"]\n        query --> query_embed[\"Query Embedding\"]\n        query_embed --> retrieve[\"Vector Retrieval\"]\n        retrieve --> rerank[\"Re-ranking\u003Cbr\u002F>(Cross-Encoder)\"]\n        rerank --> context[\"Context Assembly\"]\n        context --> llm[\"LLM Generation\"]\n        llm --> response[\"Final Response\"]\n        query -.-> rerank\n    end\n    \n    %% Main Flow Connections\n    client --> |\"1.Upload Document\"| docs\n    docs --> |\"2.Generate\"| job_id\n    docs --> |\"3a.Trigger\"| async_process\n    job_id --> |\"3b.Return\"| client\n    docs --> nfs\n    nfs --> preprocess\n\n    %% Open API Retrieval Flow\n    open_api --> |\"Retrieve Context\"| retrieval_service[\"Retrieval Service\"]\n    retrieval_service --> |\"Access\"| store\n    retrieval_service --> |\"Return Context\"| open_api\n\n    %% Status Query Flow\n    client --> |\"4.Poll\"| job_status\n    job_status --> |\"5.Return Progress\"| client\n    \n    %% Database connects to Query Service\n    store --> retrieve\n\n    %% Style Definitions (Adjusted to match GitHub theme colors)\n    classDef process fill:#d1ecf1,stroke:#0077b6,stroke-width:1px\n    classDef database fill:#e2eafc,stroke:#003566,stroke-width:1px\n    classDef input fill:#caf0f8,stroke:#0077b6,stroke-width:1px\n    classDef output fill:#ffc8dd,stroke:#d00000,stroke-width:1px\n    classDef rerank fill:#cdb4db,stroke:#5a189a,stroke-width:1px\n    classDef async fill:#f8edeb,stroke:#7f5539,stroke-width:1px,stroke-dasharray: 5 5\n    classDef actor fill:#fefae0,stroke:#606c38,stroke-width:1px\n    classDef jobQuery fill:#ffedd8,stroke:#ca6702,stroke-width:1px\n    classDef queryProcess fill:#d8f3dc,stroke:#40916c,stroke-width:1px\n    classDef embeddingService fill:#ffe5d9,stroke:#9d0208,stroke-width:1px\n    classDef importProcess fill:#e5e5e5,stroke:#495057,stroke-width:1px\n\n    %% Applying classes to nodes\n    class docs,query,retrieval_service input\n    class preprocess,split,query_embed,retrieve,context,llm process\n    class store,nfs database\n    class response,job_id,job_status output\n    class rerank rerank\n    class async_process async\n    class client,open_api actor\n    class job_query jobQuery\n    style query_process fill:#d8f3dc,stroke:#40916c,stroke-width:1px\n    style embedding_process fill:#ffe5d9,stroke:#9d0208,stroke-width:1px\n    style import_process fill:#e5e5e5,stroke:#495057,stroke-width:1px\n    style job_query fill:#ffedd8,stroke:#ca6702,stroke-width:1px\n```\n\n## 🚀 Quick Start\n\n### Prerequisites\n\n- Docker & Docker Compose v2.0+\n- Node.js 18+\n- Python 3.9+\n- 8GB+ RAM\n\n### Installation\n\n1. Clone the repository\n```bash\ngit clone https:\u002F\u002Fgithub.com\u002Frag-web-ui\u002Frag-web-ui.git\ncd rag-web-ui\n```\n\n2. Configure environment variables\n\nYou can check the details in the configuration table below.\n\n```bash\ncp .env.example .env\n```\n\n3. Start services(development server)\n```bash\ndocker compose up -d --build\n```\n\n### Verification\n\nAccess the following URLs after service startup:\n\n- 🌐 Frontend UI: http:\u002F\u002F127.0.0.1.nip.io\n- 📚 API Documentation: http:\u002F\u002F127.0.0.1.nip.io\u002Fredoc\n- 💾 MinIO Console: http:\u002F\u002F127.0.0.1.nip.io:9001\n\n## 🏗️ Architecture\n\n### Backend Stack\n\n- 🐍 **Python FastAPI**: High-performance async web framework\n- 🗄️ **MySQL + ChromaDB**: Relational + Vector databases\n- 📦 **MinIO**: Distributed object storage\n- 🔗 **Langchain**: LLM application framework\n- 🔒 **JWT + OAuth2**: Authentication\n\n### Frontend Stack\n\n- ⚛️ **Next.js 14**: React framework\n- 📘 **TypeScript**: Type safety\n- 🎨 **Tailwind CSS**: Utility-first CSS\n- 🎯 **Shadcn\u002FUI**: High-quality components\n- 🤖 **Vercel AI SDK**: AI integration\n\n## 📈 Performance Optimization\n\nThe system is optimized in the following aspects:\n\n- ⚡️ Incremental document processing and async chunking\n- 🔄 Streaming responses and real-time feedback\n- 📑 Vector database performance tuning\n- 🎯 Distributed task processing\n\n## 📖 Development Guide\n\n```bash\ndocker compose -f docker-compose.dev.yml up -d --build\n```\n\n## 🔧 Configuration\n\n### Core Configuration\n\n| Parameter                   | Description                | Default   | Required |\n| --------------------------- | -------------------------- | --------- | -------- |\n| MYSQL_SERVER                | MySQL Server Address       | localhost | ✅        |\n| MYSQL_USER                  | MySQL Username             | postgres  | ✅        |\n| MYSQL_PASSWORD              | MySQL Password             | postgres  | ✅        |\n| MYSQL_DATABASE              | MySQL Database Name        | ragwebui  | ✅        |\n| SECRET_KEY                  | JWT Secret Key             | -         | ✅        |\n| ACCESS_TOKEN_EXPIRE_MINUTES | JWT Token Expiry (minutes) | 30        | ✅        |\n\n### LLM Configuration\n\n| Parameter         | Description           | Default                   | Applicable            |\n| ----------------- | --------------------- | ------------------------- | --------------------- |\n| CHAT_PROVIDER     | LLM Service Provider  | openai                    | ✅                     |\n| OPENAI_API_KEY    | OpenAI API Key        | -                         | Required for OpenAI   |\n| OPENAI_API_BASE   | OpenAI API Base URL   | https:\u002F\u002Fapi.openai.com\u002Fv1 | Optional for OpenAI   |\n| OPENAI_MODEL      | OpenAI Model Name     | gpt-4                     | Required for OpenAI   |\n| DEEPSEEK_API_KEY  | DeepSeek API Key      | -                         | Required for DeepSeek |\n| DEEPSEEK_API_BASE | DeepSeek API Base URL | -                         | Required for DeepSeek |\n| DEEPSEEK_MODEL    | DeepSeek Model Name   | -                         | Required for DeepSeek |\n| OLLAMA_API_BASE   | Ollama API Base URL   | http:\u002F\u002Flocalhost:11434    | Required for Ollama   |\n| OLLAMA_MODEL      | Ollama Model Name     | llama2                    | Required for Ollama   |\n| MINIMAX_API_KEY   | MiniMax API Key       | -                         | Required for MiniMax  |\n| MINIMAX_API_BASE  | MiniMax API Base URL  | https:\u002F\u002Fapi.minimax.io\u002Fv1 | Optional for MiniMax  |\n| MINIMAX_MODEL     | MiniMax Model Name    | MiniMax-M2.7              | Required for MiniMax  |\n\n### Embedding Configuration\n\n| Parameter                   | Description                | Default                | Applicable                    |\n| --------------------------- | -------------------------- | ---------------------- | ----------------------------- |\n| EMBEDDINGS_PROVIDER         | Embedding Service Provider | openai                 | ✅                             |\n| OPENAI_API_KEY              | OpenAI API Key             | -                      | Required for OpenAI Embedding |\n| OPENAI_EMBEDDINGS_MODEL     | OpenAI Embedding Model     | text-embedding-ada-002 | Required for OpenAI Embedding |\n| DASH_SCOPE_API_KEY          | DashScope API Key          | -                      | Required for DashScope        |\n| DASH_SCOPE_EMBEDDINGS_MODEL | DashScope Embedding Model  | -                      | Required for DashScope        |\n| OLLAMA_EMBEDDINGS_MODEL     | Ollama Embedding Model     | deepseek-r1:7b         | Required for Ollama Embedding |\n\n### Vector Database Configuration\n\n| Parameter          | Description                       | Default               | Applicable            |\n| ------------------ | --------------------------------- | --------------------- | --------------------- |\n| VECTOR_STORE_TYPE  | Vector Store Type                 | chroma                | ✅                     |\n| CHROMA_DB_HOST     | ChromaDB Server Address           | localhost             | Required for ChromaDB |\n| CHROMA_DB_PORT     | ChromaDB Port                     | 8000                  | Required for ChromaDB |\n| QDRANT_URL         | Qdrant Vector Store URL           | http:\u002F\u002Flocalhost:6333 | Required for Qdrant   |\n| QDRANT_PREFER_GRPC | Prefer gRPC Connection for Qdrant | true                  | Optional for Qdrant   |\n\n### Object Storage Configuration\n\n| Parameter         | Description          | Default        | Required |\n| ----------------- | -------------------- | -------------- | -------- |\n| MINIO_ENDPOINT    | MinIO Server Address | localhost:9000 | ✅        |\n| MINIO_ACCESS_KEY  | MinIO Access Key     | minioadmin     | ✅        |\n| MINIO_SECRET_KEY  | MinIO Secret Key     | minioadmin     | ✅        |\n| MINIO_BUCKET_NAME | MinIO Bucket Name    | documents      | ✅        |\n\n### Other Configuration\n\n| Parameter | Description      | Default       | Required |\n| --------- | ---------------- | ------------- | -------- |\n| TZ        | Timezone Setting | Asia\u002FShanghai | ❌        |\n\n## 🤝 Contributing\n\nWe welcome community contributions!\n\n### Contribution Process\n\n1. Fork the repository\n2. Create a feature branch (`git checkout -b feature\u002FAmazingFeature`)\n3. Commit changes (`git commit -m 'Add some AmazingFeature'`)\n4. Push to branch (`git push origin feature\u002FAmazingFeature`)\n5. Create a Pull Request\n\n### Development Guidelines\n\n- Follow [Python PEP 8](https:\u002F\u002Fpep8.org\u002F) coding standards\n- Follow [Conventional Commits](https:\u002F\u002Fwww.conventionalcommits.org\u002F)\n\n### 🚧 Roadmap\n\n- [x] Knowledge Base API Integration\n- [ ] Workflow By Natural Language\n- [ ] Multi-path Retrieval\n- [x] Support Multiple Models\n- [x] Support Multiple Vector Databases\n\n## 🔧 Troubleshooting\n\nFor common issues and solutions, please refer to our [Troubleshooting Guide](docs\u002Ftroubleshooting.md).\n\n## 📄 License\n\nThis project is licensed under the [Apache-2.0 License](LICENSE)\n\n## Note\n\nThis project is for learning and sharing RAG knowledge only. Please do not use it for commercial purposes. It is not ready for production use and is still under active development.\n\n## 🙏 Acknowledgments\n\nThanks to these open source projects:\n\n- [FastAPI](https:\u002F\u002Ffastapi.tiangolo.com\u002F)\n- [Langchain](https:\u002F\u002Fpython.langchain.com\u002F)\n- [Next.js](https:\u002F\u002Fnextjs.org\u002F)\n- [ChromaDB](https:\u002F\u002Fwww.trychroma.com\u002F)\n\n\n![star history](https:\u002F\u002Fapi.star-history.com\u002Fsvg?repos=rag-web-ui\u002Frag-web-ui&type=Date)\n\n---\n\n\u003Cdiv align=\"center\">\n  If this project helps you, please consider giving it a ⭐️\n\u003C\u002Fdiv>\n","RAG Web UI 是一个基于 RAG（检索增强生成）技术的智能对话系统，旨在帮助用户构建基于自有知识库的智能问答系统。该项目通过结合文档检索和大型语言模型，实现了准确可靠的基于知识的问答服务，支持包括OpenAI、DeepSeek以及本地部署的Ollama等多种LLM选项，满足不同场景下的隐私与成本需求。此外，它还提供了OpenAPI接口，方便通过API调用来访问知识库。RAG Web UI适用于需要建立个性化知识问答系统的组织或个人，特别是在教育、企业培训和技术支持等领域。",2,"2026-06-11 03:47:18","high_star"]