Skip to content

Commit 2b71b28

Browse files
committed
test: protect revision escalation semantics
1 parent 33f6a91 commit 2b71b28

4 files changed

Lines changed: 17 additions & 6 deletions

File tree

.claude/skills/thesis-control/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ The author decides whether to accept, partially accept, revise, or rollback. Do
129129

130130
## Revision Escalation Rule
131131

132-
Treat three unsuccessful attempts on the same edit contract as an operational escalation threshold, not as evidence that every task fails after three turns. Count an attempt when its drift decision is `revise` or `rollback`, or when the author rejects the result against the same contract. Clarifying discussion and unexecuted proposals do not count.
132+
Treat three unsuccessful attempts on the same edit contract as an operational escalation threshold, not as evidence that every task fails after three turns. Only count an attempt when its drift decision is `revise` or `rollback`, or when the author rejects the result against the same contract. Clarifying discussion and unexecuted proposals do not count.
133133

134134
After three unsuccessful attempts, stop. Do not apply a fourth prose patch.
135135

docs/product/lost-in-conversation-writing-control-design.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ If any of these occur during the bench run, the outcome should be recorded as a
127127

128128
### Revision Escalation
129129

130-
Three unsuccessful attempts against the same edit contract are an operational stop threshold, not a research claim that every task fails after three turns. An attempt counts when the author rejects the result or the drift decision is `revise` or `rollback`. At that point the workflow must not apply a fourth prose patch.
130+
Three unsuccessful attempts against the same edit contract are an operational stop threshold, not a research claim that every task fails after three turns. Only author rejection or a `revise` or `rollback` drift decision counts as an unsuccessful attempt; clarification and unexecuted proposals do not count. At that point the workflow must not apply a fourth prose patch.
131131

132132
The workflow may escalate earlier when claim drift, an evidence gap, an unclear spine, loss of the latest author-approved version, or version contamination is already visible. Before any further edit, it consolidates the valid requirements, compares them with the control packet and approved source, classifies the problem, and asks the author to approve the next action.
133133

plugins/academic-writing-toolkit/skills/thesis-control/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ The author decides whether to accept, partially accept, revise, or rollback. Do
129129

130130
## Revision Escalation Rule
131131

132-
Treat three unsuccessful attempts on the same edit contract as an operational escalation threshold, not as evidence that every task fails after three turns. Count an attempt when its drift decision is `revise` or `rollback`, or when the author rejects the result against the same contract. Clarifying discussion and unexecuted proposals do not count.
132+
Treat three unsuccessful attempts on the same edit contract as an operational escalation threshold, not as evidence that every task fails after three turns. Only count an attempt when its drift decision is `revise` or `rollback`, or when the author rejects the result against the same contract. Clarifying discussion and unexecuted proposals do not count.
133133

134134
After three unsuccessful attempts, stop. Do not apply a fourth prose patch.
135135

scripts/test.sh

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1089,13 +1089,23 @@ import sys
10891089
from pathlib import Path
10901090
10911091
text = Path(sys.argv[1]).read_text(encoding="utf-8")
1092-
required = (
1093-
"## Revision Escalation Rule",
1092+
start = text.index("## Revision Escalation Rule")
1093+
end = text.index("\n## Output Patterns", start)
1094+
section = text[start:end]
1095+
required_clauses = (
10941096
"same edit contract",
10951097
"three unsuccessful attempts",
10961098
"operational escalation threshold",
1099+
"Only count an attempt when its drift decision is `revise` or `rollback`, or when the author rejects the result against the same contract.",
1100+
"Clarifying discussion and unexecuted proposals do not count.",
10971101
"Do not apply a fourth prose patch",
10981102
"Escalate earlier",
1103+
"section spine cannot be stated consistently",
1104+
"requested claim lacks supporting evidence",
1105+
"claim, caveat, or scope boundary outside the contract",
1106+
"latest author-approved version cannot be identified",
1107+
"conflicting requirements indicate version contamination",
1108+
"spine card, evidence boundaries, current contract, and latest author-approved version",
10991109
"underspecified or conflicting intent",
11001110
"local execution failure",
11011111
"structural mismatch",
@@ -1105,8 +1115,9 @@ required = (
11051115
"local patch",
11061116
"section-level restructure",
11071117
"full reframing",
1118+
"Create a separate branch or manuscript version only when the approved scope requires structural work.",
11081119
)
1109-
missing = [phrase for phrase in required if phrase not in text]
1120+
missing = [phrase for phrase in required_clauses if phrase not in section]
11101121
if missing:
11111122
raise SystemExit("missing revision-escalation guidance: " + ", ".join(missing))
11121123
PY

0 commit comments

Comments
 (0)