You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: knowledge_base/AI/KnowledgeGraph.md
+13-23Lines changed: 13 additions & 23 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -53,46 +53,36 @@ If i search for "Animal" with search depth of 2, sematically Cat is similar, Cat
53
53
This is the most popular method of retrieval, the natural language query is converted to cypher query using AI provided the knowledge graph schema
54
54
55
55
### Agentic Retrieval
56
-
This is an extension of cypher Query retrieval technique, when the agent is not satisfied with the retrieved nodes, it can regenerate the cypher query, or nativate to nodes relative to retrieved nodes
56
+
This is an extension of cypher Query retrieval technique, when the agent is not satisfied with the retrieved nodes, it can regenerate the cypher query, or navigate to nodes relative to retrieved nodes
57
57
58
58
### Heirachical Retrieval
59
59
When the knowledge graph grows, the schema of the knowledge graph too grows depending on the type of data that were are storing, the llm which converts natural language query to cypher query maynot be able to interpret such large schema
60
60
So in heirarchical Retrieval, the knowledge graph is built in a way that has high level communities and sub communities
61
61
The schema of high level communities can alone be used in first stage of cypher query generation and the iteration continues for subsequent levels with it's respective schema
62
62
This technique was used in [microsoft graphRAG](https://microsoft.github.io/graphrag/)
- Flexible filtering of nodes, using node properties and relationships
67
+
- Use Semantic search as part of cypher query - [ref](https://neo4j.com/blog/genai/vector-search-deeper-insights/)
68
+
- Use builtin 65+ Advanced [Neo4j Graph Algorithms](https://neo4j.com/docs/graph-data-science/current/algorithms/) like shortest path between nodes, community detection, topological sorting etc
69
+
70
+
## Tips to Build knowledge graphs
71
+
- Build a single knowledge graph instead of multiple small ones
72
+
- Use flexible schema while doing LLM extraction and do cleanup later to avoid dataloss
72
73
73
74
## Limitations
74
-
- Data Cleaning process is difficuilt
75
+
- Data Cleaning process is difficuilt, different nodes with same meaning etc
76
+
- When the graph size increases the schema size will increase too, difficuilt to get cypher query from LLM with large schema in context
0 commit comments