ensure-repo-graph
Skill2 starsChanged 4 months agoMITView on GitHub
Phase 1 engg-reviews: ensure local Graphify code graphs are present and fresh for a fleet of candidate app repos at develop. Resolves candidates from an Impact-Map or PE list, syncs sibling clones, builds or updates graphify-out/, and records develop_sha + graph_digest. Gate-independent — never sets impact-map-* or spec-* labels. Run before /prd-codebase-map.
In this repository22 other files it gives its agents.
- ground-specSkill
- initiative-feasibilitySkill
- learning-extractSkill
- loop-specSkill
- pre-implementSkill
- purge-initiative-artifacts-appSkill
- spec-draftSkill
- spec-implementation-planSkill
- spec-technical-reviewSkill
- post-product-questionsSkill
- prd-codebase-mapSkill
- review-product-questionsSkill
- commit-workspaceSkill
- create-board-ticketsSkill
- open-draft-prSkill
- prd-impact-mapSkill
- prd-qualitySkill
- prd-thinkSkill
- purge-initiative-artifacts-metaSkill
- review-findingsSkill
- update-documentsSkill
- validate-requirementsSkill
The file
We split this skill into the rules it gives an agent
11 rules. About 0 are common, 4 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
Distinctive · estimate
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 30
Use the codegraph provider interface.
- Very specific: line 31
If Graphify (or configured provider) is missing → outcome blocked with install steps.
- Very specific: line 35
Prefer --mode deep for first build.
- Distinctive: line 38
No product questions. No PRD edits.
- Very specific: line 61
Prefer cwd = pe-workspace (or PE states fleet.yaml path).
- Very specific: line 79
Stop with handoff outcome blocked.
- Distinctive: line 86
If missing: clone (only with explicit PE authorization).
- Distinctive: line 93
Prefer pe-workspace helper when present:
- Very specific: line 124
Never: prd-impact-acceptance, prd-merge, spec-draft, or any sdd-delivery/v2 node.
- Very specific: line 130
Use contract: engg-reviews/v1 and stage ensure-repo-graph.
- Very specific: line 137
Always gate_coupled: false.
≈ “Common” is an estimate: at least 1 in 5 of the 372,429 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Ensure repo graph
Make in-depth code graphs available for the candidate fleet so
/prd-codebase-map can ground the PRD. Do not ask product questions.
Do not touch SDD gates.
Provider contract: ../references/codegraph-provider.md.
Handoff: ../references/handoff-adjunct.md.
NON-NEGOTIABLE
- This skill is gate-independent. Never create/update/delete
impact-map-*orspec-*labels. Never claim Gate 1 readiness. - Use the codegraph provider interface. Phase 1 default: local Graphify CLI.
- If Graphify (or configured provider) is missing → outcome
blockedwith install steps. No PASS and no “light skim” substitute. - Each repo must be on integration branch (default
develop) at a recorded SHA before build/update. - Prefer
--mode deepfor first build;--updatewhen graph exists but SHA changed. - Record per-repo
develop_sha+graph_digest(sha256 ofgraph.json). - No product questions. No PRD edits. No app PRs. No GitHub writes unless the user later authorizes unrelated actions outside this skill.
- Dual output: chat fleet table + optional saved status snippet under meta
prd/reports/when useful (Graph-Fleet-Status-{INIT}.md).
Inputs
- Initiative id — (REQUIRED) e.g.
INIT-001 - Candidate repos — (REQUIRED) from one of:
prd/reports/Impact-Map-{INIT}.mdaffected (+ optional transitive) list- PE-supplied list
- resolved
config/service-catalog*.yamlhint (only if PE confirms; same one-file resolver as/prd-impact-map— never hardcode a tenant org)
- Workspace layout — preferred:
{fleet}/pe-workspace/withfleet.yaml+graphs/{repo}/; app code at../{repo}; meta at../drivestream-meta(or{client}-meta). Legacy: cwd = meta with sibling../{repo}graphs (discouraged — pollutes app trees). - Integration branch — default
develop
Process
T0 — Gather
- Prefer cwd = pe-workspace (or PE states
fleet.yamlpath). - Resolve candidate repo list from impact-map /
fleet.yamlinitiatives / PE list. - Cap spike fleets at a reasonable size (document if >5 repos).
T1 — Provider check
command -v graphify || uv tool run --from graphifyy graphify --helpIf unavailable:
blocked: install with `uv tool install graphifyy` (PyPI package graphifyy),
then re-run /ensure-repo-graph.Stop with handoff outcome blocked.
T2 — Sync clones
For each candidate repo:
- Resolve
code_pathfromfleet.yamlor../{repo}relative to fleet root. - If missing: clone (only with explicit PE authorization).
git fetch+ checkout integration branch; recorddevelop_sha.- Fail that row as
blockedif dirty tree would mislead SHA policy — ask PE to stash/clean or confirm.
T3 — Ensure graph
Prefer pe-workspace helper when present:
./bin/refresh-graph.sh {repo} # deep → graphs/{repo}/graphify-out/
./bin/refresh-graph.sh {repo} --update # when graph existsOtherwise, for each repo:
- Build Graphify in
code_path, then copygraphify-out/tographs/{repo}/graphify-out/and remove it from the app clone. - Compute
graph_digest; writegraphs/{repo}/.engg-reviews-meta.json. - Status:
CURRENT|BUILT|UPDATED|FAILED
Canonical query path: graphs/{repo}/graphify-out/graph.json
(not {code_path}/graphify-out/).
T4 — Report
Present references/output-template.md.
Append adjunct handoff (stage: ensure-repo-graph).
| Outcome | When | next_candidates |
pass | All required candidates CURRENT/BUILT/UPDATED | prd-codebase-map |
blocked | Provider missing or any required repo failed | [] or retry ensure |
needs-input | Candidate list unclear | [] |
failed | Unexpected tool error | [] |
Forbidden next_candidates
Never: prd-impact-acceptance, prd-merge, spec-draft, or any sdd-delivery/v2 node.
Workflow handoff
Append the envelope from
../references/handoff-adjunct.md.
Use contract: engg-reviews/v1 and stage ensure-repo-graph.
| Outcome | Next |
pass | /prd-codebase-map |
blocked / failed / needs-input | Fix provider/clones; re-run /ensure-repo-graph |
Always gate_coupled: false. This handoff must not be used to navigate
sdd-delivery/v2 Gate 1/2.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

