Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 8500136

Browse files
garrytanclaude
andauthored
feat: remove trigger guard + proactive opt-out prompt (garrytan#457)
* fix: telemetry source tagging + duration guards Add --source, --error-message, --failed-step flags to gstack-telemetry-log. Source tagging (live vs test via GSTACK_TELEMETRY_SOURCE env) prevents E2E tests from polluting production data. Duration guards cap unreasonable values (>24h or negative → null). Partial cherry-pick from garrytan/community-mode — non-breaking parts only. Skips install_fingerprint rename (needs schema migration). Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]> * feat: remove trigger guard + proactive opt-out prompt Remove "MANUAL TRIGGER ONLY" injection from all skill descriptions. This frees 59 chars per skill from the 1024-char Codex description budget and lets skills auto-fire based on semantic matching. Merge auto-fire control into the existing `proactive` setting — when false, Claude won't auto-invoke skills or suggest them. Users are prompted once about this preference (chains after the telemetry prompt, fires on second skill run). Also trims the root gstack description by removing the skill catalog (already in the body), saving ~500 chars. Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]> * chore: bump version and changelog (v0.11.16.0) Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]> --------- Co-authored-by: Claude Opus 4.6 (1M context) <[email protected]>
1 parent 315c172 commit 8500136

36 files changed

Lines changed: 723 additions & 116 deletions

File tree

CHANGELOG.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,16 @@
11
# Changelog
22

3+
## [0.11.17.0] - 2026-03-24 — Cleaner Skill Descriptions + Proactive Opt-Out
4+
5+
### Changed
6+
7+
- **Skill descriptions are now clean and readable.** Removed the ugly "MANUAL TRIGGER ONLY" prefix from every skill description that was wasting 58 characters and causing build errors for Codex integration.
8+
- **You can now opt out of proactive skill suggestions.** The first time you run any gstack skill, you'll be asked whether you want gstack to suggest skills during your workflow. If you prefer to invoke skills manually, just say no — it's saved as a global setting. You can change your mind anytime with `gstack-config set proactive true/false`.
9+
10+
### Fixed
11+
12+
- **Telemetry source tagging no longer crashes.** Fixed duration guards and source field validation in the telemetry logger so it handles edge cases cleanly instead of erroring.
13+
314
## [0.11.16.1] - 2026-03-24 — Installation ID Privacy Fix
415

516
### Fixed

SKILL.md

Lines changed: 28 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,10 @@ name: gstack
33
preamble-tier: 1
44
version: 1.1.0
55
description: |
6-
MANUAL TRIGGER ONLY: invoke only when user types /gstack.
76
Fast headless browser for QA testing and site dogfooding. Navigate pages, interact with
87
elements, verify state, diff before/after, take annotated screenshots, test responsive
98
layouts, forms, uploads, dialogs, and capture bug evidence. Use when asked to open or
109
test a site, verify a deployment, dogfood a user flow, or file a bug with screenshots.
11-
Also suggest adjacent gstack skills by stage: brainstorm /office-hours; strategy
12-
/plan-ceo-review; architecture /plan-eng-review; design /plan-design-review or
13-
/design-consultation; auto-review /autoplan; debugging /investigate; QA /qa; code review
14-
/review; visual audit /design-review; shipping /ship; docs /document-release; retro
15-
/retro; second opinion /codex; prod safety /careful or /guard; scoped edits /freeze or
16-
/unfreeze; gstack upgrades /gstack-upgrade. If the user opts out of suggestions, stop
17-
and run gstack-config set proactive false; if they opt back in, run gstack-config set
18-
proactive true.
1910
allowed-tools:
2011
- Bash
2112
- Read
@@ -36,9 +27,11 @@ _SESSIONS=$(find ~/.gstack/sessions -mmin -120 -type f 2>/dev/null | wc -l | tr
3627
find ~/.gstack/sessions -mmin +120 -type f -delete 2>/dev/null || true
3728
_CONTRIB=$(~/.claude/skills/gstack/bin/gstack-config get gstack_contributor 2>/dev/null || true)
3829
_PROACTIVE=$(~/.claude/skills/gstack/bin/gstack-config get proactive 2>/dev/null || echo "true")
30+
_PROACTIVE_PROMPTED=$([ -f ~/.gstack/.proactive-prompted ] && echo "yes" || echo "no")
3931
_BRANCH=$(git branch --show-current 2>/dev/null || echo "unknown")
4032
echo "BRANCH: $_BRANCH"
4133
echo "PROACTIVE: $_PROACTIVE"
34+
echo "PROACTIVE_PROMPTED: $_PROACTIVE_PROMPTED"
4235
source <(~/.claude/skills/gstack/bin/gstack-repo-mode 2>/dev/null) || true
4336
REPO_MODE=${REPO_MODE:-unknown}
4437
echo "REPO_MODE: $REPO_MODE"
@@ -56,8 +49,11 @@ echo '{"skill":"gstack","ts":"'$(date -u +%Y-%m-%dT%H:%M:%SZ)'","repo":"'$(basen
5649
for _PF in $(find ~/.gstack/analytics -maxdepth 1 -name '.pending-*' 2>/dev/null); do [ -f "$_PF" ] && ~/.claude/skills/gstack/bin/gstack-telemetry-log --event-type skill_run --skill _pending_finalize --outcome unknown --session-id "$_SESSION_ID" 2>/dev/null || true; break; done
5750
```
5851

59-
If `PROACTIVE` is `"false"`, do not proactively suggest gstack skills — only invoke
60-
them when the user explicitly asks. The user opted out of proactive suggestions.
52+
If `PROACTIVE` is `"false"`, do not proactively suggest gstack skills AND do not
53+
auto-invoke skills based on conversation context. Only run skills the user explicitly
54+
types (e.g., /qa, /ship). If you would have auto-invoked a skill, instead briefly say:
55+
"I think /skillname might help here — want me to run it?" and wait for confirmation.
56+
The user opted out of proactive behavior.
6157

6258
If output shows `UPGRADE_AVAILABLE <old> <new>`: read `~/.claude/skills/gstack/gstack-upgrade/SKILL.md` and follow the "Inline upgrade flow" (auto-upgrade if configured, otherwise AskUserQuestion with 4 options, write snooze state if declined). If `JUST_UPGRADED <from> <to>`: tell user "Running gstack v{to} (just updated!)" and continue.
6359

@@ -106,6 +102,27 @@ touch ~/.gstack/.telemetry-prompted
106102

107103
This only happens once. If `TEL_PROMPTED` is `yes`, skip this entirely.
108104

105+
If `PROACTIVE_PROMPTED` is `no` AND `TEL_PROMPTED` is `yes`: After telemetry is handled,
106+
ask the user about proactive behavior. Use AskUserQuestion:
107+
108+
> gstack can proactively figure out when you might need a skill while you work —
109+
> like suggesting /qa when you say "does this work?" or /investigate when you hit
110+
> a bug. We recommend keeping this on — it speeds up every part of your workflow.
111+
112+
Options:
113+
- A) Keep it on (recommended)
114+
- B) Turn it off — I'll type /commands myself
115+
116+
If A: run `~/.claude/skills/gstack/bin/gstack-config set proactive true`
117+
If B: run `~/.claude/skills/gstack/bin/gstack-config set proactive false`
118+
119+
Always run:
120+
```bash
121+
touch ~/.gstack/.proactive-prompted
122+
```
123+
124+
This only happens once. If `PROACTIVE_PROMPTED` is `yes`, skip this entirely.
125+
109126
## Contributor Mode
110127

111128
If `_CONTRIB` is `true`: you are in **contributor mode**. At the end of each major workflow step, rate your gstack experience 0-10. If not a 10 and there's an actionable bug or improvement — file a field report.

SKILL.md.tmpl

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,6 @@ description: |
77
elements, verify state, diff before/after, take annotated screenshots, test responsive
88
layouts, forms, uploads, dialogs, and capture bug evidence. Use when asked to open or
99
test a site, verify a deployment, dogfood a user flow, or file a bug with screenshots.
10-
Also suggest adjacent gstack skills by stage: brainstorm /office-hours; strategy
11-
/plan-ceo-review; architecture /plan-eng-review; design /plan-design-review or
12-
/design-consultation; auto-review /autoplan; debugging /investigate; QA /qa; code review
13-
/review; visual audit /design-review; shipping /ship; docs /document-release; retro
14-
/retro; second opinion /codex; prod safety /careful or /guard; scoped edits /freeze or
15-
/unfreeze; gstack upgrades /gstack-upgrade. If the user opts out of suggestions, stop
16-
and run gstack-config set proactive false; if they opt back in, run gstack-config set
17-
proactive true.
1810
allowed-tools:
1911
- Bash
2012
- Read

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.11.16.1
1+
0.11.17.0

autoplan/SKILL.md

Lines changed: 28 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ name: autoplan
33
preamble-tier: 3
44
version: 1.0.0
55
description: |
6-
MANUAL TRIGGER ONLY: invoke only when user types /autoplan.
76
Auto-review pipeline — reads the full CEO, design, and eng review skills from disk
87
and runs them sequentially with auto-decisions using 6 decision principles. Surfaces
98
taste decisions (close approaches, borderline scope, codex disagreements) at a final
@@ -37,9 +36,11 @@ _SESSIONS=$(find ~/.gstack/sessions -mmin -120 -type f 2>/dev/null | wc -l | tr
3736
find ~/.gstack/sessions -mmin +120 -type f -delete 2>/dev/null || true
3837
_CONTRIB=$(~/.claude/skills/gstack/bin/gstack-config get gstack_contributor 2>/dev/null || true)
3938
_PROACTIVE=$(~/.claude/skills/gstack/bin/gstack-config get proactive 2>/dev/null || echo "true")
39+
_PROACTIVE_PROMPTED=$([ -f ~/.gstack/.proactive-prompted ] && echo "yes" || echo "no")
4040
_BRANCH=$(git branch --show-current 2>/dev/null || echo "unknown")
4141
echo "BRANCH: $_BRANCH"
4242
echo "PROACTIVE: $_PROACTIVE"
43+
echo "PROACTIVE_PROMPTED: $_PROACTIVE_PROMPTED"
4344
source <(~/.claude/skills/gstack/bin/gstack-repo-mode 2>/dev/null) || true
4445
REPO_MODE=${REPO_MODE:-unknown}
4546
echo "REPO_MODE: $REPO_MODE"
@@ -57,8 +58,11 @@ echo '{"skill":"autoplan","ts":"'$(date -u +%Y-%m-%dT%H:%M:%SZ)'","repo":"'$(bas
5758
for _PF in $(find ~/.gstack/analytics -maxdepth 1 -name '.pending-*' 2>/dev/null); do [ -f "$_PF" ] && ~/.claude/skills/gstack/bin/gstack-telemetry-log --event-type skill_run --skill _pending_finalize --outcome unknown --session-id "$_SESSION_ID" 2>/dev/null || true; break; done
5859
```
5960

60-
If `PROACTIVE` is `"false"`, do not proactively suggest gstack skills — only invoke
61-
them when the user explicitly asks. The user opted out of proactive suggestions.
61+
If `PROACTIVE` is `"false"`, do not proactively suggest gstack skills AND do not
62+
auto-invoke skills based on conversation context. Only run skills the user explicitly
63+
types (e.g., /qa, /ship). If you would have auto-invoked a skill, instead briefly say:
64+
"I think /skillname might help here — want me to run it?" and wait for confirmation.
65+
The user opted out of proactive behavior.
6266

6367
If output shows `UPGRADE_AVAILABLE <old> <new>`: read `~/.claude/skills/gstack/gstack-upgrade/SKILL.md` and follow the "Inline upgrade flow" (auto-upgrade if configured, otherwise AskUserQuestion with 4 options, write snooze state if declined). If `JUST_UPGRADED <from> <to>`: tell user "Running gstack v{to} (just updated!)" and continue.
6468

@@ -107,6 +111,27 @@ touch ~/.gstack/.telemetry-prompted
107111

108112
This only happens once. If `TEL_PROMPTED` is `yes`, skip this entirely.
109113

114+
If `PROACTIVE_PROMPTED` is `no` AND `TEL_PROMPTED` is `yes`: After telemetry is handled,
115+
ask the user about proactive behavior. Use AskUserQuestion:
116+
117+
> gstack can proactively figure out when you might need a skill while you work —
118+
> like suggesting /qa when you say "does this work?" or /investigate when you hit
119+
> a bug. We recommend keeping this on — it speeds up every part of your workflow.
120+
121+
Options:
122+
- A) Keep it on (recommended)
123+
- B) Turn it off — I'll type /commands myself
124+
125+
If A: run `~/.claude/skills/gstack/bin/gstack-config set proactive true`
126+
If B: run `~/.claude/skills/gstack/bin/gstack-config set proactive false`
127+
128+
Always run:
129+
```bash
130+
touch ~/.gstack/.proactive-prompted
131+
```
132+
133+
This only happens once. If `PROACTIVE_PROMPTED` is `yes`, skip this entirely.
134+
110135
## AskUserQuestion Format
111136

112137
**ALWAYS follow this structure for every AskUserQuestion call:**

benchmark/SKILL.md

Lines changed: 28 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ name: benchmark
33
preamble-tier: 1
44
version: 1.0.0
55
description: |
6-
MANUAL TRIGGER ONLY: invoke only when user types /benchmark.
76
Performance regression detection using the browse daemon. Establishes
87
baselines for page load times, Core Web Vitals, and resource sizes.
98
Compares before/after on every PR. Tracks performance trends over time.
@@ -30,9 +29,11 @@ _SESSIONS=$(find ~/.gstack/sessions -mmin -120 -type f 2>/dev/null | wc -l | tr
3029
find ~/.gstack/sessions -mmin +120 -type f -delete 2>/dev/null || true
3130
_CONTRIB=$(~/.claude/skills/gstack/bin/gstack-config get gstack_contributor 2>/dev/null || true)
3231
_PROACTIVE=$(~/.claude/skills/gstack/bin/gstack-config get proactive 2>/dev/null || echo "true")
32+
_PROACTIVE_PROMPTED=$([ -f ~/.gstack/.proactive-prompted ] && echo "yes" || echo "no")
3333
_BRANCH=$(git branch --show-current 2>/dev/null || echo "unknown")
3434
echo "BRANCH: $_BRANCH"
3535
echo "PROACTIVE: $_PROACTIVE"
36+
echo "PROACTIVE_PROMPTED: $_PROACTIVE_PROMPTED"
3637
source <(~/.claude/skills/gstack/bin/gstack-repo-mode 2>/dev/null) || true
3738
REPO_MODE=${REPO_MODE:-unknown}
3839
echo "REPO_MODE: $REPO_MODE"
@@ -50,8 +51,11 @@ echo '{"skill":"benchmark","ts":"'$(date -u +%Y-%m-%dT%H:%M:%SZ)'","repo":"'$(ba
5051
for _PF in $(find ~/.gstack/analytics -maxdepth 1 -name '.pending-*' 2>/dev/null); do [ -f "$_PF" ] && ~/.claude/skills/gstack/bin/gstack-telemetry-log --event-type skill_run --skill _pending_finalize --outcome unknown --session-id "$_SESSION_ID" 2>/dev/null || true; break; done
5152
```
5253

53-
If `PROACTIVE` is `"false"`, do not proactively suggest gstack skills — only invoke
54-
them when the user explicitly asks. The user opted out of proactive suggestions.
54+
If `PROACTIVE` is `"false"`, do not proactively suggest gstack skills AND do not
55+
auto-invoke skills based on conversation context. Only run skills the user explicitly
56+
types (e.g., /qa, /ship). If you would have auto-invoked a skill, instead briefly say:
57+
"I think /skillname might help here — want me to run it?" and wait for confirmation.
58+
The user opted out of proactive behavior.
5559

5660
If output shows `UPGRADE_AVAILABLE <old> <new>`: read `~/.claude/skills/gstack/gstack-upgrade/SKILL.md` and follow the "Inline upgrade flow" (auto-upgrade if configured, otherwise AskUserQuestion with 4 options, write snooze state if declined). If `JUST_UPGRADED <from> <to>`: tell user "Running gstack v{to} (just updated!)" and continue.
5761

@@ -100,6 +104,27 @@ touch ~/.gstack/.telemetry-prompted
100104

101105
This only happens once. If `TEL_PROMPTED` is `yes`, skip this entirely.
102106

107+
If `PROACTIVE_PROMPTED` is `no` AND `TEL_PROMPTED` is `yes`: After telemetry is handled,
108+
ask the user about proactive behavior. Use AskUserQuestion:
109+
110+
> gstack can proactively figure out when you might need a skill while you work —
111+
> like suggesting /qa when you say "does this work?" or /investigate when you hit
112+
> a bug. We recommend keeping this on — it speeds up every part of your workflow.
113+
114+
Options:
115+
- A) Keep it on (recommended)
116+
- B) Turn it off — I'll type /commands myself
117+
118+
If A: run `~/.claude/skills/gstack/bin/gstack-config set proactive true`
119+
If B: run `~/.claude/skills/gstack/bin/gstack-config set proactive false`
120+
121+
Always run:
122+
```bash
123+
touch ~/.gstack/.proactive-prompted
124+
```
125+
126+
This only happens once. If `PROACTIVE_PROMPTED` is `yes`, skip this entirely.
127+
103128
## Contributor Mode
104129

105130
If `_CONTRIB` is `true`: you are in **contributor mode**. At the end of each major workflow step, rate your gstack experience 0-10. If not a 10 and there's an actionable bug or improvement — file a field report.

bin/gstack-telemetry-log

Lines changed: 34 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -32,21 +32,30 @@ OUTCOME="unknown"
3232
USED_BROWSE="false"
3333
SESSION_ID=""
3434
ERROR_CLASS=""
35+
ERROR_MESSAGE=""
36+
FAILED_STEP=""
3537
EVENT_TYPE="skill_run"
38+
SOURCE=""
3639

3740
while [ $# -gt 0 ]; do
3841
case "$1" in
39-
--skill) SKILL="$2"; shift 2 ;;
40-
--duration) DURATION="$2"; shift 2 ;;
41-
--outcome) OUTCOME="$2"; shift 2 ;;
42-
--used-browse) USED_BROWSE="$2"; shift 2 ;;
43-
--session-id) SESSION_ID="$2"; shift 2 ;;
44-
--error-class) ERROR_CLASS="$2"; shift 2 ;;
45-
--event-type) EVENT_TYPE="$2"; shift 2 ;;
42+
--skill) SKILL="$2"; shift 2 ;;
43+
--duration) DURATION="$2"; shift 2 ;;
44+
--outcome) OUTCOME="$2"; shift 2 ;;
45+
--used-browse) USED_BROWSE="$2"; shift 2 ;;
46+
--session-id) SESSION_ID="$2"; shift 2 ;;
47+
--error-class) ERROR_CLASS="$2"; shift 2 ;;
48+
--error-message) ERROR_MESSAGE="$2"; shift 2 ;;
49+
--failed-step) FAILED_STEP="$2"; shift 2 ;;
50+
--event-type) EVENT_TYPE="$2"; shift 2 ;;
51+
--source) SOURCE="$2"; shift 2 ;;
4652
*) shift ;;
4753
esac
4854
done
4955

56+
# Source: flag > env > default 'live'
57+
SOURCE="${SOURCE:-${GSTACK_TELEMETRY_SOURCE:-live}}"
58+
5059
# ─── Read telemetry tier ─────────────────────────────────────
5160
TIER="$("$CONFIG_CMD" get telemetry 2>/dev/null || true)"
5261
TIER="${TIER:-off}"
@@ -146,6 +155,20 @@ mkdir -p "$ANALYTICS_DIR"
146155
ERR_FIELD="null"
147156
[ -n "$ERROR_CLASS" ] && ERR_FIELD="\"$ERROR_CLASS\""
148157

158+
ERR_MSG_FIELD="null"
159+
[ -n "$ERROR_MESSAGE" ] && ERR_MSG_FIELD="\"$(echo "$ERROR_MESSAGE" | head -c 200 | sed 's/"/\\"/g')\""
160+
161+
STEP_FIELD="null"
162+
[ -n "$FAILED_STEP" ] && STEP_FIELD="\"$(echo "$FAILED_STEP" | head -c 30)\""
163+
164+
# Cap unreasonable durations
165+
if [ -n "$DURATION" ] && [ "$DURATION" -gt 86400 ] 2>/dev/null; then
166+
DURATION="" # null if > 24h
167+
fi
168+
if [ -n "$DURATION" ] && [ "$DURATION" -lt 0 ] 2>/dev/null; then
169+
DURATION="" # null if negative
170+
fi
171+
149172
DUR_FIELD="null"
150173
[ -n "$DURATION" ] && DUR_FIELD="$DURATION"
151174

@@ -155,10 +178,11 @@ INSTALL_FIELD="null"
155178
BROWSE_BOOL="false"
156179
[ "$USED_BROWSE" = "true" ] && BROWSE_BOOL="true"
157180

158-
printf '{"v":1,"ts":"%s","event_type":"%s","skill":"%s","session_id":"%s","gstack_version":"%s","os":"%s","arch":"%s","duration_s":%s,"outcome":"%s","error_class":%s,"used_browse":%s,"sessions":%s,"installation_id":%s,"_repo_slug":"%s","_branch":"%s"}\n' \
181+
printf '{"v":1,"ts":"%s","event_type":"%s","skill":"%s","session_id":"%s","gstack_version":"%s","os":"%s","arch":"%s","duration_s":%s,"outcome":"%s","error_class":%s,"error_message":%s,"failed_step":%s,"used_browse":%s,"sessions":%s,"installation_id":%s,"source":"%s","_repo_slug":"%s","_branch":"%s"}\n' \
159182
"$TS" "$EVENT_TYPE" "$SKILL" "$SESSION_ID" "$GSTACK_VERSION" "$OS" "$ARCH" \
160-
"$DUR_FIELD" "$OUTCOME" "$ERR_FIELD" "$BROWSE_BOOL" "${SESSIONS:-1}" \
161-
"$INSTALL_FIELD" "$REPO_SLUG" "$BRANCH" >> "$JSONL_FILE" 2>/dev/null || true
183+
"$DUR_FIELD" "$OUTCOME" "$ERR_FIELD" "$ERR_MSG_FIELD" "$STEP_FIELD" \
184+
"$BROWSE_BOOL" "${SESSIONS:-1}" \
185+
"$INSTALL_FIELD" "$SOURCE" "$REPO_SLUG" "$BRANCH" >> "$JSONL_FILE" 2>/dev/null || true
162186

163187
# ─── Trigger sync if tier is not off ─────────────────────────
164188
SYNC_CMD="$GSTACK_DIR/bin/gstack-telemetry-sync"

browse/SKILL.md

Lines changed: 28 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ name: browse
33
preamble-tier: 1
44
version: 1.1.0
55
description: |
6-
MANUAL TRIGGER ONLY: invoke only when user types /browse.
76
Fast headless browser for QA testing and site dogfooding. Navigate any URL, interact with
87
elements, verify page state, diff before/after actions, take annotated screenshots, check
98
responsive layouts, test forms and uploads, handle dialogs, and assert element states.
@@ -30,9 +29,11 @@ _SESSIONS=$(find ~/.gstack/sessions -mmin -120 -type f 2>/dev/null | wc -l | tr
3029
find ~/.gstack/sessions -mmin +120 -type f -delete 2>/dev/null || true
3130
_CONTRIB=$(~/.claude/skills/gstack/bin/gstack-config get gstack_contributor 2>/dev/null || true)
3231
_PROACTIVE=$(~/.claude/skills/gstack/bin/gstack-config get proactive 2>/dev/null || echo "true")
32+
_PROACTIVE_PROMPTED=$([ -f ~/.gstack/.proactive-prompted ] && echo "yes" || echo "no")
3333
_BRANCH=$(git branch --show-current 2>/dev/null || echo "unknown")
3434
echo "BRANCH: $_BRANCH"
3535
echo "PROACTIVE: $_PROACTIVE"
36+
echo "PROACTIVE_PROMPTED: $_PROACTIVE_PROMPTED"
3637
source <(~/.claude/skills/gstack/bin/gstack-repo-mode 2>/dev/null) || true
3738
REPO_MODE=${REPO_MODE:-unknown}
3839
echo "REPO_MODE: $REPO_MODE"
@@ -50,8 +51,11 @@ echo '{"skill":"browse","ts":"'$(date -u +%Y-%m-%dT%H:%M:%SZ)'","repo":"'$(basen
5051
for _PF in $(find ~/.gstack/analytics -maxdepth 1 -name '.pending-*' 2>/dev/null); do [ -f "$_PF" ] && ~/.claude/skills/gstack/bin/gstack-telemetry-log --event-type skill_run --skill _pending_finalize --outcome unknown --session-id "$_SESSION_ID" 2>/dev/null || true; break; done
5152
```
5253

53-
If `PROACTIVE` is `"false"`, do not proactively suggest gstack skills — only invoke
54-
them when the user explicitly asks. The user opted out of proactive suggestions.
54+
If `PROACTIVE` is `"false"`, do not proactively suggest gstack skills AND do not
55+
auto-invoke skills based on conversation context. Only run skills the user explicitly
56+
types (e.g., /qa, /ship). If you would have auto-invoked a skill, instead briefly say:
57+
"I think /skillname might help here — want me to run it?" and wait for confirmation.
58+
The user opted out of proactive behavior.
5559

5660
If output shows `UPGRADE_AVAILABLE <old> <new>`: read `~/.claude/skills/gstack/gstack-upgrade/SKILL.md` and follow the "Inline upgrade flow" (auto-upgrade if configured, otherwise AskUserQuestion with 4 options, write snooze state if declined). If `JUST_UPGRADED <from> <to>`: tell user "Running gstack v{to} (just updated!)" and continue.
5761

@@ -100,6 +104,27 @@ touch ~/.gstack/.telemetry-prompted
100104

101105
This only happens once. If `TEL_PROMPTED` is `yes`, skip this entirely.
102106

107+
If `PROACTIVE_PROMPTED` is `no` AND `TEL_PROMPTED` is `yes`: After telemetry is handled,
108+
ask the user about proactive behavior. Use AskUserQuestion:
109+
110+
> gstack can proactively figure out when you might need a skill while you work —
111+
> like suggesting /qa when you say "does this work?" or /investigate when you hit
112+
> a bug. We recommend keeping this on — it speeds up every part of your workflow.
113+
114+
Options:
115+
- A) Keep it on (recommended)
116+
- B) Turn it off — I'll type /commands myself
117+
118+
If A: run `~/.claude/skills/gstack/bin/gstack-config set proactive true`
119+
If B: run `~/.claude/skills/gstack/bin/gstack-config set proactive false`
120+
121+
Always run:
122+
```bash
123+
touch ~/.gstack/.proactive-prompted
124+
```
125+
126+
This only happens once. If `PROACTIVE_PROMPTED` is `yes`, skip this entirely.
127+
103128
## Contributor Mode
104129

105130
If `_CONTRIB` is `true`: you are in **contributor mode**. At the end of each major workflow step, rate your gstack experience 0-10. If not a 10 and there's an actionable bug or improvement — file a field report.

0 commit comments

Comments
 (0)