/context-graph:setupfrom context-graph
Bootstraps and verifies Memgraph Context Graph setup for capturing Claude Code activity into a graph database. Runs plugin bootstrap, doctor checks, and config inspection.
Ships in context-graph. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Use this skill when the user asks whether Claude Code activity is being captured, how Memgraph Context Graph hooks work, or why graph facts are missing.
Claude Code Plugin -> Claude Code Runtime Adapter -> Event Protocol -> Graph Connector -> Memgraph.
The plugin only installs runtime hook wiring. It must not assign graph meaning. Graph connectors decide which normalized events matter.
For first-time setup, for example when the session started with a note that the memgraph-context-graph tool isn't installed, run the plugin bootstrap once. It installs the CLI with uv and runs memgraph-context-graph setup claude-code --no-tui, which finds or starts Memgraph (in Docker by default), sets the user's identity and checks the hooks. Ask the user first: it installs software and may start a container. The script is scripts/bootstrap.sh in this plugin's folder, two levels above this skill's folder:
bash <this plugin's folder>/scripts/bootstrap.sh
If setup reports a failure, show the user its "To fix" line; it is the exact command to run next.
Run the single CLI doctor first. It checks the same Python environment that the hook command uses:
memgraph-context-graph doctor --runtime claude-code
If doctor is not available, use the strict hook smoke:
printf '{"hook_event_name":"Stop","session_id":"doctor"}' \
| memgraph-context-graph hook run claude-code --strict
Do not check skills_graph with system python3; memgraph-context-graph may be installed in an isolated uv tool or pipx environment.
Connection settings live in ~/.config/context-graph/config.toml. Hook subprocesses read from this file (not environment variables).
setup writes memgraph.url and identity.user_id; other values (credentials, keys) are set with config set.
View current config:
memgraph-context-graph config show
Set values:
memgraph-context-graph config set identity.user_id "username"
memgraph-context-graph config set memgraph.url "neo4j://coordinator:7687"
memgraph-context-graph config set memgraph.user "username"
memgraph-context-graph config set memgraph.password
memgraph-context-graph config set memgraph.database "dbname"
For HA clusters, use the neo4j:// scheme pointing to any coordinator. The driver handles routing and failover automatically:
memgraph-context-graph config set memgraph.url "neo4j://memgraph-coordinator-1:7687"
Supported keys: identity.user_id, memgraph.url, memgraph.user, memgraph.password, memgraph.database.
If skill usage is missing, inspect whether the session actually read or invoked a skill. Search/list results can be surfacing, not proven usage.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
npx claudepluginhub memgraph/ai-toolkit --plugin context-graphOther plugins' skills for the same job