Skip to content

Commit 673277a

Browse files
committed
Update v1.01
1 parent feb0762 commit 673277a

957 files changed

Lines changed: 22609 additions & 3525 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.DS_Store

0 Bytes
Binary file not shown.

README.md

Lines changed: 61 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -17,21 +17,26 @@ For more details on the original GraphRAG implementation, please refer to the [G
1717
- **Output Exploration:** Browse and view indexing outputs and artifacts.
1818
- **Logging:** Real-time logging for better debugging and monitoring.
1919
- **Flexible Querying:** Support for global, local, and direct chat queries with customizable parameters.
20+
- **Customizable Visualization:** Adjust graph layout, node sizes, colors, and more to suit your preferences.
2021

2122
![GraphRAG UI](uiv2.png)
2223

2324
## 🗺️ Roadmap
2425

25-
### **Important Note:** GraphRAG Local UI is currently a major work in progress and building a UI around the GraphRAG library has introduced a number of challenges; mainly with the Indexing process. The query works fantastic and provides a number of ways to easily and comprehensively utilize the GraphRAG library to query your indexed data. As I strive to make the application more stable with local LLMs, users should expect to encounter some bugs and breaking changes. I appreciate your patience and feedback during this development phase. If you encounter indexing issues while running this Gradio app while I am debugging it, you can typically run it straight in the terminal with the CLI args and have it work out 80-90% of the time.
26+
### **Important Note:** GraphRAG Local UI is currently a major work in progress and building a UI around the GraphRAG library has introduced a number of challenges; mainly with the Indexing process. The query is also a work in progress as it tends to go between functional and breaking with the changes to the GraphRAG library. As I strive to make the application more stable with local LLMs, users should expect to encounter some bugs and breaking changes. I appreciate your patience and feedback during this development phase. If you encounter indexing issues while running this Gradio app while I am debugging it, you can typically run it straight in the terminal with the CLI args and have it work out 80-90% of the time.
2627

27-
*The app gained traction much quicker than anticipated, so we are actively working to fix bugs and integrate suggested improvements. While it is currently functional, it has been primarily tested on a Mac Studio M2.*
28+
*While it is currently functional, it has only been primarily tested on a Mac Studio M2.*
2829

2930
My vision for GraphRAG Local UI is to become the ultimate GraphRAG app for local LLMs, incorporating as many cool features and knowledge graph tools as possible. I am continuously working on improvements and new features.
3031

3132
### Recent Updates
33+
- [x] Indexing Works! Fixes to the Indexing process and caching of embeddings.
3234
- [x] LLM agnostic: Use Ollama or set your own base URL and local model for LLM and Embedder
3335
- [x] Custom configurable graph visuals
3436
- [x] Preset Query/Indexing library options to quickly and easily harness all the GraphRAG args
37+
- [x] Enhanced UI with tabbed interface for better organization
38+
- [x] Improved file management system
39+
- [x] Real-time indexing progress and control
3540

3641
### Upcoming Features
3742
- [ ] Dockerfile for easier deployment
@@ -85,10 +90,14 @@ Follow these steps to set up and run GraphRAG Local with Interactive UI:
8590
1. **File Upload:**
8691
- Navigate to the "Data Management" tab.
8792
- Use the "File Upload" section to upload .txt files to the input directory.
93+
- Click the "Upload File" button to add your file to the system.
8894

8995
2. **File Management:**
9096
- View, edit, and delete uploaded files in the "File Management" section.
91-
- Use the "Refresh File List" button to update the list of available files.
97+
- Use the dropdown to select a file, then view its content in the text area below.
98+
- Edit the file content directly in the text area and click "Save Changes" to update.
99+
- Use the "Delete Selected File" button to remove a file from the system.
100+
- Click "Refresh File List" to update the list of available files.
92101

93102
### Indexing
94103

@@ -102,67 +111,100 @@ Follow these steps to set up and run GraphRAG Local with Interactive UI:
102111
- Click "Run Indexing" to start the indexing process.
103112
- Monitor progress in real-time through the output box and progress bar.
104113
- Use "Stop Indexing" if you need to halt the process.
114+
- The "Refresh Indexing" button allows you to reset the indexing process if needed.
105115

106-
### KG Chat/Outputs
116+
3. **Custom CLI Arguments:**
117+
- For advanced users, you can add custom CLI arguments in the provided text area.
118+
- Refer to the CLI Argument Key Guide for available options.
119+
120+
### Indexing Outputs/Visuals
107121

108122
1. **Explore Indexed Data:**
109123
- Select an output folder from the dropdown.
110124
- Browse through the folder contents and view file information and content.
125+
- Use the "Initialize Selected Folder" button to load the contents of a specific output folder.
111126

112127
2. **Visualize Graph:**
113128
- Select a GraphML file from the output folder.
114129
- Click "Visualize Graph" to generate a 2D or 3D visualization of your knowledge graph.
115-
- Customize the visualization using the "Visualization Settings" accordion.
130+
- Customize the visualization using the "Visualization Settings" accordion:
131+
- Choose between 3D Spring, 2D Spring, or Circular layouts
132+
- Adjust node size, edge width, and label size
133+
- Select node color attributes and color schemes
134+
- Toggle node labels on/off
116135

117136
### LLM Settings
118137

119138
1. **Configure LLM and Embeddings:**
120139
- Set API base URLs and keys for both LLM and embeddings.
121140
- Choose the service type (OpenAI-compatible or Ollama).
122-
- Select models from the dropdown or refresh the list.
141+
- Select models from the dropdown or refresh the list of available models.
123142

124143
2. **Adjust Parameters:**
125144
- Set the system message, context window, temperature, and max tokens.
126145
- Click "Update LLM Settings" to save your changes.
127146

147+
### YAML Settings
148+
149+
- Adjust additional GraphRAG settings in the "YAML Settings" tab as needed.
150+
- Each setting is presented in an accordion for easy access and editing.
151+
128152
### Querying
129153

130154
1. **Choose Query Type:**
131155
- Select between global, local, or direct chat queries.
132156

133157
2. **Select Preset or Custom Options:**
134158
- Choose a preset query option or customize your query parameters.
159+
- Presets include options like "Default Global Search", "Detailed Local Analysis", "Quick Global Summary", etc.
160+
- For custom queries, you can adjust community level, response type, and add custom CLI arguments.
135161

136162
3. **Enter Your Query:**
137163
- Type your query in the input box and click "Send Query" or press Shift+Enter.
138164

139165
4. **View Results:**
140166
- See the chat history and responses in the chat interface.
167+
- The chat history is preserved between queries for context.
141168

142-
### Other Settings
169+
5. **Clear Chat:**
170+
- Use the "Clear Chat" button to reset the conversation history.
143171

144-
- Adjust additional GraphRAG settings in the "YAML Settings" tab as needed.
172+
### Graph Visualization
173+
174+
1. **Select Output Folder and GraphML File:**
175+
- Choose the output folder and GraphML file you want to visualize.
145176

146-
## 🛠️ Customization
177+
2. **Customize Visualization:**
178+
- Use the "Visualization Settings" accordion to adjust various aspects of the graph:
179+
- Layout Type: Choose between 3D Spring, 2D Spring, or Circular layouts.
180+
- Node Size: Adjust the size of nodes in the graph.
181+
- Edge Width: Change the thickness of edges connecting nodes.
182+
- Node Color Attribute: Color nodes based on their degree or randomly.
183+
- Color Scheme: Select from various color palettes for node coloring.
184+
- Show Node Labels: Toggle the visibility of node labels.
185+
- Label Size: Adjust the size of node labels.
147186

148-
Users can experiment with different models and settings:
187+
3. **Generate Visualization:**
188+
- Click the "Visualize Graph" button to create the graph based on your settings.
149189

150-
- For OpenAI-compatible APIs: Use any model compatible with the OpenAI API format.
151-
- For Ollama: Use models like llama2, mistral, phi-2, etc. Find the complete list of Ollama models [here](https://ollama.com/library).
190+
4. **Interact with the Graph:**
191+
- Once generated, you can interact with the 3D graph by rotating, zooming, and panning.
192+
- Hover over nodes to see additional information.
152193

153194
## 📊 Visualization
154195

155196
The UI includes a 2D/3D graph visualization feature:
156197

157198
1. Run indexing on your data.
158-
2. Go to the "KG Chat/Outputs" tab.
199+
2. Go to the "Indexing Outputs/Visuals" tab.
159200
3. Select the latest output folder and navigate to the GraphML file.
160201
4. Click the "Visualize Graph" button.
161-
5. Customize the visualization using the settings provided.
202+
5. Customize the visualization using the settings provided in the "Visualization Settings" accordion.
162203

163204
## 🚀 Advanced Usage
164205

165-
- **Custom CLI Arguments:** In the query interface, advanced users can add custom CLI arguments for more granular control over the query process.
206+
- **Custom CLI Arguments:** In both the indexing and query interfaces, advanced users can add custom CLI arguments for more granular control over the processes.
207+
- **LLM and Embeddings Configuration:** You can configure different models and APIs for LLM and embeddings separately, allowing for flexible setups.
166208

167209
## 📚 Citations
168210

@@ -172,10 +214,10 @@ The UI includes a 2D/3D graph visualization feature:
172214

173215
## Troubleshooting
174216

175-
- If you can't run `gradio app.py`, try running `pip install --upgrade gradio` and then exit out and start a new terminal. It should then load and launch properly as a Gradio app
217+
- If you can't run `gradio app.py`, try running `pip install --upgrade gradio` and then exit out and start a new terminal. It should then load and launch properly as a Gradio app.
176218
177-
- On Windows, if you run into and encoding/UTF error, you can change it to the correct format in the YAML Settings menu
219+
- On Windows, if you run into an encoding/UTF error, you can change it to the correct format in the YAML Settings menu.
178220
179-
- Indexing Errors: These are still tough to debug a track down as it is dependant on your specific pipeline of llms and embedders. Right now it seems to call /v1/embeddings no matter what in the Index workflow, but I think I found a workaround that allows Ollama and other local options. I'll keep trying to reenforce the Indexing process to make it more stable and robust.
221+
- Indexing Errors: These are still tough to debug and track down as it is dependent on your specific pipeline of LLMs and embedders. Right now it seems to call /v1/embeddings no matter what in the Index workflow, but I think I found a workaround that allows Ollama and other local options. I'll keep trying to reinforce the Indexing process to make it more stable and robust.
180222

181-
For any issues or feature requests, please open an issue on the GitHub repository. Happy knowledge graphing!
223+
For any issues or feature requests, please open an issue on the GitHub repository. Happy knowledge graphing!

0 commit comments

Comments
 (0)