claude-code-autoconfig 1.0.194 → 1.0.195
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -69,9 +69,14 @@ proceed, do BOTH of these as near-final actions so the tab flips to the AWAITING
|
|
|
69
69
|
(instead of the idle asterisk):
|
|
70
70
|
1. Write the flag file {{ASK_FILE}} (any short content, e.g. "1"). This is the RELIABLE trigger --
|
|
71
71
|
it is on disk before the turn ends, so it never misses (the transcript-text check in 2 can race
|
|
72
|
-
the turn-end write and silently miss). The flag is one-shot: it
|
|
73
|
-
auto-cleared next turn, so write it ONLY on a turn you are genuinely
|
|
74
|
-
|
|
72
|
+
the turn-end write and silently miss, or miss on phrasing -- see below). The flag is one-shot: it
|
|
73
|
+
is consumed at turn end and auto-cleared next turn, so write it ONLY on a turn you are genuinely
|
|
74
|
+
blocked on an answer. Write it WHENEVER the turn genuinely needs the user's answer to proceed --
|
|
75
|
+
the flag doesn't parse your text, so it is correct even when your closing question is wrapped in
|
|
76
|
+
parens, phrased as a parenthetical aside, or is not the literal final character of the message.
|
|
77
|
+
2. Phrase your FINAL line so it ends with a question mark ('?') -- a backup signal, and good UX. A
|
|
78
|
+
single trailing parenthetical aside after the '?' is fine ("...option A or B? (I lean B.)"), but
|
|
79
|
+
do not rely on phrasing for the signal -- the flag in step 1 is what reliably flips the tab.
|
|
75
80
|
Make the closing question self-contained: answerable from the question alone, without re-reading
|
|
76
81
|
the response above it. Only do this for a genuine blocking question, never a rhetorical one or a recap.
|
|
77
82
|
<!-- /DIRECTIVE:PENDING -->
|
|
@@ -177,7 +177,8 @@ function fileExists(file) {
|
|
|
177
177
|
|
|
178
178
|
// Stop heuristic: did the turn end on a question? Read the JSONL transcript, find the most-recent
|
|
179
179
|
// assistant message with VISIBLE text (skip pure tool_use turns so a final title/memory Write doesn't
|
|
180
|
-
// mask the question), test whether it ends in '?' (allowing trailing whitespace / ) * _ "
|
|
180
|
+
// mask the question), test whether it ends in '?' (allowing trailing whitespace / ) * _ ", plus one
|
|
181
|
+
// trailing parenthetical aside — see the endsOnQuestion regex below). Returns a
|
|
181
182
|
// diagnostic record { ends, found, tail }: `ends` is the old boolean the caller branches on; `found`
|
|
182
183
|
// and `tail` feed the debug log so a missing half-circle can be told apart — a transcript-flush race
|
|
183
184
|
// shows found=0 (or a stale tail), a genuine regex miss shows a tail that's present but doesn't end
|
|
@@ -216,7 +217,15 @@ function inspectLastResponse(transcriptPath) {
|
|
|
216
217
|
if (text.trim()) {
|
|
217
218
|
// last ~60 chars, collapsed to one line and quote-stripped so it can't break the log framing
|
|
218
219
|
const tail = text.trim().slice(-60).replace(/\s+/g, ' ').replace(/"/g, "'");
|
|
219
|
-
|
|
220
|
+
// Ends on a question? A '?' at the end, tolerating trailing whitespace / ) * _ " — AND an optional
|
|
221
|
+
// SINGLE trailing parenthetical aside after it ("How should we handle it? (I lean option 2.)"), a
|
|
222
|
+
// common shape: ask, then a bracketed recommendation/clarifier. The aside is one level only
|
|
223
|
+
// (`[^()]`, no nesting) and must sit at the very end, so a mid-message rhetorical '?' or a plain
|
|
224
|
+
// statement ending in ')' still won't match — only a genuine closing question does. Belt to the
|
|
225
|
+
// {sid}.ask flag's suspenders: the flag is the primary, parse-free path; this only hardens the
|
|
226
|
+
// fallback for turns that ended on a parenthetical question without writing one.
|
|
227
|
+
const endsOnQuestion = /\?[\s)*_"]*(\([^()]*\)[\s.*_"]*)?$/.test(text);
|
|
228
|
+
return { ends: endsOnQuestion, found: true, tail, suspectRace: sawTextlessAssistant };
|
|
220
229
|
}
|
|
221
230
|
// assistant message with no visible text = a thinking-only or tool_use-only block sitting AFTER the
|
|
222
231
|
// last text we'll grade — a strong hint the final text line hasn't flushed yet.
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## v1.0.195
|
|
4
|
+
- fix(terminal-title): flip awaiting ◐ for a closing question with a trailing parenthetical aside
|
|
5
|
+
|
|
3
6
|
## v1.0.194
|
|
4
7
|
- fix(terminal-title): guard the Stop question-grade against the transcript-flush race
|
|
5
8
|
|
|
@@ -144,9 +147,3 @@
|
|
|
144
147
|
## v1.0.146
|
|
145
148
|
- style: improve inside-Claude block message formatting
|
|
146
149
|
|
|
147
|
-
## v1.0.145
|
|
148
|
-
- fix: block npx install from inside Claude Code session
|
|
149
|
-
|
|
150
|
-
## v1.0.144
|
|
151
|
-
- feat: swagger-style docs, wider layout, better install UX
|
|
152
|
-
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "claude-code-autoconfig",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.195",
|
|
4
4
|
"description": "Intelligent, self-configuring setup for Claude Code. One command analyzes your project, configures Claude, and shows you what it did.",
|
|
5
5
|
"author": "ADAC 1001 <info@adac1001.com>",
|
|
6
6
|
"license": "MIT",
|