diff --git a/cso/SKILL.md b/cso/SKILL.md index 9843d26ca..e74c2aaa4 100644 --- a/cso/SKILL.md +++ b/cso/SKILL.md @@ -755,7 +755,17 @@ Replace `SKILL_NAME`, `OUTCOME`, and `USED_BROWSE` before running. Skills that run plan reviews (`/plan-*-review`, `/codex review`) include the EXIT PLAN MODE GATE blocking checklist at the end of the skill, which verifies the plan file ends with `## GSTACK REVIEW REPORT` before ExitPlanMode is called. Skills that don't run plan reviews (operational skills like `/ship`, `/qa`, `/review`) typically don't operate in plan mode and have no review report to verify; this footer is a no-op for them. Writing the plan file is the one edit allowed in plan mode. +## Brain Context Load +**Skip this entire section if `gbrain` is not on PATH.** + +Extract 2-4 keywords from the user's request. Search the brain: +`gbrain search ""`. Read the top 3 results with +`gbrain get_page ""`. Use that context to inform your analysis. + +If `gbrain search` returns no results or any non-zero exit, proceed +without brain context. Full search/read protocol + examples: +see `docs/gbrain-write-surfaces.md` §Context Load. # /cso — Chief Security Officer Audit (v2) @@ -1228,7 +1238,28 @@ staleness detection: if those files are later deleted, the learning can be flagg **Only log genuine discoveries.** Don't log obvious things. Don't log things the user already knows. A good test: would this insight save time in a future session? If yes, log it. +## Save Results to Brain +**Skip this entire section if `gbrain` is not on PATH.** + +After completing this skill, save the output: + +```bash +gbrain put "security-audits/" --content "$(cat <<'EOF' +--- +title: "Security Audit: " +tags: [security-audit, ] +--- + +EOF +)" +``` + +Then extract person/org entities and create stub pages for each one. +Throttle errors (exit 1 with "throttle"/"rate limit"/"busy") and any +other non-zero exit are transient — don't retry inline. Full entity-stub +template, throttle handling, and backlink protocol: +see `docs/gbrain-write-surfaces.md` §Save Template. ## Important Rules diff --git a/design-consultation/SKILL.md b/design-consultation/SKILL.md index 2ecca91c0..d29e444d9 100644 --- a/design-consultation/SKILL.md +++ b/design-consultation/SKILL.md @@ -924,7 +924,17 @@ If `DESIGN_NOT_AVAILABLE`: Phase 5 falls back to the HTML preview page (still go --- +## Brain Context Load +**Skip this entire section if `gbrain` is not on PATH.** + +Extract 2-4 keywords from the user's request. Search the brain: +`gbrain search ""`. Read the top 3 results with +`gbrain get_page ""`. Use that context to inform your analysis. + +If `gbrain search` returns no results or any non-zero exit, proceed +without brain context. Full search/read protocol + examples: +see `docs/gbrain-write-surfaces.md` §Context Load. ## Prior Learnings @@ -1187,7 +1197,28 @@ staleness detection: if those files are later deleted, the learning can be flagg **Only log genuine discoveries.** Don't log obvious things. Don't log things the user already knows. A good test: would this insight save time in a future session? If yes, log it. +## Save Results to Brain +**Skip this entire section if `gbrain` is not on PATH.** + +After completing this skill, save the output: + +```bash +gbrain put "design-systems/" --content "$(cat <<'EOF' +--- +title: "Design System: " +tags: [design-system, ] +--- + +EOF +)" +``` + +Then extract person/org entities and create stub pages for each one. +Throttle errors (exit 1 with "throttle"/"rate limit"/"busy") and any +other non-zero exit are transient — don't retry inline. Full entity-stub +template, throttle handling, and backlink protocol: +see `docs/gbrain-write-surfaces.md` §Save Template. ## Important Rules diff --git a/design-review/SKILL.md b/design-review/SKILL.md index 6aa627271..bc5aba50d 100644 --- a/design-review/SKILL.md +++ b/design-review/SKILL.md @@ -771,7 +771,17 @@ Replace `SKILL_NAME`, `OUTCOME`, and `USED_BROWSE` before running. Skills that run plan reviews (`/plan-*-review`, `/codex review`) include the EXIT PLAN MODE GATE blocking checklist at the end of the skill, which verifies the plan file ends with `## GSTACK REVIEW REPORT` before ExitPlanMode is called. Skills that don't run plan reviews (operational skills like `/ship`, `/qa`, `/review`) typically don't operate in plan mode and have no review report to verify; this footer is a no-op for them. Writing the plan file is the one edit allowed in plan mode. +## Brain Context Load +**Skip this entire section if `gbrain` is not on PATH.** + +Extract 2-4 keywords from the user's request. Search the brain: +`gbrain search ""`. Read the top 3 results with +`gbrain get_page ""`. Use that context to inform your analysis. + +If `gbrain search` returns no results or any non-zero exit, proceed +without brain context. Full search/read protocol + examples: +see `docs/gbrain-write-surfaces.md` §Context Load. # /design-review: Design Audit → Fix → Verify @@ -1952,7 +1962,14 @@ staleness detection: if those files are later deleted, the learning can be flagg **Only log genuine discoveries.** Don't log obvious things. Don't log things the user already knows. A good test: would this insight save time in a future session? If yes, log it. +## Save Results to Brain +**Skip this entire section if `gbrain` is not on PATH.** + +If the skill output is worth preserving, save it via +`gbrain put "" --content ""`. Full template +(heredoc body, frontmatter shape, entity-stub instructions, throttle +handling): see `docs/gbrain-write-surfaces.md` §Save Template. ## Additional Rules (design-review specific) diff --git a/investigate/SKILL.md b/investigate/SKILL.md index 0e27f4d34..ecc1d7bc6 100644 --- a/investigate/SKILL.md +++ b/investigate/SKILL.md @@ -800,7 +800,19 @@ Fixing symptoms creates whack-a-mole debugging. Every fix that doesn't address r --- +## Brain Context Load +**Skip this entire section if `gbrain` is not on PATH.** + +Extract 2-4 keywords from the user's request. Search the brain: +`gbrain search ""`. Read the top 3 results with +`gbrain get_page ""`. Use that context to inform your analysis. + +If `gbrain search` returns no results or any non-zero exit, proceed +without brain context. Full search/read protocol + examples: +see `docs/gbrain-write-surfaces.md` §Context Load. + +For structured-data extraction requests ("track this", "extract from emails", "build a tracker"), route to GBrain's data-research skill instead: `gbrain call data-research`. ## Phase 1: Root Cause Investigation @@ -1029,7 +1041,28 @@ staleness detection: if those files are later deleted, the learning can be flagg **Only log genuine discoveries.** Don't log obvious things. Don't log things the user already knows. A good test: would this insight save time in a future session? If yes, log it. +## Save Results to Brain +**Skip this entire section if `gbrain` is not on PATH.** + +After completing this skill, save the output: + +```bash +gbrain put "investigations/" --content "$(cat <<'EOF' +--- +title: "Investigation: " +tags: [investigation, ] +--- + +EOF +)" +``` + +Then extract person/org entities and create stub pages for each one. +Throttle errors (exit 1 with "throttle"/"rate limit"/"busy") and any +other non-zero exit are transient — don't retry inline. Full entity-stub +template, throttle handling, and backlink protocol: +see `docs/gbrain-write-surfaces.md` §Save Template. --- diff --git a/office-hours/SKILL.md b/office-hours/SKILL.md index b02ec8fa6..48ab547da 100644 --- a/office-hours/SKILL.md +++ b/office-hours/SKILL.md @@ -848,7 +848,17 @@ You are a **YC office hours partner**. Your job is to ensure the problem is unde --- +## Brain Context Load +**Skip this entire section if `gbrain` is not on PATH.** + +Extract 2-4 keywords from the user's request. Search the brain: +`gbrain search ""`. Read the top 3 results with +`gbrain get_page ""`. Use that context to inform your analysis. + +If `gbrain search` returns no results or any non-zero exit, proceed +without brain context. Full search/read protocol + examples: +see `docs/gbrain-write-surfaces.md` §Context Load. ## Brain Context (preflight) diff --git a/office-hours/sections/design-and-handoff.md b/office-hours/sections/design-and-handoff.md index 9d3f2e19b..1a333a787 100644 --- a/office-hours/sections/design-and-handoff.md +++ b/office-hours/sections/design-and-handoff.md @@ -209,7 +209,28 @@ Present the reviewed design doc to the user via AskUserQuestion: - B) Revise — specify which sections need changes (loop back to revise those sections) - C) Start over — return to Phase 2 +## Save Results to Brain +**Skip this entire section if `gbrain` is not on PATH.** + +After completing this skill, save the output: + +```bash +gbrain put "office-hours/" --content "$(cat <<'EOF' +--- +title: "Office Hours: " +tags: [design-doc, ] +--- + +EOF +)" +``` + +Then extract person/org entities and create stub pages for each one. +Throttle errors (exit 1 with "throttle"/"rate limit"/"busy") and any +other non-zero exit are transient — don't retry inline. Full entity-stub +template, throttle handling, and backlink protocol: +see `docs/gbrain-write-surfaces.md` §Save Template. ## Brain Calibration Write-Back (Phase 2 / gated) diff --git a/plan-ceo-review/SKILL.md b/plan-ceo-review/SKILL.md index 126c9282c..40a608f9f 100644 --- a/plan-ceo-review/SKILL.md +++ b/plan-ceo-review/SKILL.md @@ -1111,7 +1111,17 @@ matches a past learning, display: This makes the compounding visible. The user should see that gstack is getting smarter on their codebase over time. +## Brain Context Load +**Skip this entire section if `gbrain` is not on PATH.** + +Extract 2-4 keywords from the user's request. Search the brain: +`gbrain search ""`. Read the top 3 results with +`gbrain get_page ""`. Use that context to inform your analysis. + +If `gbrain search` returns no results or any non-zero exit, proceed +without brain context. Full search/read protocol + examples: +see `docs/gbrain-write-surfaces.md` §Context Load. ## Brain Context (preflight) diff --git a/plan-ceo-review/sections/review-sections.md b/plan-ceo-review/sections/review-sections.md index 71bae4d93..f467198fd 100644 --- a/plan-ceo-review/sections/review-sections.md +++ b/plan-ceo-review/sections/review-sections.md @@ -828,7 +828,28 @@ staleness detection: if those files are later deleted, the learning can be flagg **Only log genuine discoveries.** Don't log obvious things. Don't log things the user already knows. A good test: would this insight save time in a future session? If yes, log it. +## Save Results to Brain +**Skip this entire section if `gbrain` is not on PATH.** + +After completing this skill, save the output: + +```bash +gbrain put "ceo-plans/" --content "$(cat <<'EOF' +--- +title: "CEO Plan: " +tags: [ceo-plan, ] +--- + +EOF +)" +``` + +Then extract person/org entities and create stub pages for each one. +Throttle errors (exit 1 with "throttle"/"rate limit"/"busy") and any +other non-zero exit are transient — don't retry inline. Full entity-stub +template, throttle handling, and backlink protocol: +see `docs/gbrain-write-surfaces.md` §Save Template. ## Brain Calibration Write-Back (Phase 2 / gated) diff --git a/plan-design-review/sections/review-sections.md b/plan-design-review/sections/review-sections.md index fde4b79f9..a3859eba9 100644 --- a/plan-design-review/sections/review-sections.md +++ b/plan-design-review/sections/review-sections.md @@ -531,7 +531,28 @@ staleness detection: if those files are later deleted, the learning can be flagg **Only log genuine discoveries.** Don't log obvious things. Don't log things the user already knows. A good test: would this insight save time in a future session? If yes, log it. +## Save Results to Brain +**Skip this entire section if `gbrain` is not on PATH.** + +After completing this skill, save the output: + +```bash +gbrain put "design-reviews/" --content "$(cat <<'EOF' +--- +title: "Design Review: " +tags: [design-review, ] +--- + +EOF +)" +``` + +Then extract person/org entities and create stub pages for each one. +Throttle errors (exit 1 with "throttle"/"rate limit"/"busy") and any +other non-zero exit are transient — don't retry inline. Full entity-stub +template, throttle handling, and backlink protocol: +see `docs/gbrain-write-surfaces.md` §Save Template. ## Brain Calibration Write-Back (Phase 2 / gated) diff --git a/plan-devex-review/sections/review-sections.md b/plan-devex-review/sections/review-sections.md index e4ce30a95..5c5ee0bcd 100644 --- a/plan-devex-review/sections/review-sections.md +++ b/plan-devex-review/sections/review-sections.md @@ -769,7 +769,28 @@ staleness detection: if those files are later deleted, the learning can be flagg **Only log genuine discoveries.** Don't log obvious things. Don't log things the user already knows. A good test: would this insight save time in a future session? If yes, log it. +## Save Results to Brain +**Skip this entire section if `gbrain` is not on PATH.** + +After completing this skill, save the output: + +```bash +gbrain put "devex-reviews/" --content "$(cat <<'EOF' +--- +title: "Devex Review: " +tags: [devex-review, ] +--- + +EOF +)" +``` + +Then extract person/org entities and create stub pages for each one. +Throttle errors (exit 1 with "throttle"/"rate limit"/"busy") and any +other non-zero exit are transient — don't retry inline. Full entity-stub +template, throttle handling, and backlink protocol: +see `docs/gbrain-write-surfaces.md` §Save Template. ## Brain Calibration Write-Back (Phase 2 / gated) diff --git a/plan-eng-review/SKILL.md b/plan-eng-review/SKILL.md index 4def7719a..7a5c186c4 100644 --- a/plan-eng-review/SKILL.md +++ b/plan-eng-review/SKILL.md @@ -774,7 +774,17 @@ Replace `SKILL_NAME`, `OUTCOME`, and `USED_BROWSE` before running. Skills that run plan reviews (`/plan-*-review`, `/codex review`) include the EXIT PLAN MODE GATE blocking checklist at the end of the skill, which verifies the plan file ends with `## GSTACK REVIEW REPORT` before ExitPlanMode is called. Skills that don't run plan reviews (operational skills like `/ship`, `/qa`, `/review`) typically don't operate in plan mode and have no review report to verify; this footer is a no-op for them. Writing the plan file is the one edit allowed in plan mode. +## Brain Context Load +**Skip this entire section if `gbrain` is not on PATH.** + +Extract 2-4 keywords from the user's request. Search the brain: +`gbrain search ""`. Read the top 3 results with +`gbrain get_page ""`. Use that context to inform your analysis. + +If `gbrain search` returns no results or any non-zero exit, proceed +without brain context. Full search/read protocol + examples: +see `docs/gbrain-write-surfaces.md` §Context Load. # Plan Review Mode diff --git a/plan-eng-review/sections/review-sections.md b/plan-eng-review/sections/review-sections.md index 7592f0a70..dc6329fab 100644 --- a/plan-eng-review/sections/review-sections.md +++ b/plan-eng-review/sections/review-sections.md @@ -849,7 +849,28 @@ staleness detection: if those files are later deleted, the learning can be flagg **Only log genuine discoveries.** Don't log obvious things. Don't log things the user already knows. A good test: would this insight save time in a future session? If yes, log it. +## Save Results to Brain +**Skip this entire section if `gbrain` is not on PATH.** + +After completing this skill, save the output: + +```bash +gbrain put "eng-reviews/" --content "$(cat <<'EOF' +--- +title: "Eng Review: " +tags: [eng-review, ] +--- + +EOF +)" +``` + +Then extract person/org entities and create stub pages for each one. +Throttle errors (exit 1 with "throttle"/"rate limit"/"busy") and any +other non-zero exit are transient — don't retry inline. Full entity-stub +template, throttle handling, and backlink protocol: +see `docs/gbrain-write-surfaces.md` §Save Template. ## Brain Calibration Write-Back (Phase 2 / gated) diff --git a/qa/SKILL.md b/qa/SKILL.md index 4108212ea..6b58aa6f3 100644 --- a/qa/SKILL.md +++ b/qa/SKILL.md @@ -814,7 +814,17 @@ branch name wherever the instructions say "the base branch" or ``. --- +## Brain Context Load +**Skip this entire section if `gbrain` is not on PATH.** + +Extract 2-4 keywords from the user's request. Search the brain: +`gbrain search ""`. Read the top 3 results with +`gbrain get_page ""`. Use that context to inform your analysis. + +If `gbrain search` returns no results or any non-zero exit, proceed +without brain context. Full search/read protocol + examples: +see `docs/gbrain-write-surfaces.md` §Context Load. # /qa: Test → Fix → Verify @@ -1644,7 +1654,14 @@ staleness detection: if those files are later deleted, the learning can be flagg **Only log genuine discoveries.** Don't log obvious things. Don't log things the user already knows. A good test: would this insight save time in a future session? If yes, log it. +## Save Results to Brain +**Skip this entire section if `gbrain` is not on PATH.** + +If the skill output is worth preserving, save it via +`gbrain put "" --content ""`. Full template +(heredoc body, frontmatter shape, entity-stub instructions, throttle +handling): see `docs/gbrain-write-surfaces.md` §Save Template. ## Additional Rules (qa-specific) diff --git a/retro/SKILL.md b/retro/SKILL.md index cb65e98cf..a6f4cabab 100644 --- a/retro/SKILL.md +++ b/retro/SKILL.md @@ -824,7 +824,17 @@ When the user types `/retro`, run this skill. - `/retro global` — cross-project retro across all AI coding tools (7d default) - `/retro global 14d` — cross-project retro with explicit window +## Brain Context Load +**Skip this entire section if `gbrain` is not on PATH.** + +Extract 2-4 keywords from the user's request. Search the brain: +`gbrain search ""`. Read the top 3 results with +`gbrain get_page ""`. Use that context to inform your analysis. + +If `gbrain search` returns no results or any non-zero exit, proceed +without brain context. Full search/read protocol + examples: +see `docs/gbrain-write-surfaces.md` §Context Load. ## Instructions @@ -1205,7 +1215,28 @@ staleness detection: if those files are later deleted, the learning can be flagg **Only log genuine discoveries.** Don't log obvious things. Don't log things the user already knows. A good test: would this insight save time in a future session? If yes, log it. +## Save Results to Brain +**Skip this entire section if `gbrain` is not on PATH.** + +After completing this skill, save the output: + +```bash +gbrain put "retros/" --content "$(cat <<'EOF' +--- +title: "Retro: " +tags: [retro, ] +--- + +EOF +)" +``` + +Then extract person/org entities and create stub pages for each one. +Throttle errors (exit 1 with "throttle"/"rate limit"/"busy") and any +other non-zero exit are transient — don't retry inline. Full entity-stub +template, throttle handling, and backlink protocol: +see `docs/gbrain-write-surfaces.md` §Save Template. ### Step 10: Week-over-Week Trends (if window >= 14d) diff --git a/ship/SKILL.md b/ship/SKILL.md index edcc5f2df..f23f8fa68 100644 --- a/ship/SKILL.md +++ b/ship/SKILL.md @@ -810,7 +810,17 @@ branch name wherever the instructions say "the base branch" or ``. --- +## Brain Context Load +**Skip this entire section if `gbrain` is not on PATH.** + +Extract 2-4 keywords from the user's request. Search the brain: +`gbrain search ""`. Read the top 3 results with +`gbrain get_page ""`. Use that context to inform your analysis. + +If `gbrain search` returns no results or any non-zero exit, proceed +without brain context. Full search/read protocol + examples: +see `docs/gbrain-write-surfaces.md` §Context Load. # Ship: Fully Automated Ship Workflow diff --git a/ship/sections/adversarial.md b/ship/sections/adversarial.md index c7b2321d1..6099970f9 100644 --- a/ship/sections/adversarial.md +++ b/ship/sections/adversarial.md @@ -179,7 +179,28 @@ staleness detection: if those files are later deleted, the learning can be flagg **Only log genuine discoveries.** Don't log obvious things. Don't log things the user already knows. A good test: would this insight save time in a future session? If yes, log it. +## Save Results to Brain +**Skip this entire section if `gbrain` is not on PATH.** + +After completing this skill, save the output: + +```bash +gbrain put "releases/" --content "$(cat <<'EOF' +--- +title: "Release: " +tags: [release, ] +--- + +EOF +)" +``` + +Then extract person/org entities and create stub pages for each one. +Throttle errors (exit 1 with "throttle"/"rate limit"/"busy") and any +other non-zero exit are transient — don't retry inline. Full entity-stub +template, throttle handling, and backlink protocol: +see `docs/gbrain-write-surfaces.md` §Save Template. ### Refresh learnings for the headline feature on this branch