diff --git a/cso/SKILL.md b/cso/SKILL.md index a08d7e9fe..d4f84ab34 100644 --- a/cso/SKILL.md +++ b/cso/SKILL.md @@ -784,7 +784,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) @@ -1257,7 +1267,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 83eed0a2d..e6d761dd9 100644 --- a/design-consultation/SKILL.md +++ b/design-consultation/SKILL.md @@ -953,7 +953,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 @@ -1216,7 +1226,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 645453162..b71a441cb 100644 --- a/design-review/SKILL.md +++ b/design-review/SKILL.md @@ -800,7 +800,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 @@ -1981,7 +1991,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 5d54b4256..559211127 100644 --- a/investigate/SKILL.md +++ b/investigate/SKILL.md @@ -829,7 +829,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 @@ -1058,7 +1070,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 83161b8ca..0f78588d6 100644 --- a/office-hours/SKILL.md +++ b/office-hours/SKILL.md @@ -877,7 +877,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 4c253e96a..30fcc9a6b 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 3d3208bee..f325e2f1c 100644 --- a/plan-ceo-review/SKILL.md +++ b/plan-ceo-review/SKILL.md @@ -1140,7 +1140,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 5557a33fa..fc1719fac 100644 --- a/plan-eng-review/SKILL.md +++ b/plan-eng-review/SKILL.md @@ -803,7 +803,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 c1ac10253..8aa7d9cc3 100644 --- a/qa/SKILL.md +++ b/qa/SKILL.md @@ -843,7 +843,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 @@ -1673,7 +1683,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 3fbc44726..0a35a36cb 100644 --- a/retro/SKILL.md +++ b/retro/SKILL.md @@ -853,7 +853,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 @@ -1234,7 +1244,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 eadffaa8f..83ca6fab1 100644 --- a/ship/SKILL.md +++ b/ship/SKILL.md @@ -839,7 +839,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