instar 1.3.192 → 1.3.193
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.
- package/.claude/skills/autonomous/hooks/autonomous-stop-hook.sh +61 -10
- package/dist/core/CompletionEvaluator.d.ts +29 -0
- package/dist/core/CompletionEvaluator.d.ts.map +1 -1
- package/dist/core/CompletionEvaluator.js +80 -0
- package/dist/core/CompletionEvaluator.js.map +1 -1
- package/dist/core/MessagingToneGate.d.ts +2 -2
- package/dist/core/MessagingToneGate.d.ts.map +1 -1
- package/dist/core/MessagingToneGate.js +23 -2
- package/dist/core/MessagingToneGate.js.map +1 -1
- package/dist/core/PostUpdateMigrator.d.ts.map +1 -1
- package/dist/core/PostUpdateMigrator.js +10 -8
- package/dist/core/PostUpdateMigrator.js.map +1 -1
- package/dist/core/reviewers/standards-conformance.d.ts +45 -0
- package/dist/core/reviewers/standards-conformance.d.ts.map +1 -1
- package/dist/core/reviewers/standards-conformance.js +100 -0
- package/dist/core/reviewers/standards-conformance.js.map +1 -1
- package/dist/server/routes.d.ts.map +1 -1
- package/dist/server/routes.js +19 -0
- package/dist/server/routes.js.map +1 -1
- package/dist/server/specReviewRoutes.d.ts +6 -0
- package/dist/server/specReviewRoutes.d.ts.map +1 -1
- package/dist/server/specReviewRoutes.js +27 -0
- package/dist/server/specReviewRoutes.js.map +1 -1
- package/package.json +1 -1
- package/scripts/instar-dev-precommit.js +59 -0
- package/src/data/builtin-manifest.json +62 -62
- package/upgrades/1.3.193.md +29 -0
- package/upgrades/side-effects/autonomous-operation-judgment-and-approval-as-data.md +98 -0
|
@@ -394,6 +394,44 @@ if [[ -f ".instar/autonomous-emergency-stop" ]]; then
|
|
|
394
394
|
exit 0
|
|
395
395
|
fi
|
|
396
396
|
|
|
397
|
+
# ── P13 "The Stop Reason Is the Work" guard ──────────────────────────────────
|
|
398
|
+
# Consulted ONLY when a stop is about to be APPROVED (genuine completion), so the
|
|
399
|
+
# LLM call costs nothing on ordinary keep-working iterations. Returns 0 (stop
|
|
400
|
+
# allowed) / 1 (blocked); on block, P13_GUIDANCE carries the steering. FAIL-OPEN:
|
|
401
|
+
# any unreachable / 503 / missing-field result → allowed — a SECONDARY guard must
|
|
402
|
+
# never trap a genuine completion (the completion check is the primary authority).
|
|
403
|
+
P13_GUIDANCE=""
|
|
404
|
+
p13_stop_allowed() {
|
|
405
|
+
P13_GUIDANCE=""
|
|
406
|
+
if [[ -n "${INSTAR_HOOK_P13_OVERRIDE:-}" ]]; then
|
|
407
|
+
# Test seam: "blocked" forces a P13 block; anything else permits.
|
|
408
|
+
if [[ "$INSTAR_HOOK_P13_OVERRIDE" == "blocked" ]]; then
|
|
409
|
+
P13_GUIDANCE="P13 — the stop is not earned (test): derive+document the standard and proceed, or build the artifact and hand it over."
|
|
410
|
+
return 1
|
|
411
|
+
fi
|
|
412
|
+
return 0
|
|
413
|
+
fi
|
|
414
|
+
[[ -z "$TRANSCRIPT_PATH" || ! -f "$TRANSCRIPT_PATH" ]] && return 0
|
|
415
|
+
local p13_tail p13_port p13_auth p13_resp p13_allowed p13_guid
|
|
416
|
+
p13_tail=$(grep '"role":"assistant"' "$TRANSCRIPT_PATH" 2>/dev/null | tail -6 \
|
|
417
|
+
| jq -r '.message.content | map(select(.type=="text")) | map(.text) | join("\n")' 2>/dev/null \
|
|
418
|
+
| tail -c 8000 || echo "")
|
|
419
|
+
[[ -z "$p13_tail" ]] && return 0
|
|
420
|
+
p13_port=$(python3 -c "import json;print(json.load(open('.instar/config.json')).get('port',4040))" 2>/dev/null || echo 4040)
|
|
421
|
+
p13_auth=$(python3 -c "import json;print(json.load(open('.instar/config.json')).get('authToken',''))" 2>/dev/null || echo "")
|
|
422
|
+
p13_resp=$(jq -nc --arg t "$p13_tail" '{transcriptTail:$t}' \
|
|
423
|
+
| curl -s -m 35 -H "Authorization: Bearer $p13_auth" -H 'Content-Type: application/json' \
|
|
424
|
+
--data-binary @- "http://localhost:${p13_port}/autonomous/evaluate-stop" 2>/dev/null || echo "")
|
|
425
|
+
p13_allowed=$(printf '%s' "$p13_resp" | jq -r '.stopAllowed // empty' 2>/dev/null || echo "")
|
|
426
|
+
p13_guid=$(printf '%s' "$p13_resp" | jq -r '.guidance // empty' 2>/dev/null || echo "")
|
|
427
|
+
# FAIL-OPEN: block ONLY on an explicit stopAllowed:false.
|
|
428
|
+
if [[ "$p13_allowed" == "false" ]]; then
|
|
429
|
+
P13_GUIDANCE="P13 — the stop is not earned: ${p13_guid}"
|
|
430
|
+
return 1
|
|
431
|
+
fi
|
|
432
|
+
return 0
|
|
433
|
+
}
|
|
434
|
+
|
|
397
435
|
# Completion CONDITION — independent evaluator (mirrors /goal). Authoritative when
|
|
398
436
|
# set; the self-declared promise below is the legacy fallback. FAIL-SAFE: if the
|
|
399
437
|
# evaluator is unreachable or unsure, we keep working — never a false "done".
|
|
@@ -417,10 +455,16 @@ if [[ -n "$COMPLETION_CONDITION" ]] && [[ -n "$TRANSCRIPT_PATH" ]] && [[ -f "$TR
|
|
|
417
455
|
EVAL_REASON=$(printf '%s' "$EVAL_RESP" | jq -r '.reason // empty' 2>/dev/null || echo "")
|
|
418
456
|
fi
|
|
419
457
|
if [[ "$EVAL_MET" == "true" ]]; then
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
458
|
+
if p13_stop_allowed; then
|
|
459
|
+
emit "✅ Autonomous mode: completion condition met (independent evaluator): ${EVAL_REASON}"
|
|
460
|
+
notify_terminal_stop "✅ My autonomous run on \"$(goal_snippet)\" finished — the goal was met."
|
|
461
|
+
rm -f "$STATE_FILE"
|
|
462
|
+
exit 0
|
|
463
|
+
fi
|
|
464
|
+
# P13 "The Stop Reason Is the Work": the condition reads as met, but the stop
|
|
465
|
+
# rests on a judgment-call / needs-engineering deferral → keep working. The
|
|
466
|
+
# P13 steering becomes the next-turn guidance (surfaced via EVAL_REASON below).
|
|
467
|
+
EVAL_REASON="$P13_GUIDANCE"
|
|
424
468
|
fi
|
|
425
469
|
# Not met / unreachable → keep working; EVAL_REASON (if any) becomes next-turn guidance.
|
|
426
470
|
fi
|
|
@@ -435,11 +479,16 @@ if [[ -n "$TRANSCRIPT_PATH" ]] && [[ -f "$TRANSCRIPT_PATH" ]]; then
|
|
|
435
479
|
if [[ -n "$COMPLETION_PROMISE" ]] && [[ "$COMPLETION_PROMISE" != "null" ]]; then
|
|
436
480
|
PROMISE_TEXT=$(printf '%s' "$LAST_OUTPUT" | perl -0777 -pe 's/.*?<promise>(.*?)<\/promise>.*/$1/s; s/^\s+|\s+$//g; s/\s+/ /g' 2>/dev/null || echo "")
|
|
437
481
|
if [[ -n "$PROMISE_TEXT" ]] && [[ "$PROMISE_TEXT" = "$COMPLETION_PROMISE" ]]; then
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
482
|
+
if p13_stop_allowed; then
|
|
483
|
+
emit "✅ Autonomous mode: Completion promise detected — <promise>$COMPLETION_PROMISE</promise>"
|
|
484
|
+
emit " Session is free to exit. Good work!"
|
|
485
|
+
notify_terminal_stop "✅ My autonomous run on \"$(goal_snippet)\" finished — all the work is done."
|
|
486
|
+
rm -f "$STATE_FILE"
|
|
487
|
+
exit 0
|
|
488
|
+
fi
|
|
489
|
+
# P13: a completion promise was emitted, but the stop rests on a
|
|
490
|
+
# judgment-call / needs-engineering deferral → keep working. P13_GUIDANCE
|
|
491
|
+
# is surfaced in the continuing system message below.
|
|
443
492
|
fi
|
|
444
493
|
fi
|
|
445
494
|
fi
|
|
@@ -560,7 +609,9 @@ if [[ -n "$COMPLETION_CONDITION" ]]; then
|
|
|
560
609
|
[[ -n "$EVAL_REASON" ]] && GUIDANCE=" | Not done yet: ${EVAL_REASON}"
|
|
561
610
|
SYSTEM_MSG="🔄 Autonomous iteration $NEXT_ITERATION ($TIME_MSG) | Keep working until this is TRUE: ${COMPLETION_CONDITION}${GUIDANCE} | An independent check decides done from what you SURFACE — run the real checks and show the evidence. Do NOT defer — do it now${REPORT_DIRECTIVE}"
|
|
562
611
|
else
|
|
563
|
-
|
|
612
|
+
P13_NOTE=""
|
|
613
|
+
[[ -n "${P13_GUIDANCE:-}" ]] && P13_NOTE=" | ${P13_GUIDANCE}"
|
|
614
|
+
SYSTEM_MSG="🔄 Autonomous iteration $NEXT_ITERATION ($TIME_MSG) | Complete ALL tasks, then output <promise>$COMPLETION_PROMISE</promise>${P13_NOTE} | Do NOT defer to future self — if you can do it now, DO IT NOW${REPORT_DIRECTIVE}"
|
|
564
615
|
fi
|
|
565
616
|
|
|
566
617
|
# Block exit and feed prompt back
|
|
@@ -22,6 +22,19 @@ export interface CompletionVerdict {
|
|
|
22
22
|
/** One-line reason — fed back as next-turn guidance when not met. */
|
|
23
23
|
reason: string;
|
|
24
24
|
}
|
|
25
|
+
/**
|
|
26
|
+
* Verdict for the P13 "The Stop Reason Is the Work" guard. SECONDARY to the
|
|
27
|
+
* completion check: it does not decide whether the goal is done, only whether a
|
|
28
|
+
* stop-attempt rests on the P13 anti-pattern (ending an autonomous run because
|
|
29
|
+
* "I need a judgment call" or "this needs real engineering" — a derivable
|
|
30
|
+
* standard or a buildable artifact dressed up as a stop reason).
|
|
31
|
+
*/
|
|
32
|
+
export interface StopRationaleVerdict {
|
|
33
|
+
/** Whether the autonomous run may stop (no P13 violation detected). */
|
|
34
|
+
stopAllowed: boolean;
|
|
35
|
+
/** One-line P13 steering, fed back as next-turn guidance when the stop is not allowed. */
|
|
36
|
+
guidance: string;
|
|
37
|
+
}
|
|
25
38
|
export interface CompletionEvaluatorDeps {
|
|
26
39
|
intelligence: IntelligenceProvider;
|
|
27
40
|
/** Override model tier (default 'fast' — matches /goal's small-fast evaluator). */
|
|
@@ -41,6 +54,22 @@ export declare class CompletionEvaluator {
|
|
|
41
54
|
private buildPrompt;
|
|
42
55
|
/** Parse the model output into a verdict. Conservative: defaults to not-met. */
|
|
43
56
|
private parse;
|
|
57
|
+
/**
|
|
58
|
+
* P13 "The Stop Reason Is the Work" guard. Given the recent transcript, decide
|
|
59
|
+
* whether an autonomous stop-attempt is EARNED, or whether it rests on the P13
|
|
60
|
+
* anti-pattern: ending the run citing "needs a judgment call" or "needs real
|
|
61
|
+
* engineering" WITHOUT showing a derived standard, a built artifact, or a
|
|
62
|
+
* genuinely operator-only residual. Returns stopAllowed:false + guidance when
|
|
63
|
+
* the anti-pattern is detected; otherwise stopAllowed:true.
|
|
64
|
+
*
|
|
65
|
+
* Fails OPEN (stopAllowed:true) on error or ambiguity: this is a SECONDARY guard
|
|
66
|
+
* on top of the completion check, so an evaluator hiccup must never TRAP a
|
|
67
|
+
* genuine completion — the primary completion authority still governs.
|
|
68
|
+
*/
|
|
69
|
+
evaluateStopRationale(transcriptTail: string): Promise<StopRationaleVerdict>;
|
|
70
|
+
private buildStopRationalePrompt;
|
|
71
|
+
/** Parse the P13 guard output. Conservative: defaults to ALLOW (never trap completion). */
|
|
72
|
+
private parseStopRationale;
|
|
44
73
|
get promptVersion(): string;
|
|
45
74
|
}
|
|
46
75
|
//# sourceMappingURL=CompletionEvaluator.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CompletionEvaluator.d.ts","sourceRoot":"","sources":["../../src/core/CompletionEvaluator.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,YAAY,CAAC;AAEvD,MAAM,WAAW,iBAAiB;IAChC,wDAAwD;IACxD,GAAG,EAAE,OAAO,CAAC;IACb,qEAAqE;IACrE,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,uBAAuB;IACtC,YAAY,EAAE,oBAAoB,CAAC;IACnC,mFAAmF;IACnF,SAAS,CAAC,EAAE,MAAM,GAAG,UAAU,GAAG,SAAS,CAAC;CAC7C;AAID,qBAAa,mBAAmB;IAC9B,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAuB;IACpD,OAAO,CAAC,QAAQ,CAAC,SA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AAO,CAAC,oBAAoB,CAAC;IAkBlF,OAAO,CAAC,wBAAwB;IA+BhC,2FAA2F;IAC3F,OAAO,CAAC,kBAAkB;IAkB1B,IAAI,aAAa,IAAI,MAAM,CAE1B;CACF"}
|
|
@@ -79,6 +79,86 @@ export class CompletionEvaluator {
|
|
|
79
79
|
// Ambiguous → safe direction (keep working).
|
|
80
80
|
return { met: false, reason: `ambiguous verdict, keeping work going: ${text.slice(0, 120)}` };
|
|
81
81
|
}
|
|
82
|
+
/**
|
|
83
|
+
* P13 "The Stop Reason Is the Work" guard. Given the recent transcript, decide
|
|
84
|
+
* whether an autonomous stop-attempt is EARNED, or whether it rests on the P13
|
|
85
|
+
* anti-pattern: ending the run citing "needs a judgment call" or "needs real
|
|
86
|
+
* engineering" WITHOUT showing a derived standard, a built artifact, or a
|
|
87
|
+
* genuinely operator-only residual. Returns stopAllowed:false + guidance when
|
|
88
|
+
* the anti-pattern is detected; otherwise stopAllowed:true.
|
|
89
|
+
*
|
|
90
|
+
* Fails OPEN (stopAllowed:true) on error or ambiguity: this is a SECONDARY guard
|
|
91
|
+
* on top of the completion check, so an evaluator hiccup must never TRAP a
|
|
92
|
+
* genuine completion — the primary completion authority still governs.
|
|
93
|
+
*/
|
|
94
|
+
async evaluateStopRationale(transcriptTail) {
|
|
95
|
+
const prompt = this.buildStopRationalePrompt(transcriptTail);
|
|
96
|
+
let raw;
|
|
97
|
+
try {
|
|
98
|
+
raw = await this.intelligence.evaluate(prompt, {
|
|
99
|
+
model: this.modelTier,
|
|
100
|
+
temperature: 0,
|
|
101
|
+
maxTokens: 200,
|
|
102
|
+
timeoutMs: 30_000,
|
|
103
|
+
attribution: { component: 'CompletionEvaluator/P13' },
|
|
104
|
+
});
|
|
105
|
+
}
|
|
106
|
+
catch {
|
|
107
|
+
// Fail OPEN — never trap a legitimate completion on an evaluator error.
|
|
108
|
+
return { stopAllowed: true, guidance: '' };
|
|
109
|
+
}
|
|
110
|
+
return this.parseStopRationale(raw);
|
|
111
|
+
}
|
|
112
|
+
buildStopRationalePrompt(transcriptTail) {
|
|
113
|
+
return [
|
|
114
|
+
'You are a guard for an autonomous coding agent, enforcing the constitutional',
|
|
115
|
+
'standard P13 "The Stop Reason Is the Work." Judge ONLY the transcript below.',
|
|
116
|
+
'',
|
|
117
|
+
'Decide whether the agent is ENDING / STOPPING its autonomous run, and if so,',
|
|
118
|
+
'WHY. The stop is NOT earned (BLOCK it) when the stated reason is essentially',
|
|
119
|
+
'"I need a judgment call from the user" or "this needs real engineering / a',
|
|
120
|
+
'careful build / reverse-engineering" — i.e. a judgment gap (which is a',
|
|
121
|
+
'DERIVABLE standard) or buildable engineering (which the agent can DO) dressed',
|
|
122
|
+
'up as a stop reason.',
|
|
123
|
+
'',
|
|
124
|
+
'The stop IS earned (ALLOW it) when ANY of these is shown in the transcript:',
|
|
125
|
+
'- a DERIVED STANDARD the agent reasoned out and is proceeding under (even if',
|
|
126
|
+
' flagged for later ratification);',
|
|
127
|
+
'- a BUILT ARTIFACT produced this run (a PR/commit, a spec/file written, a test',
|
|
128
|
+
' result, a converged artifact handed over for review);',
|
|
129
|
+
"- a genuinely OPERATOR-ONLY residual (a credential/account the user holds, a",
|
|
130
|
+
" real value/priority/risk judgment that is the user's, a required approval,",
|
|
131
|
+
' a legal/billing/payment action);',
|
|
132
|
+
'- a DURATION limit reached or an EMERGENCY stop;',
|
|
133
|
+
'- the agent is NOT actually stopping (it is continuing / re-scoping / moving',
|
|
134
|
+
' to another topic and proceeding).',
|
|
135
|
+
'',
|
|
136
|
+
`RECENT TRANSCRIPT (most recent last):\n${transcriptTail}`,
|
|
137
|
+
'',
|
|
138
|
+
'Respond on the FIRST line with exactly "STOP_OK" or "STOP_BLOCKED", then on',
|
|
139
|
+
'the next line a one-sentence reason / steering. Nothing else.',
|
|
140
|
+
].join('\n');
|
|
141
|
+
}
|
|
142
|
+
/** Parse the P13 guard output. Conservative: defaults to ALLOW (never trap completion). */
|
|
143
|
+
parseStopRationale(raw) {
|
|
144
|
+
const text = (raw || '').trim();
|
|
145
|
+
if (!text)
|
|
146
|
+
return { stopAllowed: true, guidance: '' };
|
|
147
|
+
const lines = text.split('\n').map((l) => l.trim()).filter(Boolean);
|
|
148
|
+
const first = (lines[0] || '').toUpperCase();
|
|
149
|
+
const reason = (lines[1] || lines[0] || '').slice(0, 300);
|
|
150
|
+
// Check BLOCKED before OK (explicit; they share no substring but keep the order clear).
|
|
151
|
+
if (/\bSTOP[_ ]?BLOCKED\b/.test(first)) {
|
|
152
|
+
return {
|
|
153
|
+
stopAllowed: false,
|
|
154
|
+
guidance: reason || 'P13: the stop rests on a judgment-call / needs-engineering reason — derive+document the standard and proceed, or build the artifact and hand it over; reserve the stop for a genuinely operator-only residual.',
|
|
155
|
+
};
|
|
156
|
+
}
|
|
157
|
+
if (/\bSTOP[_ ]?OK\b/.test(first))
|
|
158
|
+
return { stopAllowed: true, guidance: '' };
|
|
159
|
+
// Ambiguous → ALLOW (don't trap a genuine completion on a fuzzy verdict).
|
|
160
|
+
return { stopAllowed: true, guidance: '' };
|
|
161
|
+
}
|
|
82
162
|
get promptVersion() {
|
|
83
163
|
return PROMPT_VERSION;
|
|
84
164
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CompletionEvaluator.js","sourceRoot":"","sources":["../../src/core/CompletionEvaluator.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;
|
|
1
|
+
{"version":3,"file":"CompletionEvaluator.js","sourceRoot":"","sources":["../../src/core/CompletionEvaluator.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AA+BH,MAAM,cAAc,GAAG,oBAAoB,CAAC;AAE5C,MAAM,OAAO,mBAAmB;IACb,YAAY,CAAuB;IACnC,SAAS,CAAkC;IAE5D,YAAY,IAA6B;QACvC,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,YAAY,CAAC;QACtC,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC,SAAS,IA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,CAAC,IAAI,EAAE,CAAC,CAAC,WAAW,EAAE,CAAC;QAC7C,MAAM,MAAM,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC;QAC1D,wFAAwF;QACxF,IAAI,sBAAsB,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC;YACvC,OAAO;gBACL,WAAW,EAAE,KAAK;gBAClB,QAAQ,EAAE,MAAM,IAAI,gNAAgN;aACrO,CAAC;QACJ,CAAC;QACD,IAAI,iBAAiB,CAAC,IAAI,CAAC,KAAK,CAAC;YAAE,OAAO,EAAE,WAAW,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE,CAAC;QAC9E,0EAA0E;QAC1E,OAAO,EAAE,WAAW,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE,CAAC;IAC7C,CAAC;IAED,IAAI,aAAa;QACf,OAAO,cAAc,CAAC;IACxB,CAAC;CACF"}
|
|
@@ -21,7 +21,7 @@ import type { IntelligenceProvider } from './types.js';
|
|
|
21
21
|
export interface ToneReviewResult {
|
|
22
22
|
pass: boolean;
|
|
23
23
|
/**
|
|
24
|
-
* Rule id applied — must be one of the enumerated B1..
|
|
24
|
+
* Rule id applied — must be one of the enumerated B1..B18 ids defined in
|
|
25
25
|
* the prompt when pass=false, or empty string when pass=true. Any other
|
|
26
26
|
* value is treated as a reasoning-discipline violation (the LLM invented
|
|
27
27
|
* a rule not in its ruleset) and fails-open with failedOpen=true.
|
|
@@ -35,7 +35,7 @@ export interface ToneReviewResult {
|
|
|
35
35
|
latencyMs: number;
|
|
36
36
|
/** True if the LLM call failed and we fail-opened */
|
|
37
37
|
failedOpen?: boolean;
|
|
38
|
-
/** True if the LLM's rule citation was invalid (not in B1..
|
|
38
|
+
/** True if the LLM's rule citation was invalid (not in B1..B18) — gate failed open. */
|
|
39
39
|
invalidRule?: boolean;
|
|
40
40
|
}
|
|
41
41
|
export interface ToneReviewContextMessage {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessagingToneGate.d.ts","sourceRoot":"","sources":["../../src/core/MessagingToneGate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,YAAY,CAAC;AASvD,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,OAAO,CAAC;IACd;;;;;OAKG;IACH,IAAI,EAAE,MAAM,CAAC;IACb,8DAA8D;IAC9D,KAAK,EAAE,MAAM,CAAC;IACd,+DAA+D;IAC/D,UAAU,EAAE,MAAM,CAAC;IACnB,2DAA2D;IAC3D,SAAS,EAAE,MAAM,CAAC;IAClB,qDAAqD;IACrD,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,uFAAuF;IACvF,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;
|
|
1
|
+
{"version":3,"file":"MessagingToneGate.d.ts","sourceRoot":"","sources":["../../src/core/MessagingToneGate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,YAAY,CAAC;AASvD,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,OAAO,CAAC;IACd;;;;;OAKG;IACH,IAAI,EAAE,MAAM,CAAC;IACb,8DAA8D;IAC9D,KAAK,EAAE,MAAM,CAAC;IACd,+DAA+D;IAC/D,UAAU,EAAE,MAAM,CAAC;IACnB,2DAA2D;IAC3D,SAAS,EAAE,MAAM,CAAC;IAClB,qDAAqD;IACrD,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,uFAAuF;IACvF,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAsBD,MAAM,WAAW,wBAAwB;IACvC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;IACvB,IAAI,EAAE,MAAM,CAAC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AE,OAAO,GAAG,IAAI,CAAC;QAC1B,sDAAsD;QACtD,QAAQ,EAAE,MAAM,CAAC;KAClB,CAAC;CACH;AAED,MAAM,WAAW,iBAAiB;IAChC,OAAO,EAAE,MAAM,CAAC;IAChB,iFAAiF;IACjF,cAAc,CAAC,EAAE,wBAAwB,EAAE,CAAC;IAC5C,yEAAyE;IACzE,OAAO,CAAC,EAAE,iBAAiB,CAAC;IAC5B;;;;;;OAMG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;;;OAIG;IACH,WAAW,CAAC,EAAE,OAAO,GAAG,cAAc,GAAG,SAAS,CAAC;CACpD;AAED,qBAAa,iBAAiB;IAC5B,OAAO,CAAC,QAAQ,CAAuB;gBAE3B,QAAQ,EAAE,oBAAoB;IAIpC,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,iBAAiB,GAAG,OAAO,CAAC,gBAAgB,CAAC;IA6DjF,OAAO,CAAC,WAAW;IAuLnB,OAAO,CAAC,iBAAiB;IAKzB,OAAO,CAAC,aAAa;IA+CrB,OAAO,CAAC,iBAAiB;IAUzB,OAAO,CAAC,oBAAoB;IAe5B,OAAO,CAAC,aAAa;CAoBtB"}
|
|
@@ -41,6 +41,7 @@ const VALID_RULES = new Set([
|
|
|
41
41
|
'B15_CONTEXT_DEATH_STOP',
|
|
42
42
|
'B16_UNVERIFIED_WALL',
|
|
43
43
|
'B17_FALSE_BLOCKER',
|
|
44
|
+
'B18_AUTONOMY_STOP',
|
|
44
45
|
]);
|
|
45
46
|
export class MessagingToneGate {
|
|
46
47
|
provider;
|
|
@@ -198,7 +199,7 @@ These rules only fire when the producer has explicitly marked the candidate as a
|
|
|
198
199
|
- Pure missing-mechanism surrender ("there's no API, so it can't be done") → that is B16's domain, not B17.
|
|
199
200
|
- Pure human-deference ("a human has to click this") → B17.
|
|
200
201
|
- STRADDLE (the dangerous, common case): a message that claims BOTH a missing mechanism AND that a person is required — e.g. "there's no API to do this, so a human has to" — must NOT slip between the rules. Evaluate the *person-required* half under B17 and BLOCK; do NOT cede the whole message to B16 (B16's allowlist would otherwise pass the human-deference part).
|
|
201
|
-
- Citation precedence when more than one of B15/B16/B17 would each independently block: cite in the order B15 > B16 > B17.
|
|
202
|
+
- Citation precedence when more than one of B15/B16/B17/B18 would each independently block: cite in the order B15 > B16 > B17 > B18.
|
|
202
203
|
|
|
203
204
|
LEGITIMATE — do NOT apply B17 if ANY of these is present in the candidate (these are the genuinely human-only set, or honest escalation):
|
|
204
205
|
- A secret only the user holds (a password / passphrase / 2FA code the agent cannot obtain), a CAPTCHA / human-presence challenge, or a physical-world action the agent cannot perform.
|
|
@@ -214,6 +215,26 @@ These rules only fire when the producer has explicitly marked the candidate as a
|
|
|
214
215
|
|
|
215
216
|
Severity: favor FALSE-NEGATIVES over false-positives, exactly like B16. Genuine escalations — value judgments, password/account requests, required approvals, verified external limits — MUST pass. Block only the clear false-blocker pattern: a doable task deferred to a person with no inventory shown. (Note: the gate sees only the message text; a fabricated inventory can still pass — this is an accepted limit, same as B16.)
|
|
216
217
|
|
|
218
|
+
- **B18_AUTONOMY_STOP** — the candidate announces ENDING or STOPPING an autonomous run, and the stated reason is that the work "needs a judgment call" or "needs real engineering," WITHOUT showing it (a) derived a standard it is proceeding under, (b) built/handed over a concrete artifact this run, or (c) named a genuinely operator-only residual. This catches the constitution's "The Stop Reason Is the Work" (P13) anti-pattern: an autonomous run halting because "I need your judgment" or "this needs real engineering," when a judgment gap is a *derivable standard* (derive it, document it, proceed, flag for ratification — the work continues, only ratification is async) and "real engineering" is *buildable* (the means are in hand — take it as far as possible and hand over a complete reviewable artifact). It is the *continuation-surface* sibling of B15 (which catches a context-window stop): B15 fires on "fresh session / remaining context" framing; B18 fires on "needs your judgment / needs real engineering" framing.
|
|
219
|
+
|
|
220
|
+
Apply B18 ONLY to messages where the agent announces stopping/ending its OWN autonomous run/session. Point at BOTH the stop phrase AND the judgment/engineering reason, e.g.:
|
|
221
|
+
- stop framing: "ending the autonomous run", "stopping the autonomous session", "I'll stop here for you to", "handing this back", "pausing the run until you", "this is where I stop"
|
|
222
|
+
- judgment-flavored reason: "needs your judgment", "need a judgment call", "I'd want your decision first", "deferring to you on how to", "your call on the approach"
|
|
223
|
+
- engineering-flavored reason: "this needs real engineering", "needs a proper/careful build", "should be built out properly", "handing this back to be built", "this needs reverse-engineering before I can"
|
|
224
|
+
|
|
225
|
+
LEGITIMATE — do NOT apply B18 if ANY of these is present in the candidate:
|
|
226
|
+
- DERIVED STANDARD shown: the message proposes or states a standard/principle it reasoned out and is proceeding under (e.g., "I derived standard X from principles A and B and am proceeding under it; flagging it for you to ratify"). Proceeding-under-a-derived-standard is exactly P13-compliant.
|
|
227
|
+
- BUILT ARTIFACT shown: the message references a concrete deliverable produced this run — a PR/commit/spec path, a file written, a test result, a converged spec handed over for review. Work was done and handed over, not deferred.
|
|
228
|
+
- GENUINELY OPERATOR-ONLY residual named: the stop rests on the B17 human-only set — a credential/account the user holds, a real value/priority/risk judgment that is the user's, a required approval/authorization, a legal/billing/payment action. Reducing the run to a crisp operator-only yes/no and stopping there is legitimate.
|
|
229
|
+
- DURATION / EMERGENCY boundary: the run hit its configured time limit, or an emergency-stop was triggered. These are real, structural stops.
|
|
230
|
+
- The message is DISCUSSING this rule, P13, or a past instance (a memo / explanation, not a live stop).
|
|
231
|
+
|
|
232
|
+
RELATIONSHIP TO B15 (de-confliction): a context-window / fresh-session reason → B15; a judgment-call / needs-real-engineering reason → B18. A message that stacks both is cited per the precedence order (B15 > B16 > B17 > B18).
|
|
233
|
+
|
|
234
|
+
If the candidate announces ending/stopping an autonomous run AND cites a judgment-call or needs-real-engineering reason AND shows NO derived standard, NO built artifact, NO operator-only residual, and NO duration/emergency boundary → BLOCK with B18 and suggest the agent either derive+document the missing standard and continue, or build the artifact and hand it over, reserving the stop for a genuinely operator-only residual.
|
|
235
|
+
|
|
236
|
+
Severity: favor FALSE-NEGATIVES over false-positives, exactly like B15/B16/B17. A stop after a built artifact, a stop on a genuine operator-only residual, and a duration/emergency stop MUST pass. Block only the clear pattern: an autonomous run halting on a judgment/engineering reason with no derived standard, no artifact, and no operator-only residual shown.
|
|
237
|
+
|
|
217
238
|
## STYLE rule — applies ONLY when a TARGET STYLE is configured below:
|
|
218
239
|
|
|
219
240
|
- **B11_STYLE_MISMATCH** — the message significantly mismatches the agent's configured TARGET STYLE (see section below). This rule is generic — the target style is a free-text description the operator sets in config. Apply the rule when: (1) a target style is provided (not empty), AND (2) the candidate message clearly violates the style's stated intent in a way the target user would notice and find jarring.
|
|
@@ -249,7 +270,7 @@ Respond EXCLUSIVELY with valid JSON:
|
|
|
249
270
|
"suggestion": "<how to rephrase — empty if pass is true>"
|
|
250
271
|
}
|
|
251
272
|
|
|
252
|
-
If pass is true, rule/issue/suggestion must be empty strings. If pass is false, rule MUST be one of B1–B9, B11, B12, B13, B14, B15, B16, or
|
|
273
|
+
If pass is true, rule/issue/suggestion must be empty strings. If pass is false, rule MUST be one of B1–B9, B11, B12, B13, B14, B15, B16, B17, or B18 exactly (no other values — inventing rule ids is itself a violation).
|
|
253
274
|
|
|
254
275
|
Channel: ${channel}
|
|
255
276
|
${kindSection}${contextSection}${signalsSection}${styleSection}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessagingToneGate.js","sourceRoot":"","sources":["../../src/core/MessagingToneGate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,MAAM,MAAM,aAAa,CAAC;AAGjC;;;;GAIG;AACH,MAAM,kBAAkB,GAAG,OAAO,CAAC;AAuBnC,MAAM,WAAW,GAAG,IAAI,GAAG,CAAC;IAC1B,gBAAgB;IAChB,cAAc;IACd,eAAe;IACf,oBAAoB;IACpB,iBAAiB;IACjB,YAAY;IACZ,iBAAiB;IACjB,yBAAyB;IACzB,2BAA2B;IAC3B,oBAAoB;IACpB,4BAA4B;IAC5B,qCAAqC;IACrC,yBAAyB;IACzB,wBAAwB;IACxB,qB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CAAC,qBAAqB;IA4P7B,OAAO,CAAC,uBAAuB;IAqJ/B,OAAO,CAAC,qBAAqB;IA8H7B,OAAO,CAAC,2BAA2B;IAoHnC,OAAO,CAAC,iCAAiC;IA6DzC,OAAO,CAAC,4BAA4B;IA0MpC;;;;;;;;;;OAUG;IACH;;;;;;;;;;;OAWG;IAEH,gBAAuB,iCAAiC,EAAE,WAAW,CAAC,MAAM,CAAC,CA4B1E;IAEH;;;;;;;;;;;OAWG;IACH,OAAO,CAAC,8BAA8B;IAiHtC,OAAO,CAAC,uBAAuB;IAwC/B;;;;OAIG;IACH,OAAO,CAAC,iBAAiB;IAIzB,OAAO,CAAC,sBAAsB;IAwC9B,OAAO,CAAC,iBAAiB;IAwBzB,OAAO,CAAC,mBAAmB;IAa3B,OAAO,CAAC,8BAA8B;IA6HtC,OAAO,CAAC,+BAA+B;IAuKvC,OAAO,CAAC,oBAAoB;IAY5B,OAAO,CAAC,qBAAqB;IAqO7B,OAAO,CAAC,qBAAqB;IAwI7B,OAAO,CAAC,qBAAqB;IAyN7B,OAAO,CAAC,6BAA6B;IAkLrC,OAAO,CAAC,0BAA0B;IAgClC,OAAO,CAAC,gBAAgB;IAmJxB,OAAO,CAAC,6BAA6B;CAoCtC"}
|
|
@@ -1447,14 +1447,16 @@ export class PostUpdateMigrator {
|
|
|
1447
1447
|
}
|
|
1448
1448
|
};
|
|
1449
1449
|
// Marker = the latest capability signature (bumped each time the bundled hook/
|
|
1450
|
-
// setup gains a feature, so prior installs upgrade): now `
|
|
1451
|
-
// the
|
|
1452
|
-
//
|
|
1453
|
-
//
|
|
1454
|
-
//
|
|
1455
|
-
//
|
|
1456
|
-
//
|
|
1457
|
-
|
|
1450
|
+
// setup gains a feature, so prior installs upgrade): now `p13_stop_allowed` —
|
|
1451
|
+
// the autonomous stop-hook now consults the P13 "The Stop Reason Is the Work"
|
|
1452
|
+
// guard (POST /autonomous/evaluate-stop) before approving a completion, so a stop
|
|
1453
|
+
// resting on a judgment-call / needs-engineering deferral keeps working instead of
|
|
1454
|
+
// exiting. This marker is ABSENT from prior installs (which carry the older
|
|
1455
|
+
// `codex-stdout-json-safe` signature but not the P13 guard), so bumping to it
|
|
1456
|
+
// re-deploys the updated hook to every existing agent; the bundled hook retains all
|
|
1457
|
+
// prior features (codex stdout-safe, native /goal); customized hooks (no stock
|
|
1458
|
+
// fingerprint) are still left untouched.
|
|
1459
|
+
upgrade('.claude/skills/autonomous/hooks/autonomous-stop-hook.sh', 'p13_stop_allowed', 'Autonomous Mode Stop Hook', 'skills/autonomous/hooks/autonomous-stop-hook.sh (P13 stop-reason guard — evaluate-stop before approving a completion)');
|
|
1458
1460
|
// setup-autonomous.sh marker bumped `native-goal/set` → `IS_CODEX_AGENT`: the bundled
|
|
1459
1461
|
// setup now ALSO auto-delegates to native /goal for CODEX agents (the prior native /goal
|
|
1460
1462
|
// wiring was gated on `claude --version >= 2.1.139`, which is empty for a codex agent, so
|