Repository navigation
Mirror the withdrawn-claims guard fixes from ad-res-j7 - #16
Merged
Merged
Conversation
Wrapped corrections and negated verbs are no longer flagged; 'written off' is caught again; box rows in fenced diagrams are joined only when one continues the other, with borders dropped; the prefilter treats box borders as spacing and leaves spaces inside character classes alone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RDB1UaJwokY8cw2E1M2fvp
CodeQL flagged the character-class branch: a backslash could match both '\\.' and '[^\]]', so '[' followed by many backslashes backtracked exponentially. Backslash is now excluded from the second branch (from cogpy/ad-res-j7). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RDB1UaJwokY8cw2E1M2fvp
There was a problem hiding this comment.
🟡 Changes recommended
The checker can miss withdrawn claims because its prefilter excludes line breaks within space-bearing character classes and its continuation logic drops uppercase or numeric follow-on text.
2 open issues
What changed in this PR
Mirrors upstream withdrawn-claims guard updates into this repository, retaining its local path exemptions and adding no new claims or banners.
Changes:
- Updates wrapped-correction handling, fenced-diagram grouping, and prefilter spacing.
- Adjusts claim patterns for negated extraction wording and “written off” amounts, with supporting examples.
- Refreshes the register’s mirror date and provenance.
| File | Description |
|---|---|
scripts/check_withdrawn_claims.py |
Updates correction exemptions, diagram row handling, and prefilter transformation. |
docs/strategic/WITHDRAWN_CLAIMS_REGISTER.json |
Revises two claim patterns and their examples; updates mirror metadata. |
Review effort: Balanced
Comment on lines
+186
to
+188
| if not (content[:1].islower() and sub): | ||
| paragraphs.append(sub) | ||
| sub = [] |
| pattern = re.sub(r"\{(\d+),(\d+)\}", lambda m: "{%s,%d}" % (m.group(1), int(m.group(2)) + 200), pattern) | ||
| return pattern.replace("(?i)", "").replace("[^.\\n|]", "[^.|]").replace("[^.\\n]", "[^.]").replace("[^\\n]", "[\\s\\S]").replace(" ", "\\s*") | ||
| pattern = pattern.replace("(?i)", "").replace("[^.\\n|]", "[^.|]").replace("[^.\\n]", "[^.]").replace("[^\\n]", "[\\s\\S]") | ||
| return re.sub(r"\\.|\[(?:\\.|[^\]\\])*\]| ", lambda m: "[\\s│┃║]*" if m.group() == " " else m.group(), pattern) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Copies
scripts/check_withdrawn_claims.pyanddocs/strategic/WITHDRAWN_CLAIMS_REGISTER.json(updated 2026-11-12) from cogpy/ad-res-j7#5134, which fixed the five gaps Copilot found on cogpy/discosys#9:This repository's own
allow_pathsare kept. No claim was added, so no banners change. The withdrawn-claims guard passes on the diff.Generated by Claude Code