My context graph

From alivecontext/alive · View interactive version

My context graph is an AI agent skill from the GitHub repository alivecontext/alive. Render an interactive map of your world. Generates the world index from all walnut and bundle frontmatter, then produces a force-directed graph showing connections between walnuts, people, bundles, and tags. Opens in the browser.

How to use this skill

Skill file

Map

Visual overview of the entire ALIVE world — connections, clusters, health.

Not a list (that's the tree in alive:world). Not a search (that's alive:search-world). Map is spatial — it shows how everything connects and where the energy is.


What It Does

1. Generate the World Index

Run generate-index.py from the plugin to walk all walnuts and collect frontmatter. Always use the plugin cache copy — never copy scripts to the world (world-local copies drift from the plugin and produce stale data).

python3 "$ALIVE_PLUGIN_ROOT/scripts/generate-index.py" "$WORLD_ROOT"

The script walks all directories for key.md files, handling both _kernel/key.md (current structure) and root-level key.md (flat/legacy structure). It deduplicates entries and skips template walnuts.

Collected data per walnut:

Projection tiers:

The graph supports three projection levels for controlling visual density:

Default to Tier 2. Offer toggle controls for Tier 1 (simplified) and Tier 3 (full detail).

Outputs:

2. Render the Graph

Run generate-graph.py from the plugin to read the JSON index and generate an interactive D3.js graph.

python3 "$ALIVE_PLUGIN_ROOT/scripts/generate-graph.py" "$WORLD_ROOT"

The graph is written to .alive/context-graph.html — an HTML file with embedded data. Requires internet connection (D3.js loads from CDN, fonts from Fontshare/Google Fonts).

Open in browser:

# macOS
open "$WORLD_ROOT/.alive/context-graph.html"
# Linux
xdg-open "$WORLD_ROOT/.alive/context-graph.html"
# Windows
start "" "$WORLD_ROOT/.alive/context-graph.html"

Theme: Alive branded. Light mode default (cream #FAF8F5, orange primary #F97316). Dark mode toggle (forest green #0A1F0D, copper #B87333 accents). Custom fonts: Array (display), Khand (headings), Inter (body).

Nodes:

Edges:

Color by ALIVE domain:

Colors adapt per theme (lighter in dark mode for visibility).

Size by activity:

Health signals visible:

3. Open in Browser

> **squirrel map generated**
> 58 walnuts, 78 people, 41 bundles
> 60 nodes, 36 links, 11 people connectors
>
> > Opening in browser...

Graph Features

Interactive Controls

Details Panel

Click any node to open a pinned side panel showing:

Search

Theme Toggle

Controls

Bundle Expansion

Click any walnut with bundles to expand them as orbiting nodes:


Files

| File | Purpose |

|------|---------|

| .alive/_index.yaml | Generated world index — human-readable, all frontmatter |

| .alive/_index.json | Generated world index — JSON for graph consumption |

| .alive/context-graph.html | Interactive D3.js graph — self-contained, Alive branded |

| $ALIVE_PLUGIN_ROOT/scripts/generate-index.py | Index generator (walks tree, reads frontmatter, outputs YAML + JSON) |

| $ALIVE_PLUGIN_ROOT/scripts/generate-graph.py | Graph generator (reads JSON index, outputs branded HTML with D3.js) |

Important: Always use the plugin cache copies. Do NOT copy scripts to .alive/scripts/ — world-local copies drift from the plugin on updates and produce stale data (root cause of t003).


Regeneration

The index and graph should be regenerated:

> **squirrel world changed — regenerate map?**
> New walnut created: flux-engine
> 2 new bundles, 1 new person
>
> > Regenerate / Skip

What Map Is NOT

World answers "what should I do?" Map answers "what does my world look like?"

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.