openlore-analyze-codeb…
Run a full static OpenLore analysis and summarize architecture, call graph, refactoring issues, and duplicate code. Use when…
Review code changes using OpenLore risk, call, coverage, and cluster evidence without editing code. Use when asked for a change review, pre-PR safety check, or merge recommendation.
$ npx -y skills add clay-good/OpenLore --skill openlore-review-changes --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/openlore-review-changesContext preview
The summary Claude sees to decide when to auto-load this skill.
Review code changes using OpenLore risk, call, coverage, and cluster evidence without editing code. Use when asked for a change review, pre-PR safety check, or merge recommendation.
name: openlore-review-changes description: Review code changes using OpenLore risk, call, coverage, and cluster evidence without editing code. Use when asked for a change review, pre-PR safety check, or merge recommendation.
Trigger this skill whenever the user asks to **review, audit, or check the safety of recent changes**, with phrasings like:
**No code is written.** Output is a risk-ranked review with a go/no-go recommendation.
---
Ask: which project? Diff against which base? (default: `main`)
Store as `$DIRECTORY` and `$BASE_REF`.
---
Call the openlore MCP tool `detect_changes` with:
{"directory": "$DIRECTORY", "base": "$BASE_REF"}The risk score is **multiplicative**: `likelihood × impact`.
A function with fanIn=0 calling nothing external scores 0 regardless of change size — correct; focus on non-zero scores.
Present a risk-ranked table:
| Rank | Function | File | riskScore | blastRadius | fanIn | testedBy | |---|---|---|---|---|---|---|
Flag:
---
For each function with `riskScore ≥ 5`, call `get_minimal_context`:
{"directory": "$DIRECTORY", "functionName": "$FUNCTION_NAME"}**What to read:**
For each HIGH function, state:
$FUNCTION_NAME ($FILE): Interface frozen? [yes — all callers await | no — mixed] External boundary? [yes: $CALLEES | no] Effective coverage: [strong (called) | weak (imported only) | none] Verdict: [safe | needs direct tests first | coordinate with callers before merge]
---
For any HIGH function whose verdict is not "safe":
{"directory": "$DIRECTORY", "functionName": "$FUNCTION_NAME"}
// get_clusterRead `stats.clusterDensity`:
| Density | Meaning | Action | |---|---|---| | < 0.05 | Sparse — shared utilities | Change isolated; safe to land independently | | 0.05–0.15 | Moderate coupling | Review `internalCallGraph` for transitively dependent functions | | > 0.15 | Dense — tightly interwoven | Coordinate whole cluster; consider feature flag or staged rollout |
---
For each HIGH or MEDIUM function with `testedBy` empty or all `"imported"`:
> "⚠️ `$FUNCTION_NAME` has no direct test coverage. Changes here are not caught by the test suite unless a test directly calls this function. Recommend adding a characterisation test before merging."
Suggest a concrete test scenario based on the function body from `get_minimal_context`.
---
(from Step 2)
(from Steps 3–4)
---
Deterministic, local-first memory and guardrails for AI coding agents with no LLM in the hot path.
Run a full static OpenLore analysis and summarize architecture, call graph, refactoring issues, and duplicate code. Use when…
Transform a feature idea into an annotated story using a Domain Sketch or Constrained Option Tree. Use when asked to brainstorm,…
Debug with OpenLore structural context, an explicit root-cause hypothesis, and RED/GREEN verification. Use when a bug, failure,…
Apply a confirmed .openlore/refactor-plan.md with a test gate after each change. Use when asked to execute or continue an…
Author a new OpenSpec domain specification from deterministic OpenLore MCP evidence. Use when asked to reverse-engineer,…
Implement a brownfield story with OpenLore orientation, risk checks, spec validation, tests, and drift detection. Use when asked…