Transform your documents into interactive, queryable, and visually engaging knowledge graphs.
GraphMind is a mono-repo that combines the power of FastAPI, LangGraph, and modern frontend technologies to enable seamless document ingestion, processing, and visualization. With GraphMind, you can:
- Ingest and process documents (PDF, TXT, MD, and more).
- Extract entities, relationships, and metrics using LLMs.
- Store and query data with ChromaDB.
- Visualize knowledge graphs in an intuitive React-based UI.
GraphMind/
├── backend/ # Backend service built with FastAPI
│ ├── src/ # Core backend logic
│ │ ├── api/ # FastAPI routes and Pydantic models
│ │ ├── components/ # Modular components for ingestion, processing, and graph building
│ │ ├── workflows/ # LangGraph workflows and state management
│ │ ├── config/ # Configuration and logging
│ ├── tests/ # Pytest test suite
│ └── main.py # FastAPI app entrypoint
├── frontend/ # Frontend application built with Vite + React + TypeScript
│ ├── src/ # React components, hooks, and pages
│ ├── vite.config.ts
│ └── package.json
- Document Ingestion: Supports multiple formats (PDF, TXT, MD, etc.).
- Smart Chunking: Recursive and token-based strategies for text segmentation.
- Semantic Search: Powered by ChromaDB for efficient retrieval.
- Knowledge Graph Extraction: Entity and relationship extraction using LLMs.
- Orchestrated Pipelines: Modular workflows with LangGraph.
- RESTful API: Clean and scalable API endpoints.
- Interactive UI: Upload documents, run queries, and visualize knowledge graphs.
- Modern Stack: Built with Vite, React, TypeScript, and TailwindCSS.
- Real-Time Updates: Seamless integration with backend APIs.
- Backend: Python 3.11, Redis, Docker (optional).
- Frontend: Node.js (v16+), npm or yarn.
- Navigate to the
backend/directory. - Create and activate a virtual environment:
python -m venv .venv source .venv/bin/activate - Create a
.envfile (refer tobackend/README.mdfor required variables). - Install dependencies in editable mode:
pip install -e . - Start the FastAPI server:
uvicorn main:app --reload
- Navigate to the
frontend/directory. - Create a
.envfile with the following content:VITE_API_BASE_URL=http://localhost:8000/api/v1
- Install dependencies:
npm install
- Start the development server:
npm run dev
- Backend: API documentation available at
http://localhost:8000/docs. - Frontend: Open
http://localhost:5173in your browser.
GraphMind is designed for deployment on modern platforms:
- Frontend: Deploy on Vercel for seamless CI/CD.
- Backend: Deploy on Render with Redis for task management.
Refer to the docs/DEPLOYMENT.md for detailed instructions.
- Backend Documentation: backend/README.md
- Frontend Documentation: frontend/README.md
- Redis Optimization: docs/REDIS_OPTIMIZATION.md
- LLM-powered features require an API key. Refer to
backend/README.mdfor environment variable setup. - ChromaDB supports both embedded (persistent client) and remote configurations.
Crafted with ❤️ by the GraphMind team.