Skip to main content

Cheat Sheet

Version: 0.3.6-beta | Updated: 2026-04-11

Claude Code only: The /kmgraph: prefix requires Claude Code with this plugin installed. Other IDEs access equivalent functionality through MCP tools.

One-page cheat sheet for the Knowledge Management Graph. For detailed documentation, see Command Guide.


I Want To...โ€‹

  • Start a new knowledge graph โ†’ /kmgraph:init
  • Create a cross-project personal KG โ†’ /kmgraph:init-personal-kg
  • Document what I just learned โ†’ /kmgraph:capture-lesson [topic] (v0.2.1-beta refactored)
  • Find something I documented before โ†’ /kmgraph:recall [query] (v0.2.1-beta refactored)
  • See what's in my knowledge graph โ†’ /kmgraph:status
  • Track a complex bug across multiple attempts โ†’ /kmgraph:meta-issue
  • Set up team knowledge sharing โ†’ /kmgraph:config-sanitization
  • Summarize my current chat session โ†’ /kmgraph:session-summary (v0.2.1-beta refactored)
  • Extract my chat history โ†’ /kmgraph:extract-chat
  • Sync lessons to the knowledge graph โ†’ /kmgraph:update-graph
  • Check for sensitive data before sharing โ†’ /kmgraph:check-sensitive
  • Work with multiple knowledge graphs โ†’ /kmgraph:list then /kmgraph:switch
  • Link lessons to GitHub issues โ†’ /kmgraph:link-issue
  • Update plugin documentation โ†’ /kmgraph:update-doc --user-facing
  • Create comprehensive project handoff โ†’ /kmgraph:handoff

Commands by Difficultyโ€‹

๐ŸŸข Essential (Start Here)โ€‹

First-time users need these for basic operation:

CommandPurpose
/kmgraph:initInitialize a new knowledge graph with wizard-based setup
/kmgraph:init-personal-kgCreate personal KG at ~/.kmgraph/ for cross-project lessons
/kmgraph:capture-lesson [topic]Document lessons learned with git metadata tracking (v0.2.1-beta refactored)
/kmgraph:statusView active knowledge graph info and quick reference
/kmgraph:recall [query]Search across all memory systems (lessons, decisions, knowledge) (v0.2.1-beta refactored)

โ†’ Full details in Command Guide

๐ŸŸก Intermediate (Once Comfortable)โ€‹

Active users use these for regular workflows:

CommandPurpose
/kmgraph:update-graphExtract knowledge graph entries from lessons. Uses background file reading for large batches when context-mode is installed
/kmgraph:add-categoryAdd a new category to existing knowledge graph
/kmgraph:session-summaryCreate summary of current chat session; --snapshot for lightweight mid-session capture (v0.2.2-beta)
/kmgraph:listDisplay all configured knowledge graphs
/kmgraph:switchChange active knowledge graph
/kmgraph:check-sensitiveScan knowledge graph for potentially sensitive information
/kmgraph:config-sanitizationInteractive wizard for pre-commit hook setup
/kmgraph:extract-chatExtract chat history from Claude and Gemini logs (--today, --date, --after, --before, --project)
/kmgraph:update-docUpdate plugin/project docs (--user-facing) or KG content

โ†’ Full details in Command Guide

๐Ÿ”ด Advanced (Power Features)โ€‹

Power users leverage these for complex workflows:

CommandPurpose
/kmgraph:meta-issueInitialize meta-issue tracking for complex multi-attempt problems
/kmgraph:start-issue-trackingInitialize issue tracking with structured docs and Git branch
/kmgraph:update-issue-planSync knowledge graph โ†’ plan โ†’ issue โ†’ GitHub
/kmgraph:link-issueManually link existing lesson or ADR to GitHub issue
/kmgraph:archive-memoryArchive stale MEMORY.md entries to prevent bloat
/kmgraph:restore-memoryRestore archived MEMORY.md entries
/kmgraph:sync-allAutomated full sync pipeline (4 steps โ†’ 1 command). Uses background file scanning when context-mode is installed. Refreshes search index automatically if built
/kmgraph:handoffCreate comprehensive handoff documentation for transitions or onboarding

โ†’ Full details in Command Guide


Auto-Triggered Skillsโ€‹

Skills activate automatically based on conversation context. No invocation needed.

SkillTrigger ConditionSuggests
lesson-captureBug solved, breakthrough made, "figured it out"/kmgraph:capture-lesson with pre-filled context
kg-recallHistory question, "have we solved this?", past decision/kmgraph:recall with extracted search terms
session-wrapContext approaching limit, major milestone, session end/kmgraph:session-summary before compaction
adr-guideArchitecture decision discussed, "I'm thinking of using..."/kmgraph:create-adr with decision guidance
doc-update-router"update [doc name]", "update the session summary", "update the changelog"Routes to /kmgraph:update-doc --user-facing, /kmgraph:session-summary, or /kmgraph:create-adr
capture-router"capture that" / "remember that" / "save that"Auto-detects type+location, single confirmation before writing
gov-execute-plan"execute plan", implementation start, docs/plans/*.md mentionedZero-deviation 8-step execution protocol
stuck-work-escalation3+ failed attempts, 30+ min stuck, same bug resisting fixesOpus diagnosis gate โ†’ hypothesis logging โ†’ exit-path decision at 5 attempts
docs-impact-scan"push to origin", "push and merge", "open PR", "create PR", "finishing up", "ready to push"Scans changed identifiers, validates affected docs list, dispatches /kmgraph:update-doc --user-facing for each
sidebar-updateDoc file moved or renamed, git mv docs/..., "move [doc]", "rename [doc]"Updates stale id: in sidebars.js; scans for broken internal links

Agents Quick Referenceโ€‹

Heavy-lift task handlers. Usually invoked automatically by skills/commands.

AgentWhen UsedExample
lesson-capture-agentCapturing lessons from sessionsAuto-triggered after bug fix
recall-agentSearching knowledge graphVia /kmgraph:recall [query] command
session-summary-agentSession wrap-up and documentationAuto-triggered at end of work
mcp-setup-agentMCP server setup and configurationIDE detection + auto-config
knowledge-extractorBatch KG extraction and parsingVia /kmgraph:sync-all
sync-all-agentExecuting KG sync pipelineVia /kmgraph:sync-all command
create-adr-agentADR creation wizardVia /kmgraph:create-adr command
knowledge-reviewerQuality review for lessons and ADRsVia /kmgraph:update-graph command

See Concepts Guide ยง Four-Layer Architecture for full agent overview and when each operates.


Delegation for Heavy-Lift Tasksโ€‹

When processing large batches or complex files, delegate to subagents to reduce context usage.

Extraction & Parsing (knowledge-extractor)โ€‹

Use for: multi-file analysis, chat history parsing (10+ sessions), large lesson batches (50+ KB)

# Before delegation (default)
/kmgraph:extract-chat --after=2026-02-01 # Loads all sessions into context

# Suggested delegation
/kmgraph:extract-chat --project=knowledge-graph
# (Assistant suggests: "Consider delegating to knowledge-extractor for multi-project filtering")

Documentation & Git (session-documenter)โ€‹

Use for: full session parsing across multiple branches, automated session summaries

# Before delegation (default)
/kmgraph:session-summary # Parses entire chat history in-context

# Suggested delegation
# (Assistant suggests: "For multi-session history, delegate to session-documenter")

Knowledge Graph Updates (knowledge-extractor)โ€‹

Use for: bulk lesson extraction (10+ lessons at once), pattern analysis

# Before delegation (default)
/kmgraph:update-graph # Processes all new lessons in-context

# Suggested delegation
# (Assistant suggests: "For 50+ KB of lessons, delegate to knowledge-extractor")

Key Conceptsโ€‹

  • Knowledge Graph: Structured collection of lessons learned, decisions, and patterns stored as markdown files with YAML frontmatter
  • YAML Frontmatter: Metadata at the top of files (title, date, tags, context, etc.) used for organization and search
  • Git Metadata: Automatic tracking of branch, commit, PR, and issue information when capturing lessons
  • MEMORY.md: Persistent context file synced bidirectionally to Claude's system prompt for cross-session awareness
  • Sanitization: Process of detecting and removing sensitive data (API keys, credentials, PII) before sharing code publicly
  • Meta-Issue: Multi-attempt problem tracking system for complex bugs that span multiple debugging sessions
  • Category: Organizational unit within a knowledge graph (e.g., "debugging", "architecture", "process")
  • Active KG: The currently selected knowledge graph when multiple graphs are configured
  • Session Summary: Markdown summary of a chat session extracted from conversation history
  • Recall: Unified search across lessons learned, decisions, knowledge graph, and session summaries
  • Search Index (kg_fts5_rebuild): Optional catalog of all knowledge graph content. Build or refresh it for faster, relevance-ranked search results. Updates automatically during sync-all once enabled

Common Workflowsโ€‹

First Time Setup (5 minutes)โ€‹

  1. /kmgraph:init โ†’ Follow wizard to configure location, categories, and git strategy

  2. /kmgraph:capture-lesson โ†’ Document your first learning with guided prompts

  3. /kmgraph:status โ†’ Verify everything is working correctly

Daily Use (10 minutes)โ€‹

  1. Solve a problem or learn something new

  2. /kmgraph:capture-lesson โ†’ Document it while fresh in your mind

  3. /kmgraph:update-graph โ†’ Sync to knowledge graph for quick reference

Before Sharing Code (2 minutes)โ€‹

  1. /kmgraph:check-sensitive โ†’ Scan for API keys, credentials, PII

  2. Review findings carefully

  3. Remove sensitive data before git push

Working with Complex Bugs (30+ minutes)โ€‹

  1. /kmgraph:meta-issue โ†’ Initialize tracking for multi-attempt problem

  2. Attempt fixes, document each try

  3. /kmgraph:update-issue-plan โ†’ Sync progress to GitHub issue

Multi-Graph Workflowsโ€‹

  1. /kmgraph:list โ†’ See all configured knowledge graphs

  2. /kmgraph:switch โ†’ Change to different project's KG

  3. Work with that project's knowledge


Quick Tipsโ€‹

  • Start with Essential commands โ€” Add Intermediate and Advanced commands as needs arise
  • Use /kmgraph:status often โ€” Shows what's in your active knowledge graph at a glance
  • /kmgraph:recall searches everything โ€” Lessons, decisions, knowledge entries, and session summaries; add --scope=all to include personal KG
  • MEMORY.md auto-updates โ€” Check it before important sessions to see what context is loaded
  • Commands use colon syntax โ€” It's /kmgraph: not /knowledge- (colon, not hyphen)
  • Git metadata is automatic โ€” Branch, commit, PR, and issue info captured when you create lessons
  • Categories are flexible โ€” Start with defaults, add custom ones with /kmgraph:add-category
  • Sanitization is a wizard โ€” /kmgraph:config-sanitization guides you through pre-commit hook setup
  • Multiple KGs are powerful โ€” Separate knowledge graphs for work, personal, open-source projects; personal KG shares lessons across all of them

Need More Help?โ€‹

  • Want detailed examples? โ†’ Command Guide โ€” All commands with full documentation
  • New to the system? โ†’ Getting Started โ€” Setup and first lesson walkthrough
  • Understanding terminology? โ†’ Concepts Guide โ€” Definitions of all key terms
  • Using other platforms? โ†’ Platform Adaptation โ€” Cursor, Windsurf, Continue setup
  • Configuring settings? โ†’ Configuration Guide โ€” Post-install options and workflows

Getting started:

Learning:

  • Command Reference Guide โ€” Complete command documentation with examples and learning path
  • Concepts Guide โ€” Plain-English definitions and explanations of all key terms
  • Examples โ€” Real-world lesson, ADR, and KG entry examples

Advanced topics:

  • Workflows โ€” Step-by-step guides for manual workflows
  • Platform Adaptation โ€” Integration for Cursor, Windsurf, Continue, VS Code, Aider
  • Style Guide โ€” Documentation authoring standards and best practices

Version: 0.3.6-beta Last Updated: 2026-04-11