Skip to content

Commit

Permalink
added visualization script for .graphml files
Browse files Browse the repository at this point in the history
  • Loading branch information
TheAiSingularity authored and TheAiSingularity committed Jul 8, 2024
1 parent 91e3ef2 commit 61e5624
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,18 +88,19 @@ Users can experiment by changing the models. The llm model expects language mode
python3 -m graphrag.query --data ./ragtest/output/20240709-024831/artifacts/ --method global "What is machine learning?"
```
**Graphs can be saved which further can be used for visualization by changing the graphml to "true" in the settings.yaml : **
**Graphs can be saved which further can be used for visualization by changing the graphml to "true" in the settings.yaml :**
snapshots:
graphml: true
**To visualize the generated graphml files, you can use : https://gephi.org/users/download/ or the script provided in the repo visualize-graphml.py : **
**To visualize the generated graphml files, you can use : https://gephi.org/users/download/ or the script provided in the repo visualize-graphml.py :**
Pass the path to the .graphml file to the below line in visualize-graphml.py:
graph = nx.read_graphml('output/20240708-161630/artifacts/summarized_graph.graphml')
graph = nx.read_graphml('output/20240708-161630/artifacts/summarized_graph.graphml')
13. **Visualize .graphml :**
```bash
python3 visualize-graphml.py
```
Expand Down

0 comments on commit 61e5624

Please sign in to comment.