Docs / Knowledge Graph

Knowledge Graph

The Knowledge Graph is an auto-categorizing knowledge base that stores, links, and visualizes information with semantic connections. It serves as the long-term memory for all agents.

How It Works

When agents generate research, reports, or artifacts, the Knowledge Graph agent automatically:

  1. Ingests the raw content into .magent/vault/raw/
  2. Extracts key entities, topics, and relationships
  3. Creates semantic links between related knowledge entries
  4. Categorizes entries by domain, type, and confidence level
  5. Makes everything searchable and retrievable by other agents

Vault Structure

.magent/vault/
  raw/          Original ingested documents
  wiki/         Processed knowledge articles
  outputs/      Generated artifacts and deliverables

Entry Format

Each knowledge entry is stored as a JSON file with metadata:

{
  "id": "kg-a1b2c3d4",
  "title": "Competitive Analysis: SaaS Market Q1 2026",
  "category": "research",
  "tags": ["saas", "market-analysis", "competitive"],
  "created": "2026-05-20T14:30:00Z",
  "source_agent": "researcher",
  "connections": ["kg-e5f6g7h8", "kg-i9j0k1l2"],
  "confidence": 0.92,
  "content": "..."
}

Radial Visualization

The dashboard provides an interactive radial graph that displays knowledge entries as nodes with connections drawn between semantically related items. Features include:

  • Color coding — Nodes colored by category (research, technical, business, creative)
  • Size weighting — Larger nodes indicate higher connection count or confidence
  • Interactive exploration — Click nodes to expand connections, hover for previews
  • Search and filter — Find entries by keyword, category, or date range

Agent Integration

Any agent can read from and write to the Knowledge Graph:

  • vault_read — Search and retrieve knowledge entries by query or ID
  • vault_write — Store new entries with automatic categorization
  • vault_link — Create explicit connections between entries

The Orchestrator automatically queries the Knowledge Graph for relevant context before delegating tasks, giving agents access to previously gathered intelligence.

Dashboard View

The Knowledge Graph view in the dashboard provides:

  • Radial graph visualization with pan/zoom controls
  • List view with sortable columns (title, category, date, connections)
  • Full-text search across all entries
  • Category filters and date range selectors
  • Entry detail panel with content preview and connection map
  • Manual entry creation and editing