How plishh/hipporag works
HippoRAG 2 is an LLM memory and retrieval framework. The principal workflow accepts documents for indexing, extracts entities and relations, builds searchable memory, then answers queries using retrieval and generation; the README Quick Start documents the index-to-QA flow. The graph includes documented evaluation and model-provider capabilities. Several source files were not sampled, so unsourced implementation links are omitted; dashed links mark documented optional endpoint integrations.
Main entry points: HippoRAG.py HippoRAG controller · embedding_store.py Embedding store · base.py LLM interface · gateway_llm.py Gateway LLM
Components 22
Memory workflow
- HippoRAG controller
src/hipporag/HippoRAG.py - Standard RAG
src/hipporag/StandardRAG.py - Text preprocessing
src/hipporag/preprocessing.py - OpenIE extraction
src/hipporag/information_extraction/openie_openai.py - Offline OpenIE
src/hipporag/information_extraction/openie_vllm_offline.py - Retrieval reranking
src/hipporag/rerank.py
Model integrations
- Embedding interface
src/hipporag/embedding_model/base.py - OpenAI embeddings
src/hipporag/embedding_model/OpenAI.py - LLM interface
src/hipporag/llm/base.py - OpenAI LLM
src/hipporag/llm/openai_gpt.py - Gateway LLM
src/hipporag/llm/gateway_llm.py
Index storage
- Embedding store
src/hipporag/embedding_store.py - Chroma backend
src/hipporag/vector_stores/chroma_store.py - Milvus backend
src/hipporag/vector_stores/milvus_store.py - Qdrant backend
src/hipporag/vector_stores/qdrant_store.py - Index state and identity
src/hipporag/utils/state_utils.py
Prompts and evaluation
- Prompt templates
src/hipporag/prompts/prompt_template_manager.py - Entity linking prompts
src/hipporag/prompts/linking.py - Retrieval evaluation
src/hipporag/evaluation/retrieval_eval.py - QA evaluation
src/hipporag/evaluation/qa_eval.py
Other components
- Application user
- OpenAI-compatible endpoint
Connections 20
- Application user → HippoRAG controller: indexes and queries
- Application user → Standard RAG: runs RAG
src/hipporag/StandardRAG.py - HippoRAG controller → OpenIE extraction: extracts facts
src/hipporag/HippoRAG.py - HippoRAG controller → Embedding store: stores embeddings
src/hipporag/HippoRAG.py - HippoRAG controller → Text preprocessing: preprocesses text
src/hipporag/HippoRAG.py - HippoRAG controller → Retrieval reranking: reranks results
src/hipporag/HippoRAG.py - HippoRAG controller → Index state and identity: validates index state
src/hipporag/HippoRAG.py - HippoRAG controller → Retrieval evaluation: evaluates retrieval
src/hipporag/HippoRAG.py - HippoRAG controller → QA evaluation: evaluates answers
src/hipporag/HippoRAG.py - OpenIE extraction → Prompt templates: renders prompts
src/hipporag/information_extraction/openie_openai.py - Offline OpenIE → LLM interface: uses offline LLM
src/hipporag/information_extraction/openie_vllm_offline.py - Embedding interface → OpenAI embeddings: implements interface
- Embedding store → Chroma backend: uses backend
src/hipporag/embedding_store.py - Embedding store → Milvus backend: uses backend
src/hipporag/embedding_store.py - Embedding store → Qdrant backend: uses backend
src/hipporag/embedding_store.py - Gateway LLM → LLM interface: implements interface
src/hipporag/llm/gateway_llm.py - Gateway LLM → OpenAI-compatible endpoint: sends requests
- OpenAI LLM → LLM interface: implements interface
src/hipporag/llm/openai_gpt.py - OpenAI embeddings → OpenAI-compatible endpoint: supports compatible endpoint
- Prompt templates → Entity linking prompts: uses linking prompts