hhy-huang/HiRAG
[EMNLP'25 findings] This is the official repo for the paper, HiRAG: Retrieval-Augmented Generation with Hierarchical Knowledge.
What it solves
HiRAG 透過使用階層式知識,解決了傳統檢索增強生成(RAG)的限制,提升生成答案的完整性、多樣性與整體品質,特別是相較於簡易 RAG 與其他 GraphRAG 實作。
How it works
HiRAG 將知識組織成階層結構,使系統能在不同粒度層級檢索資訊。它支援多種檢索模式:
- Hierarchical (hi):使用階層知識結構的主要方式。
- Local:僅檢索本地知識。
- Global:僅檢索全域知識。
- Bridge:僅檢索連結不同階層的橋接知識。
系統可與各種 LLM API(如 DeepSeek、OpenAI、ChatGLM)整合於生成階段。
Who it’s for
開發者與研究者,想要實作更進階的 RAG 系統,以處理需要高層摘要與詳細本地資訊的複雜查詢。
Highlights
- Hierarchical Knowledge Base:超越平面檢索,採用結構化方法。
- Multi‑mode Retrieval:提供彈性選項,可檢索本地、全域或橋接知識。
- Broad LLM Compatibility:相容第三方 API,如 DeepSeek、OpenAI、ChatGLM。
- Strong Performance:在答案完整性與多樣性上,顯著優於 Naive RAG 與其他 GraphRAG 框架。