Do you need to file an issue?
Describe the bug

Above is an image showing the portion of community_report extraction prompt.
Entities
id,entity,description
Relationships
id,source,target,description
The context data that is generated ends up having headers that are a bit different
Entities
human_readable_id,title,description
Relationships
human_readable_id,source,target,description
The differences are
For Entities - generate context has human_readable_id instead of id and title instead of entities
For Relationships - generate context has human_readable_id instead of id
The bug can be fixed by modifying the code or making the headers in the prompt compliant with the ones generated by the code.
For code, you would need modifications in these verbs.
This is happening because of
|
node_df[to] = node_df.apply( |
and
|
edge_df[to] = edge_df.apply( |
Steps to reproduce
You can look into the cache files. I am attaching one here.
example_community_report_cache.txt
Expected Behavior
No response
GraphRAG Config Used
Logs and screenshots
No response
Additional Information
- GraphRAG Version:
- Operating System:
- Python Version:
- Related Issues:
Do you need to file an issue?
Describe the bug
Above is an image showing the portion of
community_reportextraction prompt.The context data that is generated ends up having headers that are a bit different
The differences are
For Entities - generate context has
human_readable_idinstead ofidandtitleinstead ofentitiesFor Relationships - generate context has
human_readable_idinstead ofidThe bug can be fixed by modifying the code or making the headers in the prompt compliant with the ones generated by the code.
For code, you would need modifications in these verbs.
This is happening because of
graphrag/graphrag/index/verbs/graph/report/prepare_community_reports_nodes.py
Line 37 in c749fe2
and
graphrag/graphrag/index/verbs/graph/report/prepare_community_reports_edges.py
Line 38 in c749fe2
Steps to reproduce
You can look into the cache files. I am attaching one here.
example_community_report_cache.txt
Expected Behavior
No response
GraphRAG Config Used
# Paste your config hereLogs and screenshots
No response
Additional Information