mirror of
https://github.com/garrytan/gstack.git
synced 2026-10-03 09:56:57 +02:00
test: accept 'review mode = X' auto-decide declarations and parenthetical scope exclusions in the shared-libs actor
auto-decide-preserved: the product auto-decided HOLD SCOPE and said "Decision: review mode = HOLD SCOPE"; the grammar knew only "is" and ":". shared-libs-plan-callers: the recommended option said "(no hardening)" and the actor read "hardening" as an expansion. Both replay the captured text, keep negative controls, and passed focused paid runs.
This commit is contained in:
1 parent
12ab3b3c54
commit
a18e6cf655
6 files changed
+83
-5
No files matched your search
@@ -3,7 +3,7 @@ import type { SharedQuestionSelector } from './shared-libs-eval-fixture';
|
||||
/** Separate explicit exclusions from proposals; do not erase a following "but" clause. */
|
||||
function affirmativeCommitments(text: string): string {
|
||||
return text.split(/\n|;|(?<=[.!?])\s+|\s+but\s+|\s+however,?\s+/i).map(raw => {
|
||||
let clause = raw.replace(/^[✅❌\s]+/, '').trim();
|
||||
let clause = raw.replace(/^[✅❌\s]+/, '').replace(/\s*\((?:no|not|without|never)\b[^()]*\)/gi, '').trim();
|
||||
if (/^(?:do not|don't|never|no\b|without\b)/i.test(clause)) return '';
|
||||
if (/\b(?:is|are|remains?)\s+(?:outside\b|out of scope\b|excluded\b|not part\b)/i.test(clause)) return '';
|
||||
clause = clause.replace(/\b(?:without|do not|don't|never)\b.*$/i, '');
|
||||
|
||||
Reference in new issue
Block a user