{"id":26343669,"url":"https://github.com/anubis-labs/pathrag-system","last_synced_at":"2026-04-07T22:31:18.949Z","repository":{"id":282348360,"uuid":"941908767","full_name":"Anubis-Labs/PathRAG-System","owner":"Anubis-Labs","description":"PathRAG System - A Path-based Retrieval-Augmented Generation implementation with knowledge graph visualization and Ollama integration for enhanced question answering.","archived":false,"fork":false,"pushed_at":"2025-03-03T09:06:00.000Z","size":1926,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-14T05:25:39.040Z","etag":null,"topics":["docker","fastapi","knowledge-graph","llm","ollama","path-based-retrieval","rag","react","retrieval-augmented-generation","weaviate"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Anubis-Labs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-03-03T08:59:24.000Z","updated_at":"2025-03-10T19:30:39.000Z","dependencies_parsed_at":"2025-03-14T05:35:52.564Z","dependency_job_id":null,"html_url":"https://github.com/Anubis-Labs/PathRAG-System","commit_stats":null,"previous_names":["anubis-labs/pathrag-system"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Anubis-Labs%2FPathRAG-System","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Anubis-Labs%2FPathRAG-System/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Anubis-Labs%2FPathRAG-System/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Anubis-Labs%2FPathRAG-System/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Anubis-Labs","download_url":"https://codeload.github.com/Anubis-Labs/PathRAG-System/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243826788,"owners_count":20354222,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","fastapi","knowledge-graph","llm","ollama","path-based-retrieval","rag","react","retrieval-augmented-generation","weaviate"],"created_at":"2025-03-16T05:17:43.174Z","updated_at":"2026-04-07T22:31:18.907Z","avatar_url":"https://github.com/Anubis-Labs.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# PathRAG - Path-based Retrieval Augmented Generation\n\nPathRAG is an implementation of the paper [\"PathRAG: Pruning Graph-based Retrieval Augmented Generation with Relational Paths\"](https://arxiv.org/abs/2502.14902). This system improves retrieval-augmented generation by extracting and utilizing key relational paths from an indexing graph.\n\n## System Overview\n\nThe application consists of four main components running in Docker containers:\n\n1. **Frontend** (React + Vite)\n   - Modern UI built with Material-UI\n   - Interactive knowledge graph visualization\n   - File upload and query interface\n   - Real-time model selection and results display\n\n2. **Backend** (FastAPI)\n   - RESTful API endpoints for data processing\n   - Knowledge graph construction\n   - Path-based retrieval implementation\n   - Integration with Weaviate and Ollama\n\n3. **Weaviate** (Vector Database)\n   - Stores and indexes knowledge graph nodes\n   - Enables semantic similarity search\n   - Manages relationships between entities\n\n4. **Ollama** (LLM Service)\n   - Local LLM deployment\n   - Handles query processing\n   - Generates natural language responses\n\n## Features\n\n- **Document Upload**\n  - Support for PDF, TXT, and DOCX files\n  - Raw text input option\n  - Multiple file upload capability\n  - Progress tracking\n\n- **Knowledge Base Management**\n  - Create and manage multiple knowledge bases\n  - Add descriptions and metadata\n  - Organize documents by topic or domain\n\n- **Knowledge Graph Visualization**\n  - Interactive graph display\n  - Node and relationship exploration\n  - Path visualization for query results\n\n- **Query Interface**\n  - Natural language querying\n  - Model selection dropdown\n  - Query history tracking\n  - Detailed response visualization\n\n## Installation\n\n1. **Prerequisites**\n   - Docker and Docker Compose\n   - Git\n   - 8GB+ RAM recommended\n   - NVIDIA GPU (optional, for improved LLM performance)\n\n2. **Clone the Repository**\n   ```bash\n   git clone https://github.com/your-username/PathRAG.git\n   cd PathRAG\n   ```\n\n3. **Environment Setup**\n   ```bash\n   # Start all services\n   docker-compose up -d\n   ```\n\n4. **Access the Application**\n   - Frontend: http://localhost\n   - Backend API: http://localhost:8000\n   - Weaviate Console: http://localhost:8080\n   - Ollama API: http://localhost:11434\n\n## Architecture\n\n### Frontend (Port 80)\n- Vite + React application\n- Material-UI components\n- Nginx for static file serving and API proxying\n- Environment configuration via VITE_API_URL\n\n### Backend (Port 8000)\n- FastAPI application\n- Uvicorn ASGI server\n- File processing and KG construction\n- Path-based retrieval implementation\n\n### Weaviate (Port 8080)\n- Vector database for KG storage\n- RESTful and GraphQL APIs\n- Configurable vectorizer modules\n- Persistent data storage\n\n### Ollama (Port 11434)\n- Local LLM service\n- Multiple model support\n- REST API for inference\n- Model management\n\n## API Endpoints\n\n### Upload API\n- `POST /upload/files` - Upload documents\n- `POST /upload/knowledge_base` - Create knowledge base\n- `GET /query/kbs` - List knowledge bases\n\n### Query API\n- `GET /query/models` - List available models\n- `POST /query/query` - Execute queries\n- `GET /query/graph` - Retrieve graph data\n\n## Configuration\n\n### Docker Compose\n```yaml\nversion: '3.8'\nservices:\n  frontend:\n    build: ./frontend\n    ports:\n      - \"80:80\"\n    environment:\n      - VITE_API_URL=\n\n  backend:\n    build: ./backend\n    expose:\n      - \"8000\"\n    environment:\n      - WEAVIATE_URL=http://weaviate:8080\n      - OLLAMA_URL=http://ollama:11434\n\n  weaviate:\n    image: semitechnologies/weaviate:1.24.1\n    environment:\n      - QUERY_DEFAULTS_LIMIT=20\n      - AUTHENTICATION_ANONYMOUS_ACCESS_ENABLED=true\n\n  ollama:\n    image: ollama/ollama:latest\n    volumes:\n      - ollama-models:/root/.ollama\n```\n\n## Development\n\n### Frontend Development\n```bash\ncd frontend\nnpm install\nnpm run dev\n```\n\n### Backend Development\n```bash\ncd backend\npip install -r requirements.txt\nuvicorn main:app --reload\n```\n\n## Contributing\n\n1. Fork the repository\n2. Create a feature branch\n3. Commit your changes\n4. Push to the branch\n5. Create a Pull Request\n\n## License\n\n[Add your license information here]\n\n## References\n\n- [PathRAG Paper](https://arxiv.org/abs/2502.14902)\n- [Original PathRAG Repository](https://github.com/BUPT-GAMMA/PathRAG) ","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanubis-labs%2Fpathrag-system","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fanubis-labs%2Fpathrag-system","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanubis-labs%2Fpathrag-system/lists"}