Skip to content

Latest commit

 

History

History
126 lines (90 loc) · 2.77 KB

File metadata and controls

126 lines (90 loc) · 2.77 KB

Compass cookbook

The cookbook contains short, outcome-focused recipes. Use it when you already know the problem and want commands, interpretation guidance, and caveats in one place.

Who this page is for: everyday Compass users and integrators.

You will learn: which recipe fits your task and how cookbook pages differ from full guides and references.

Prerequisites: Getting started.

Reading time: 3 minutes.

Pick a problem

I need to… Recipe
estimate the review surface of a symbol or change Impact analysis
map a subsystem or request/data flow Architecture discovery
generate and query graphs in CI CI and automation
diagnose install, build, query, provider, or history trouble Troubleshooting

Recipe format

Each recipe follows:

Problem
  what you are trying to accomplish

Commands
  the smallest copyable workflow

Interpretation
  what the result does and does not prove

Variations
  common changes for nearby tasks

Safety / recovery
  boundaries, failures, and cleanup

For a complete learning path, use a guide. For exact options and schemas, use the reference.

Quick recipes

Find a concept

compass query "payment retry and idempotency"

Then explain one concrete result:

compass explain RetryPolicy

Connect two boundaries

compass path ApiHandler PaymentRepository

Verify each hop in source.

List direct callers

compass query --cql \
  "MATCH (caller)-[:CALLS]->(target)
   WHERE target.label = 'authorize_payment'
   RETURN caller.id, target.id
   ORDER BY caller.id
   LIMIT 100"

Compare two commits

compass diff HEAD~1 HEAD

For scripts:

compass diff HEAD~1 HEAD --format json

For an interactive reviewer report:

compass diff HEAD~1 HEAD --format html --output semantic-diff.html

The resulting standalone report combines the actionable semantic review, unified/split source diffs with an exact-patch fallback, and the changed code subgraph.

Build only structural code knowledge

compass extract . --code-only

Create a reproducible graph for a commit

compass history build HEAD --code-only
compass history export HEAD \
  --format graph-json \
  --output target/head-graph.json

Related pages

Next step: choose the recipe matching your current task and record the graph revision/profile beside any saved result.