Skip to content

Try It — Knowledge Graph Quick Start

Terminal window
docker run -d --name neo4j \
-p 7474:7474 -p 7687:7687 \
-e NEO4J_AUTH=neo4j/codegraph \
neo4j:5

Verify it’s running: open http://localhost:7474 in your browser.

Terminal window
iw plugin add kg

This installs @intentweave/plugin-kg, which gives the CLI and MCP server a Neo4j-backed persistence capability. (iw plugin add kg-lite installs a zero-config SQLite/CypherLite backend instead, if you don’t want to run Neo4j.)

Terminal window
export NEO4J_URI=bolt://localhost:7687
export NEO4J_PASSWORD=codegraph
export OPENAI_API_KEY=sk-... # only needed for natural-language queries
Terminal window
iw mcp --session my-project

With the MCP server running, use these tools directly from GitHub Copilot chat (or any MCP client):

| Tool | Purpose | | ---------------- | ----------------------------------------------------------- | | kg_query | Natural-language or raw Cypher query against the graph | | kg_context | Build RAG context (topic-based or entity-seeded) for a prompt | | kg_entities | List / search canonical entities | | kg_impact | Semantic impact analysis for a set of changed files | | kg_doc_health | Documentation freshness against the graph | | kg_schema | Graph schema — node labels, relationship types, predicates |

Example prompts once the graph is populated:

  • “Use kg_query to tell me what decisions were made about the database.”
  • “Use kg_context to build context on authentication architecture, 3 hops.”
  • “Use kg_impact to see what’s affected by changes to src/auth.ts.”
Terminal window
# CARI mode (default — no Neo4j needed)
iw intent living
# Full KG mode (requires Neo4j, reads existing graph data)
iw doc-health --neo4j -s my-project

The default CARI mode reads the local SQLite index; --neo4j adds cross-checks against the knowledge graph, if one is populated for that session.

IntentWeave’s KG tools are query-only today. The commands that used to extract documents and persist them into Neo4j (iw run, iw persist) have been removed as part of scoping the product around the CARI Evidence Engine and Intent Engine (see the iw persist entry in the CLI reference).

If you want to populate a graph to query, you currently need to write the entities and relationships yourself (e.g. via Cypher against the schema described in Knowledge Graph — What It Is), or point the KG tools at a Neo4j instance already populated by your own tooling. There is no supported IntentWeave CLI/MCP path to ingest from scratch yet.