Practical overview
When it fits
Use it when you want to turn supported text documents into an inspectable relationship graph, or explore sample graphs before configuring a model endpoint. A model endpoint is needed to generate a new graph and to use graph-questioning features; sample browsing does not require one.
Who it is for
- Researchers exploring relationships across text collections
- Teams mapping entities and connections in internal documents
- Developers building graph-based question-answering or document exploration tools
Documented uses
- Extract typed entity relationships from documents and preserve the source sentence for each extracted relationship.
- Explore connections through a searchable graph with relationship details, entity filters and path finding.
- Export graph data for use with formats and tools including JSON, CSV, GraphML, Gephi, yEd, Cytoscape and Neo4j.
- Ask questions grounded in a generated graph using the optional graph-chat command or local interface.
Requirements & limits
The project is open source under the Apache-2.0 license. It is a Python project with command-line tools and an optional local web interface. Published sample graphs can be explored without installation or an LLM endpoint.
- New graph generation requires Python 3.11+ and an OpenAI-compatible model endpoint; a local Ollama endpoint is an option.
- The core dependencies listed are networkx, jinja2 and requests; web, PDF and DOCX capabilities use optional extras.
- The interactive graph is a self-contained HTML output, while graph-serve provides a local browser interface.
- Graph-chat returns grounded, cited answers from a generated graph; it is an optional command.
- Extracted relationships retain their source sentence, and inferred edges carry method information.
Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.
Generate an interactive graph from a text file
Create an HTML knowledge graph and accompanying JSON and metadata files from your own text.
Before you start
- Python 3.11 or later
- An OpenAI-compatible LLM endpoint, with model name and base URL configured in TOML
- A supported input file such as TXT, Markdown or reStructuredText; PDF and DOCX require their optional extras
- The project installed with its web extra, as shown in the documented setup
Steps
Clone the repository and enter its directory.
Install the project with the documented web extra using uv or pip.
Set the model, endpoint and API key in the TOML configuration file.
Run the documented generate-graph command with your input file and an HTML output path.
Expected outcome
The command writes a self-contained interactive HTML page, a JSON file of triples and a metadata JSON file with community names.
Guide limitations
- Generating a new graph requires a reachable configured model endpoint.
- PDF and DOCX inputs need their corresponding optional extras.
- The documented command is for local use; no deployment workflow is described.
Sources & review
Source record details
- Source availability
- Active
- Sources checked
- 30 September 2026
- Original website title
- robert-mcdermott/ai-knowledge-graph · Official homepage title · retained in its source language

