Skip to content

Search is only available in production builds. Try building and previewing the site to test it out locally.

Knowledge Graph

The knowledge graph connects entities with directional edges so you can traverse related context instead of only reading raw text.

This page covers edge types, how links are created, and how graph traversal is used in retrieval and entity inspection.

  1. Create manual links with relation labels:
Terminal window
pgm link <source-id> <target-id> --relation involves
  1. Expand a node’s neighborhood to see neighbors and relationship direction:
Terminal window
pgm expand <entity-id> --depth 2
  1. Delete outdated or incorrect edges when needed:
Terminal window
pgm unlink <edge-id>
  1. Use the same pattern through API endpoints:
  • POST /api/edges
  • DELETE /api/edges/:id
  • GET /api/entities/:id/graph
  • Default relation examples include involves, assigned_to, part_of, blocked_by, mentioned_in, and related_to.
  • Manual edges are typically high-confidence (confidence = 1.0); extracted edges carry model-derived confidence.
  • Duplicate edges are prevented by source/target/relation constraints.