{
  "markdown": "# ai-brainmap\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](./LICENSE)\n[![Claude Code Plugin](https://img.shields.io/badge/Claude%20Code-Plugin-blueviolet)](https://docs.anthropic.com/claude-code)\n[![Made in Austria](https://img.shields.io/badge/Made%20in-Austria-red)](https://austro-intelligence.at)\n[![Version](https://img.shields.io/badge/version-0.6.0-green)](./plugins/ai-brainmap/.claude-plugin/plugin.json)\n\n## Live Context Visualizer for Claude Code\n\n<p align=\"center\">\n  <img src=\"https://ai.peab.at/images/ai-brainmap-example.gif\" alt=\"ai-brainmap live demo\">\n</p>\n\n**See what Claude is thinking — in real time, in 2D or 3D.**\n\n`ai-brainmap` turns Claude Code's invisible reasoning into a living mindmap. Every\nuser prompt, tool call and response is rendered on the fly, so you can *watch*\nyour AI work instead of guessing what it's doing.\n\n---\n\n## Install\n\n```text\n/plugin marketplace add Austro-Intelligence/ai-brainmap\n/plugin install ai-brainmap@austro-intelligence\n```\n\nThen in any Claude Code session:\n\n```text\n/brainmap start      # start server + open browser\n/brainmap topictree  # open the cluster-centric view in a second tab\n/brainmap stop       # stop server\n/brainmap status     # is it running?\n/brainmap clear      # reset the map\n```\n\nThe server listens on <http://127.0.0.1:4823>. Set `MINDMAP_PORT` to change the port.\n\n---\n\n### Screenshots\n\n<p align=\"center\">\n  <img src=\"https://ai.peab.at/images/ai-brainmap-screen1-example.png\" alt=\"ai-brainmap screenshot — graph view\" width=\"49%\">\n  <img src=\"https://ai.peab.at/images/ai-brainmap-screen2-example.png\" alt=\"ai-brainmap screenshot — topic tree view\" width=\"49%\">\n</p>\n\n---\n\n## How it works\n\n```\n┌─────────────────┐   hook payload     ┌────────────────────┐\n│ Claude Code     │ ─────────────────> │ mindmap-hook.py    │\n│ (your session)  │                    │ (tiny HTTP client) │\n└─────────────────┘                    └─────────┬──────────┘\n                                                 │ POST /api/thought\n                                                 ▼\n                                       ┌────────────────────┐\n                                       │ mindmap-server.py  │\n                                       │ (127.0.0.1:4823)   │\n                                       │ in-memory state    │\n                                       └─────────┬──────────┘\n                                                 │ SSE /api/stream (push)\n                                                 ▼\n                                       ┌────────────────────┐\n                                       │ public/index.html  │\n                                       │ Three.js + D3      │\n                                       │ force-graph in the │\n                                       │ browser            │\n                                       └────────────────────┘\n```\n\n- A local **Python HTTP server** keeps state and serves the Three.js + D3 frontend.\n- Claude Code **hooks** (`UserPromptSubmit`, `PreToolUse`, `PostToolUse`, `Stop`)\n  push events to the server.\n- A **TranscriptWatcher** additionally tails your *current* session transcript\n  (`~/.claude/projects/…/*.jsonl`) so thinking blocks and assistant text appear\n  too. It only reads the active session's file, never arbitrary paths.\n- The browser receives **live deltas over SSE** (`/api/stream`) and updates the\n  force graph in place; a `/api/state` polling endpoint exists as a fallback for\n  browsers without `EventSource`.\n- Active nodes pulse yellow; finished nodes settle into place.\n- **Optional LLM clustering** can group nodes into topic branches. It stays\n  off unless an OpenAI-compatible endpoint is reachable — see *Privacy &\n  security* below for exactly what data is sent and where. The cluster-centric\n  `topictree` view (`/brainmap topictree`) renders those topics as the main\n  branches; it runs in its own browser tab alongside the default view.\n\n---\n\n## Repository layout\n\n```\nai-brainmap/\n├── .claude-plugin/\n│   └── marketplace.json          # Marketplace manifest\n├── plugins/\n│   └── ai-brainmap/\n│       ├── .claude-plugin/plugin.json\n│       ├── bin/\n│       │   ├── mindmap-server.py # HTTP server + state API\n│       │   └── mindmap-hook.py   # Hook bridge (stdin → POST)\n│       ├── commands/brainmap.md  # /brainmap slash command\n│       ├── hooks/hooks.json      # Claude Code hooks\n│       ├── public/index.html     # Three.js + D3 frontend\n│       └── README.md\n├── LICENSE\n└── README.md\n```\n\n---\n\n## Requirements\n\n- Claude Code\n- Python 3 (preinstalled on macOS/Linux; use the official installer or WSL on Windows)\n- A modern browser with WebGL (Chrome, Safari, Firefox, Edge)\n\n---\n\n## Privacy & security\n\n- **Local by default.** The Python server binds to `127.0.0.1:4823` only —\n  it is not reachable from the network. The frontend makes no outbound calls.\n- **No telemetry.** The plugin sends nothing to Austro Intelligence or any\n  analytics service. Your prompts and tool calls stay on your machine.\n- **Hook failure is silent.** If the server is not running the hook bridge\n  returns immediately (0.4 s timeout) — Claude Code is never blocked by the\n  plugin.\n- **Read-only of your own transcript.** The TranscriptWatcher tails only the\n  *active* session's `*.jsonl`. The replay endpoint (`POST /api/replay`)\n  reads a transcript file you explicitly pass in; neither accesses arbitrary\n  files.\n- **Optional LLM clustering — the one case data leaves the process.** If you\n  configure clustering, the server POSTs node labels/summaries to an\n  OpenAI-compatible endpoint (`{url}:{port}/v1/chat/completions`) to group them\n  into topics. The default target is **`localhost:1234`** (LM Studio / Ollama),\n  so out of the box nothing leaves your machine. If you point the `url` in\n  `~/.claude/brainmap-llm.json` at a **remote** host, your node texts are sent\n  there — only enable that with a provider you trust. Delete the config file (or\n  leave no local LLM running) to keep clustering fully offline.\n\n---\n\n## Customize\n\n- **Port**: set `MINDMAP_PORT` in the environment.\n- **Hook filter**: edit `plugins/ai-brainmap/hooks/hooks.json` — narrow the\n  `matcher` to specific tools if you want a quieter map.\n- **Look & feel**: everything lives in `plugins/ai-brainmap/public/index.html`\n  (Three.js scene graph, D3 force parameters, CSS).\n\n---\n\n## Contributing\n\nIssues and PRs welcome. To hack locally, clone the repo and register it as a\nlocal marketplace:\n\n```text\n/plugin marketplace add /path/to/ai-brainmap\n/plugin install ai-brainmap@austro-intelligence\n```\n\nThen edit files under `plugins/ai-brainmap/` and reload the browser — changes\nin `public/index.html` are picked up on refresh.\n\n---\n\n## License\n\nMIT — see [LICENSE](./LICENSE).\n\n---\n\n![AI Logo](https://ai.peab.at/images/austro_intelligence_fb-titelbild.png)\n\nOpen source. Lightweight. Local by default. Built for developers who want\nclarity, not black boxes.\n\nMade with ❤️ in 🇦🇹 by [Austro Intelligence](https://austro-intelligence.at).\n",
  "bytes": 7020,
  "sha": "985f6566301704bb44b61e4272d520aa0f13f6cd7dab54da9a2d0f94cb5b4cf3",
  "repo_slug": "austro-intelligence/ai-brainmap",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/plg_austro_intelligence_ai_brainmap_ai_brain_f01cae36/readme"
}