Skip to content

cat-mode: show the escape-hatch tag in the form the gate accepts - #786

Merged
mergify[bot] merged 5 commits into
mainfrom
stack/EdbertChan/reflect/subagent-decisions-slot-20260922/cat-mode-show-escape-hatch-tag-form-gate-accepts--f47021e8
Sep 24, 2026
Merged

mergify[bot] merged 5 commits into
mainfrom
stack/EdbertChan/reflect/subagent-decisions-slot-20260922/cat-mode-show-escape-hatch-tag-form-gate-accepts--f47021e8

Conversation

@EdbertChan

@EdbertChan EdbertChan commented Sep 22, 2026 •

Copy link
Copy Markdown
Owner

Summary

The conventions file shows the escape-hatch tag in a bare form the gate rejects.

Anyone quoting that line verbatim, which the same file tells them to do when relaying a blocked message, trips the gate.

This puts the full template in that line, matching how the core rules file already writes it.

Review Claim

The conventions file shows the tag in the form the gate accepts.

Review Lane

behavior

Review Unit

corpus-lesson

Safety Invariant

Only the example text changes. The gate's own rules are untouched, so nothing that used to block stops blocking.

Slice Rationale

A one-line documentation fix with a test that pins it. Kept out of the gate change so a prose edit never rides along with behaviour.

Non-goals

Does not change the tag format itself or any gate logic.

Test Plan

Test Plan

Run at this commit:

python3 tests/test_cat_mode.py
Ran 87 tests in 0.048s
OK

The added case asserts every tag example in the conventions file is one the gate accepts.

Revert Plan

Revert Plan

Revert this commit. The example returns to the bare form and quoting it trips the gate again.


Note

Low Risk
Documentation and regression tests only; marker validation behavior is untouched.

Overview
cat-mode showed the escape-hatch as bare {{CAT-UNVERIFIED}} in the rule that tells readers to use that tag when they cannot prove a live-behavior claim. Quoting that line verbatim tripped the same gate the tag is meant to satisfy.

The one-line rule in SKILL.md and the fuller copy in references/verify.md now use the full template {{CAT-UNVERIFIED: <claim> -- cannot verify: <reason>}}, aligned with engine/CLAUDE.core.md. Gate logic is unchanged.

tests/test_cat_mode.py adds TestEscapeHatchTemplateIsWellFormed: it scans SKILL.md and every references/*.md via engine/hooks/_markers/markers.py so malformed tag examples cannot slip back in via verify.md alone.

Reviewed by Cursor Bugbot for commit 2e69d29. Bugbot is set up for automated code reviews on this repo. Configure here.

@EdbertChan

EdbertChan commented Sep 22, 2026 •

Copy link
Copy Markdown
Owner Author

This pull request is part of a Mergify stack:

# Pull Request Link
1 wrong-check-reflect: one shot per reply, and scope the reflect scan to the turn #796
2 reflect: catch an evidence-order correction from the ledger transition, not from wording #782
3 unverified-tag-ledger: gate the next-prompt reminder, default to stale only #783
4 diu-stop: a file citation buys silence only when it is backed #784
5 diu-stop: the marker gate reads prose, so a mention is not a use #785
6 cat-mode: show the escape-hatch tag in the form the gate accepts #786 👈
7 principle-subagent-inherits-scope: a brief carries decisions, not just facts and a question #788
8 llm-judge: claude is the only default runner #793

@EdbertChan
EdbertChan force-pushed the stack/EdbertChan/reflect/subagent-decisions-slot-20260922/cat-mode-show-escape-hatch-tag-form-gate-accepts--f47021e8 branch from 0201bdc to fab6704 Compare September 22, 2026 18:38
@EdbertChan
EdbertChan force-pushed the stack/EdbertChan/reflect/subagent-decisions-slot-20260922/diu-stop-marker-gate-reads-prose-mention-use--8d19b383 branch from a993989 to a0e5d05 Compare September 22, 2026 18:38
@EdbertChan

EdbertChan commented Sep 22, 2026 •

Copy link
Copy Markdown
Owner Author

Revision history

# Type Changes Reason Date
1 initial 0201bdc 2026-09-22 18:38 UTC
2 rebase 0201bdc → fab6704 (rebase only) 2026-09-22 18:38 UTC
3 rebase fab6704 → 1937775 (rebase only) 2026-09-23 14:06 UTC

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit fab6704. Configure here.

Comment thread tests/test_cat_mode.py Outdated
@EdbertChan
EdbertChan force-pushed the stack/EdbertChan/reflect/subagent-decisions-slot-20260922/diu-stop-marker-gate-reads-prose-mention-use--8d19b383 branch from a0e5d05 to 950a355 Compare September 23, 2026 14:06
@EdbertChan
EdbertChan force-pushed the stack/EdbertChan/reflect/subagent-decisions-slot-20260922/cat-mode-show-escape-hatch-tag-form-gate-accepts--f47021e8 branch from fab6704 to 1937775 Compare September 23, 2026 14:06
@EdbertChan

Copy link
Copy Markdown
Owner Author

Mergify repair stopped: lowest open stack PR #786 is based on stack/EdbertChan/reflect/subagent-decisions-slot-20260922/diu-stop-marker-gate-reads-prose-mention-use--8d19b383, which still belongs to open PR(s) #785 outside this stack; leaving it alone to avoid dropping dependency changes

@EdbertChan
EdbertChan force-pushed the stack/EdbertChan/reflect/subagent-decisions-slot-20260922/diu-stop-marker-gate-reads-prose-mention-use--8d19b383 branch from 950a355 to b0e1eea Compare September 24, 2026 08:29
@EdbertChan
EdbertChan force-pushed the stack/EdbertChan/reflect/subagent-decisions-slot-20260922/cat-mode-show-escape-hatch-tag-form-gate-accepts--f47021e8 branch from 3ed5352 to 1fb69a0 Compare September 24, 2026 08:29
@cursor

cursor Bot commented Sep 24, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_ea2da72e-fd47-43db-b44d-ed1a0d1ab13b)

@EdbertChan
EdbertChan force-pushed the stack/EdbertChan/reflect/subagent-decisions-slot-20260922/cat-mode-show-escape-hatch-tag-form-gate-accepts--f47021e8 branch from 1fb69a0 to a8e7f75 Compare September 24, 2026 10:05
@EdbertChan
EdbertChan force-pushed the stack/EdbertChan/reflect/subagent-decisions-slot-20260922/diu-stop-marker-gate-reads-prose-mention-use--8d19b383 branch from b0e1eea to 51ed95a Compare September 24, 2026 10:05
@cursor

cursor Bot commented Sep 24, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_dbe02907-5745-4823-8fe1-3b306668f806)

@EdbertChan
EdbertChan changed the base branch from stack/EdbertChan/reflect/subagent-decisions-slot-20260922/diu-stop-marker-gate-reads-prose-mention-use--8d19b383 to main September 24, 2026 10:40
@mergify

mergify Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Queued — the merge queue status continues in this comment ↓.

The sentence that tells the reader to use the tag showed it as a bare token
naming no blocker. That is the shape diu-stop rejects, so quoting cat-mode's
own rule tripped the gate enforcing it. It now shows the same template
engine/CLAUDE.core.md already uses.

tests/test_cat_mode.py gains the structural catch: no tag anywhere in the
skill may name no blocker, and the skill must still show the tag at all, so
the fix cannot be "delete the example".

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Change-Id: If47021e83bdf3d8771ccbdb879001f6effc65a3c
CI Bot and others added 4 commits September 24, 2026 19:08
The bare `{{CAT-UNVERIFIED}}` was fixed in SKILL.md, but the same sentence
lives twice on purpose: SKILL.md keeps the one-line form and references/
verify.md holds the full text the evidence gate leans on. verify.md still
showed the tag naming no blocker, so a reader sent to the reference copied
the shape diu-stop rejects.

verify.md now shows the same template. The structural catch walks every
markdown file in the skill instead of SKILL.md alone, and asserts the two
files that carry the rule are in the swept list, so an empty or mis-rooted
scan cannot report clean. The "still shows the tag at all" assertion now
covers both copies, so the fix cannot be deleting the example in either.

Fail-before / pass-after on
tests.test_cat_mode.TestEscapeHatchTemplateIsWellFormed: the extended scan
fails on verify.md's `['{{CAT-UNVERIFIED}}']` before the edit, and the full
91-test tests/test_cat_mode.py suite passes after.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The escape-hatch test explained why it pins SKILL.md and verify.md by
name in three `#` comment lines. Comments are banned in code here, and
CI's no-comments twin (scripts/ci/check_no_new_comments.py, the gate for
engine/hooks/no-comments) failed the PR on exactly those three lines.

The reason is worth keeping: a scan over an empty or mis-rooted list
reports clean and reads the same as a pass, so the two files that carry
the rule are asserted into the list before the sweep runs. Moving that
text into the method docstring keeps it where a reader and `unittest -v`
both see it, and the detector only looks for `#` and `//`.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@EdbertChan

Copy link
Copy Markdown
Owner Author

@Mergifyio queue

@EdbertChan
EdbertChan force-pushed the stack/EdbertChan/reflect/subagent-decisions-slot-20260922/cat-mode-show-escape-hatch-tag-form-gate-accepts--f47021e8 branch from a8e7f75 to 2e69d29 Compare September 24, 2026 11:08
@cursor

cursor Bot commented Sep 24, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: serverGenReqId_fd27c241-ea9f-4f63-b0a9-0a7c35fb7a19)

@mergify

mergify Bot commented Sep 24, 2026

Copy link
Copy Markdown
Contributor

queue

🛑 The pull request has been removed from the queue admin-bypass

Details

The pull request #786 has been manually updated.

You can take a look at Mergify Merge Queue check runs for more details about the failure.

@EdbertChan

Copy link
Copy Markdown
Owner Author

@Mergifyio queue

@mergify

mergify Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Merge Queue Status

This pull request spent 20 minutes 22 seconds in the queue, including 19 minutes 55 seconds running CI.

Required conditions to merge
  • check-success = lint
  • check-success = test
  • check-success = validate

@mergify mergify Bot added the queued label Sep 24, 2026
@mergify mergify Bot mentioned this pull request Sep 24, 2026
6 tasks done
@mergify
mergify Bot merged commit c974939 into main Sep 24, 2026
6 checks passed
@mergify mergify Bot removed the queued label Sep 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant