Dialogue Graph
A library for building, validating, visualizing, and serializing dialogue graphs. Use this when parsing scripts or creating branching narrative structures.
Install
npx skills add UCSB-NLP-Chang/Skill-Usage --skill dialogue-graphgit clone --depth 1 https://github.com/UCSB-NLP-Chang/Skill-Usage.git /tmp/Skill-Usage
mkdir -p ~/.claude/skills
cp -r /tmp/Skill-Usage/tasks/dialogue-parser/environment/skills/dialogue_graph ~/.claude/skills/dialogue-graphPersonal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.
From the SKILL.md
# Dialogue Graph Skill
This skill provides a `dialogue_graph` module to easily build valid dialogue trees/graphs.
## When to use
* **Script Parsers**: When converting text to data.
* **Dialogue Editors**: When building tools to edit conversation flow.
* **Game Logic**: When traversing a dialogue tree.
* **Visualization**: When generating visual diagrams of dialogue flows.
## How to use
Import the module:
```python
from dialogue_graph import Graph, Node, Edge
```
### 1. The `Graph` Class
The main container.
```python
graph = Graph()
```
### 2. Adding Nodes
Define content nodes.
```python
# Regular line
graph.add_node(Node(id="Start", speaker="Guard", text="Halt!", type="line"))
# Choice hub
graph.add_node(Node(id="Choices", type="choice"))
```
### 3. Adding Edges
Connect nodes (transitions).
```python
# Simple transition
graph.add_edge(Edge(source="Start", target="Choices"))
# Choice transition (with text)
graph.add_edge(Edge(source="Choices", target="End", text="1. Run away"))
```
### 4. Export
Serialize to JSON format for the engine.
```python
data = graph.to_dict()
# returns {"nodes": [...], "edges": [...]}
json_str = graph.to_json()
```
### 5. Validation
Check for integrity.
```python
errors = graph.validate()
# Returns list of strings, e.g., ["Edge 'Start'->'Unk' points to missing node 'Unk'"]
```
### 6. Visualization
Generate a PNG/SVG graph diagram.Details
- Skill name
dialogue-graph- Repository
- UCSB-NLP-Chang/Skill-Usage
- Path
tasks/dialogue-parser/environment/skills/dialogue_graph/SKILL.md- Repo updated
- 8 April 2026
FAQ
What does the Dialogue Graph skill do?
A library for building, validating, visualizing, and serializing dialogue graphs. Use this when parsing scripts or creating branching narrative structures.
How do I install the Dialogue Graph skill?
skills CLI (Claude Code, Cursor, Codex and more): npx skills add UCSB-NLP-Chang/Skill-Usage --skill dialogue-graph. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.
Is Dialogue Graph popular?
It lives in UCSB-NLP-Chang/Skill-Usage, which has 49 GitHub stars and 5 forks.
Related skills
Pubchem Database
49UCSB-NLP-Chang/Skill-Usage
Query PubChem via PUG-REST API/PubChemPy (110M+ compounds). Search by name/CID/SMILES, retrieve properties, similarity/substructure searches, bioactivity, for cheminformatics.
Pymatgen
49UCSB-NLP-Chang/Skill-Usage
Materials science toolkit. Crystal structures (CIF, POSCAR), phase diagrams, band structure, DOS, Materials Project integration, format conversion, for computational materials science.
Rdkit
49UCSB-NLP-Chang/Skill-Usage
Cheminformatics toolkit for fine-grained molecular control. SMILES/SDF parsing, descriptors (MW, LogP, TPSA), fingerprints, substructure search, 2D/3D generation, similarity, reactions. For standard workflows with simpler interface, use datamol (wrapper around RDKit). Use rdkit for advanced control, custom sanitization, specialized algorithms.
Power Flow Data
49UCSB-NLP-Chang/Skill-Usage
Power system network data formats and topology. Use when parsing bus, generator, and branch data for power flow analysis.
Analyze CI
49UCSB-NLP-Chang/Skill-Usage
Analyze failed GitHub Action jobs for a pull request.
Automated Review Setup
48sethdford/claude-skills
Set up automated code review tools (linters, SAST, dependency scanning) to reduce manual review burden. Use when configuring CI/CD toolchains.
Browse the most popular Claude skills, all git & code review skills, or write your own with the skills generator.