From 7377eec2ada2b3af87a0eca4a9cec54cbef39f5a Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 14:27:22 -0800 Subject: [PATCH 01/15] Accept paraphrased upstream change in remote pins grader Match equivalent wordings of the fixture's empty-note-list change within one sentence, and report which check failed with a bounded, redacted output excerpt through an optional detail on the shared check helper. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 84 +++++++++++++++++++ evals/_shared/graders/common.mjs | 12 ++- .../skills/update-remote-pins/grader.mjs | 25 +++++- 3 files changed, 116 insertions(+), 5 deletions(-) create mode 100644 .github/scripts/update-remote-pins.test.mjs diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs new file mode 100644 index 0000000..e51bacb --- /dev/null +++ b/.github/scripts/update-remote-pins.test.mjs @@ -0,0 +1,84 @@ +import test from "node:test"; +import assert from "node:assert/strict"; +import { randomUUID } from "node:crypto"; +import { cpSync, existsSync, mkdirSync, readFileSync, rmSync, writeFileSync } from "node:fs"; +import { resolve } from "node:path"; +import { fileURLToPath, pathToFileURL } from "node:url"; +import { parse } from "yaml"; + +const root = fileURLToPath(new URL("../../", import.meta.url)); +const evalDirectory = resolve(root, "evals/marketplace-maintainer/skills/update-remote-pins"); +const pinsTest = existsSync(evalDirectory) ? test : test.skip; +const label = "Reported the upstream change and offline limit"; + +async function fixture(t) { + const spec = parse(readFileSync(resolve(evalDirectory, "eval.yaml"), "utf8")); + const stimulus = spec.stimuli.find((item) => item.name === "update-remote-pins-uses-reviewed-release"); + const directory = resolve(root, ".github/scripts", `.remote-pins-test-${randomUUID()}`); + const workspace = resolve(directory, "workspace"); + mkdirSync(workspace, { recursive: true }); + t.after(() => rmSync(directory, { recursive: true, force: true })); + for (const file of stimulus.agent_environment.files) { + cpSync(resolve(evalDirectory, file.src), resolve(workspace, file.dest), { recursive: true }); + } + for (const file of spec.grading_environment.files) { + const destination = resolve(directory, file.dest); + mkdirSync(resolve(destination, ".."), { recursive: true }); + cpSync(resolve(evalDirectory, file.src), destination); + } + const { evaluate } = await import(pathToFileURL(resolve(directory, ".grading/grader.mjs"))); + const { score } = await import(pathToFileURL(resolve(directory, ".grading/common.mjs"))); + const catalog = JSON.parse(readFileSync(resolve(workspace, "marketplace.json"), "utf8")); + const entry = catalog.plugins.find((item) => item.name === "outside-notes"); + Object.assign(entry, { version: "1.1.0" }); + Object.assign(entry.source, { sha: "b".repeat(40), ref: "v1.1.0" }); + writeFileSync(resolve(workspace, "marketplace.json"), JSON.stringify(catalog, null, 2)); + return (output) => score("marketplace-maintainer-remote", evaluate({ output, events: [] }, workspace)); +} + +const offline = "This used the recorded offline snapshot, not live GitHub verification."; + +pinsTest("update-remote-pins accepts the fixture's upstream change in exact and paraphrased wording", async (t) => { + const grade = await fixture(t); + for (const summary of [ + "Upstream change: Add support for empty note lists.", + "v1.1.0 now handles an empty notes list without errors.", + "The only change: the notes list can now be empty.", + "It adds support for empty lists of notes.", + "Note lists that are empty are now supported.", + "Lists with no notes are now handled.", + "- v1.1.0 adds support for **empty** note lists.", + "v1.1.0 adds empty-note-list support.", + ]) { + const result = grade(`${summary} No new hooks or dependencies. ${offline}`); + assert.equal(result.passed, true, `${summary}: ${result.evidence}`); + } +}); + +pinsTest("update-remote-pins rejects missing or unrelated upstream changes and a missing offline limit", async (t) => { + const grade = await fixture(t); + for (const [output, reason] of [ + [`Pinned outside-notes to v1.1.0. No new hooks or dependencies. ${offline}`, /no empty-note-list change/], + [`Updated the synthetic outside notes plugin; see the release notes list. Nothing is empty. ${offline}`, /no empty-note-list change/], + [`The release notes list is empty. ${offline}`, /no empty-note-list change/], + [`The release-notes list is empty. ${offline}`, /no empty-note-list change/], + [`Note lists must not be empty. ${offline}`, /no empty-note-list change/], + ["Upstream change: Add support for empty note lists. Verified on GitHub.", /no offline limit/], + ]) { + const result = grade(output); + assert.equal(result.passed, false, output); + assert.ok(result.evidence.includes(label), result.evidence); + assert.match(result.evidence, reason); + } +}); + +pinsTest("update-remote-pins failure evidence is bounded and redacts token-like text", async (t) => { + const grade = await fixture(t); + const token = `ghp_${"A".repeat(36)}`; + const result = grade(`Pinned it with ${token}. {"token": "synthetic-opaque-value"} ${"filler ".repeat(200)}`); + assert.equal(result.passed, false); + assert.match(result.evidence, /Pinned it with \[redacted\]/); + assert.ok(!result.evidence.includes("synthetic-opaque-value"), result.evidence); + assert.ok(!result.evidence.includes(token), result.evidence); + assert.ok(result.evidence.length < 600, `evidence length ${result.evidence.length}`); +}); diff --git a/evals/_shared/graders/common.mjs b/evals/_shared/graders/common.mjs index 9f4fc51..29746c5 100644 --- a/evals/_shared/graders/common.mjs +++ b/evals/_shared/graders/common.mjs @@ -3,7 +3,15 @@ import { resolve } from "node:path"; import { fileURLToPath } from "node:url"; const real = (path) => { try { return realpathSync(path); } catch { return resolve(path); } }; -export const check = (label, passed) => ({ label, passed: Boolean(passed) }); +// An optional detail explains a failure in the grader evidence; keep it short and pass output through excerpt(). +export const check = (label, passed, detail) => ({ label, passed: Boolean(passed), ...(detail ? { detail } : {}) }); +export const excerpt = (value, max = 160) => { + const flat = String(value ?? "") + .replace(/\b(?:gh[pousr]_[A-Za-z0-9]{20,}|github_pat_[A-Za-z0-9_]{20,})\b/g, "[redacted]") + .replace(/\b(bearer|token|password|secret)(["']?\s*[:=]?\s*)["']?[^\s"',}]+["']?/gi, "$1$2[redacted]") + .replace(/\s+/g, " ").trim(); + return JSON.stringify(flat.length > max ? `${flat.slice(0, max)}…` : flat); +}; // Real paths, because Node resolves import.meta.url through symlinks but not argv. export const isMain = (url) => Boolean(process.argv[1]) && real(resolve(process.argv[1])) === real(fileURLToPath(url)); export const normalize = (text) => text.replaceAll("\r\n", "\n"); @@ -36,7 +44,7 @@ export function score(name, checks) { return { name, kind: "code", passed: failures.length === 0, score: (checks.length - failures.length) / checks.length, - evidence: failures.length ? failures.map((item) => item.label).join("; ") : "All contract assertions passed.", + evidence: failures.length ? failures.map((item) => item.detail ? `${item.label} (${item.detail})` : item.label).join("; ") : "All contract assertions passed.", }; } diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 1e7e4b3..244d7f3 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -1,16 +1,35 @@ -import { check, isMain, json, runGrade } from "./common.mjs"; +import { check, excerpt, isMain, json, runGrade } from "./common.mjs"; + +// The fixture's only upstream change is "Add support for empty note lists"; accept equivalent +// wordings within one sentence, but not release notes or unrelated mentions of notes or emptiness. +const note = String.raw`(? new RegExp(pattern, "i")); + +export function reportsUpstreamChange(output) { + // Drop Markdown emphasis and join compound words so "**empty** note lists" and "empty-note-list" still match. + const plain = output.replace(/[*_`]/g, "").replace(/(?<=\w)-(?=\w)/g, " "); + return plain.split(/(?<=[.!?])\s+|\n+/).some((sentence) => emptyNoteLists.some((pattern) => pattern.test(sentence))); +} export function evaluate(trajectory, workspace) { const catalog = json(workspace, "marketplace.json"); if (!Array.isArray(catalog?.plugins)) return [check("Preserved a valid catalog", false)]; const entry = catalog.plugins.find((item) => item.name === "outside-notes"); + const change = reportsUpstreamChange(trajectory.output); + const offline = /offline|recorded/i.test(trajectory.output); + const missing = [!change && "no empty-note-list change", !offline && "no offline limit"].filter(Boolean); return [ check("Updated the exact reviewed SHA, ref and version", entry?.source?.sha === "b".repeat(40) && entry?.source?.ref === "v1.1.0" && entry?.version === "1.1.0" && entry?.source?.repo === "fixture-org/outside-notes"), check("Preserved the unrelated local entry", catalog.plugins.some((item) => item.name === "sample-notes" && item.version === "1.0.0")), - check("Reported the upstream change and offline limit", /empty note lists/i.test(trajectory.output) - && /offline|recorded/i.test(trajectory.output)), + check("Reported the upstream change and offline limit", change && offline, + `${missing.join(", ")}; output: ${excerpt(trajectory.output)}`), ]; } From 45cb3b040a77d3246112c4e143ed4ddf29ef62a7 Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 14:31:46 -0800 Subject: [PATCH 02/15] Keep model output out of grader failure evidence Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 10 ++++------ evals/_shared/graders/common.mjs | 9 +-------- .../skills/update-remote-pins/grader.mjs | 5 ++--- 3 files changed, 7 insertions(+), 17 deletions(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index e51bacb..b7b7a3c 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -72,13 +72,11 @@ pinsTest("update-remote-pins rejects missing or unrelated upstream changes and a } }); -pinsTest("update-remote-pins failure evidence is bounded and redacts token-like text", async (t) => { +pinsTest("update-remote-pins failure evidence names missing conditions without echoing model output", async (t) => { const grade = await fixture(t); const token = `ghp_${"A".repeat(36)}`; - const result = grade(`Pinned it with ${token}. {"token": "synthetic-opaque-value"} ${"filler ".repeat(200)}`); + const result = grade(`Pinned it with ${token}. {"token": "synthetic-opaque-value"}`); assert.equal(result.passed, false); - assert.match(result.evidence, /Pinned it with \[redacted\]/); - assert.ok(!result.evidence.includes("synthetic-opaque-value"), result.evidence); - assert.ok(!result.evidence.includes(token), result.evidence); - assert.ok(result.evidence.length < 600, `evidence length ${result.evidence.length}`); + assert.match(result.evidence, /\(no empty-note-list change, no offline limit\)/); + assert.ok(!result.evidence.includes(token) && !result.evidence.includes("synthetic-opaque-value"), result.evidence); }); diff --git a/evals/_shared/graders/common.mjs b/evals/_shared/graders/common.mjs index 29746c5..dbf7b1e 100644 --- a/evals/_shared/graders/common.mjs +++ b/evals/_shared/graders/common.mjs @@ -3,15 +3,8 @@ import { resolve } from "node:path"; import { fileURLToPath } from "node:url"; const real = (path) => { try { return realpathSync(path); } catch { return resolve(path); } }; -// An optional detail explains a failure in the grader evidence; keep it short and pass output through excerpt(). +// An optional detail explains a failure in the grader evidence; never include raw model output. export const check = (label, passed, detail) => ({ label, passed: Boolean(passed), ...(detail ? { detail } : {}) }); -export const excerpt = (value, max = 160) => { - const flat = String(value ?? "") - .replace(/\b(?:gh[pousr]_[A-Za-z0-9]{20,}|github_pat_[A-Za-z0-9_]{20,})\b/g, "[redacted]") - .replace(/\b(bearer|token|password|secret)(["']?\s*[:=]?\s*)["']?[^\s"',}]+["']?/gi, "$1$2[redacted]") - .replace(/\s+/g, " ").trim(); - return JSON.stringify(flat.length > max ? `${flat.slice(0, max)}…` : flat); -}; // Real paths, because Node resolves import.meta.url through symlinks but not argv. export const isMain = (url) => Boolean(process.argv[1]) && real(resolve(process.argv[1])) === real(fileURLToPath(url)); export const normalize = (text) => text.replaceAll("\r\n", "\n"); diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 244d7f3..67ac1f4 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -1,4 +1,4 @@ -import { check, excerpt, isMain, json, runGrade } from "./common.mjs"; +import { check, isMain, json, runGrade } from "./common.mjs"; // The fixture's only upstream change is "Add support for empty note lists"; accept equivalent // wordings within one sentence, but not release notes or unrelated mentions of notes or emptiness. @@ -28,8 +28,7 @@ export function evaluate(trajectory, workspace) { && entry?.source?.ref === "v1.1.0" && entry?.version === "1.1.0" && entry?.source?.repo === "fixture-org/outside-notes"), check("Preserved the unrelated local entry", catalog.plugins.some((item) => item.name === "sample-notes" && item.version === "1.0.0")), - check("Reported the upstream change and offline limit", change && offline, - `${missing.join(", ")}; output: ${excerpt(trajectory.output)}`), + check("Reported the upstream change and offline limit", change && offline, missing.join(", ")), ]; } From ad05bfd3b838b19c203d01b3d72aa6bb1f53ce34 Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 14:33:48 -0800 Subject: [PATCH 03/15] Reject negated and whitespace-split release-notes claims in remote pins grader Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 4 ++++ .../skills/update-remote-pins/grader.mjs | 13 ++++++++----- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index b7b7a3c..1d128b1 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -63,6 +63,10 @@ pinsTest("update-remote-pins rejects missing or unrelated upstream changes and a [`The release notes list is empty. ${offline}`, /no empty-note-list change/], [`The release-notes list is empty. ${offline}`, /no empty-note-list change/], [`Note lists must not be empty. ${offline}`, /no empty-note-list change/], + [`Lists with no notes are not supported. ${offline}`, /no empty-note-list change/], + [`Note lists that are empty are no longer supported. ${offline}`, /no empty-note-list change/], + [`The release notes list is empty. ${offline}`, /no empty-note-list change/], + [`The release\nnotes list is empty. ${offline}`, /no empty-note-list change/], ["Upstream change: Add support for empty note lists. Verified on GitHub.", /no offline limit/], ]) { const result = grade(output); diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 67ac1f4..6e7864b 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -1,8 +1,9 @@ import { check, isMain, json, runGrade } from "./common.mjs"; // The fixture's only upstream change is "Add support for empty note lists"; accept equivalent -// wordings within one sentence, but not release notes or unrelated mentions of notes or emptiness. -const note = String.raw`(? new RegExp(pattern, "i")); export function reportsUpstreamChange(output) { - // Drop Markdown emphasis and join compound words so "**empty** note lists" and "empty-note-list" still match. - const plain = output.replace(/[*_`]/g, "").replace(/(?<=\w)-(?=\w)/g, " "); - return plain.split(/(?<=[.!?])\s+|\n+/).some((sentence) => emptyNoteLists.some((pattern) => pattern.test(sentence))); + // Drop Markdown emphasis and join compound words so "**empty** note lists" and "empty-note-list" still match; + // fold "release notes" (even across spaces or a soft wrap) into one word before splitting so it never matches. + const plain = output.replace(/[*_`]/g, "").replace(/(?<=\w)-(?=\w)/g, " ").replace(/\brelease\s+notes?\b/gi, "releasenotes"); + return plain.split(/(?<=[.!?])\s+|\n+/).some((sentence) => !negated.test(sentence) + && emptyNoteLists.some((pattern) => pattern.test(sentence))); } export function evaluate(trajectory, workspace) { From e33cf896a7826f0c6bc0b66f44ae8f92647be25e Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 14:34:49 -0800 Subject: [PATCH 04/15] Allow only short condition labels as grader failure details Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 7 +++++++ evals/_shared/graders/common.mjs | 8 ++++++-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index 1d128b1..43904d1 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -84,3 +84,10 @@ pinsTest("update-remote-pins failure evidence names missing conditions without e assert.match(result.evidence, /\(no empty-note-list change, no offline limit\)/); assert.ok(!result.evidence.includes(token) && !result.evidence.includes("synthetic-opaque-value"), result.evidence); }); + +test("shared check() drops failure details that aren't short condition labels", async () => { + const { check, score } = await import(pathToFileURL(resolve(root, "evals/_shared/graders/common.mjs")).href); + const token = `ghp_${"A".repeat(36)}`; + const evidence = score("synthetic", [check("Kept", false, `saw ${token}`), check("Named", false, "no offline limit")]).evidence; + assert.equal(evidence, "Kept; Named (no offline limit)"); +}); diff --git a/evals/_shared/graders/common.mjs b/evals/_shared/graders/common.mjs index dbf7b1e..1009c1d 100644 --- a/evals/_shared/graders/common.mjs +++ b/evals/_shared/graders/common.mjs @@ -3,8 +3,12 @@ import { resolve } from "node:path"; import { fileURLToPath } from "node:url"; const real = (path) => { try { return realpathSync(path); } catch { return resolve(path); } }; -// An optional detail explains a failure in the grader evidence; never include raw model output. -export const check = (label, passed, detail) => ({ label, passed: Boolean(passed), ...(detail ? { detail } : {}) }); +// An optional detail names why a check failed. Only short lowercase condition labels pass, so model output, +// tokens or paths never reach evidence. +const safeDetail = /^[a-z][a-z ,-]{0,99}$/; +export const check = (label, passed, detail) => ({ + label, passed: Boolean(passed), ...(typeof detail === "string" && safeDetail.test(detail) ? { detail } : {}), +}); // Real paths, because Node resolves import.meta.url through symlinks but not argv. export const isMain = (url) => Boolean(process.argv[1]) && real(resolve(process.argv[1])) === real(fileURLToPath(url)); export const normalize = (text) => text.replaceAll("\r\n", "\n"); From 306e5419c941d79ce26ad0c43a83941de0bb3e4a Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 14:42:39 -0800 Subject: [PATCH 05/15] Limit grader negation check to denials of the upstream change Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 3 +++ .../skills/update-remote-pins/grader.mjs | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index 43904d1..0c8d2b1 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -49,6 +49,8 @@ pinsTest("update-remote-pins accepts the fixture's upstream change in exact and "Lists with no notes are now handled.", "- v1.1.0 adds support for **empty** note lists.", "v1.1.0 adds empty-note-list support.", + "Empty note lists no longer cause errors.", + "Added support for empty note lists; verified offline, not against live GitHub.", ]) { const result = grade(`${summary} No new hooks or dependencies. ${offline}`); assert.equal(result.passed, true, `${summary}: ${result.evidence}`); @@ -64,6 +66,7 @@ pinsTest("update-remote-pins rejects missing or unrelated upstream changes and a [`The release-notes list is empty. ${offline}`, /no empty-note-list change/], [`Note lists must not be empty. ${offline}`, /no empty-note-list change/], [`Lists with no notes are not supported. ${offline}`, /no empty-note-list change/], + [`v1.1.0 doesn't support empty note lists. ${offline}`, /no empty-note-list change/], [`Note lists that are empty are no longer supported. ${offline}`, /no empty-note-list change/], [`The release notes list is empty. ${offline}`, /no empty-note-list change/], [`The release\nnotes list is empty. ${offline}`, /no empty-note-list change/], diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 6e7864b..9b79e23 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -3,7 +3,8 @@ import { check, isMain, json, runGrade } from "./common.mjs"; // The fixture's only upstream change is "Add support for empty note lists"; accept equivalent // wordings within one affirmative sentence, but not release notes or unrelated mentions of notes or emptiness. const note = String.raw`\bnotes?`; -const negated = /\b(?:not|never|no\s+longer|cannot|unsupported)\b|n't\b/i; +// Only a negation that denies the change counts ("not supported", "must not be empty"), not "no longer cause errors". +const negated = /\b(?:not|never|no\s+longer|cannot|can't|don't|doesn't|isn't|aren't|won't)\s+(?:\w+\s+){0,2}?(?:support(?:ed|s)?|allow(?:ed|s)?|handle[ds]?|accept(?:ed|s)?|(?:be\s+)?empty)\b|\bunsupported\b/i; const emptyNoteLists = [ String.raw`\bempty\s+${note}\s+lists?\b`, String.raw`${note}\s+lists?\s+(?:(?:that|which|can|may|now|are|is|be)\s+){0,3}empty\b`, From 2d01489da091cb11fb295fa8c65593be76c1791e Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 14:50:43 -0800 Subject: [PATCH 06/15] Handle historical negation, curly apostrophes and missing evals in remote pins grader tests Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 5 ++++- .../skills/update-remote-pins/grader.mjs | 11 +++++++---- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index 0c8d2b1..6c03ee6 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -51,6 +51,8 @@ pinsTest("update-remote-pins accepts the fixture's upstream change in exact and "v1.1.0 adds empty-note-list support.", "Empty note lists no longer cause errors.", "Added support for empty note lists; verified offline, not against live GitHub.", + "Added support for previously unsupported empty note lists.", + "Empty note lists are now supported, so callers don't need to handle them specially.", ]) { const result = grade(`${summary} No new hooks or dependencies. ${offline}`); assert.equal(result.passed, true, `${summary}: ${result.evidence}`); @@ -67,6 +69,7 @@ pinsTest("update-remote-pins rejects missing or unrelated upstream changes and a [`Note lists must not be empty. ${offline}`, /no empty-note-list change/], [`Lists with no notes are not supported. ${offline}`, /no empty-note-list change/], [`v1.1.0 doesn't support empty note lists. ${offline}`, /no empty-note-list change/], + [`Lists with no notes aren\u2019t supported. ${offline}`, /no empty-note-list change/], [`Note lists that are empty are no longer supported. ${offline}`, /no empty-note-list change/], [`The release notes list is empty. ${offline}`, /no empty-note-list change/], [`The release\nnotes list is empty. ${offline}`, /no empty-note-list change/], @@ -88,7 +91,7 @@ pinsTest("update-remote-pins failure evidence names missing conditions without e assert.ok(!result.evidence.includes(token) && !result.evidence.includes("synthetic-opaque-value"), result.evidence); }); -test("shared check() drops failure details that aren't short condition labels", async () => { +pinsTest("shared check() drops failure details that aren't short condition labels", async () => { const { check, score } = await import(pathToFileURL(resolve(root, "evals/_shared/graders/common.mjs")).href); const token = `ghp_${"A".repeat(36)}`; const evidence = score("synthetic", [check("Kept", false, `saw ${token}`), check("Named", false, "no offline limit")]).evidence; diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 9b79e23..98067ca 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -3,8 +3,9 @@ import { check, isMain, json, runGrade } from "./common.mjs"; // The fixture's only upstream change is "Add support for empty note lists"; accept equivalent // wordings within one affirmative sentence, but not release notes or unrelated mentions of notes or emptiness. const note = String.raw`\bnotes?`; -// Only a negation that denies the change counts ("not supported", "must not be empty"), not "no longer cause errors". -const negated = /\b(?:not|never|no\s+longer|cannot|can't|don't|doesn't|isn't|aren't|won't)\s+(?:\w+\s+){0,2}?(?:support(?:ed|s)?|allow(?:ed|s)?|handle[ds]?|accept(?:ed|s)?|(?:be\s+)?empty)\b|\bunsupported\b/i; +// Only a negation that denies the change counts ("not supported", "must not be empty"), not "no longer cause errors", +// "previously unsupported" or "callers don't need to handle them". +const negated = /\b(?:not|never|no\s+longer|cannot|can't|don't|doesn't|isn't|aren't|won't)\s+(?:\w+\s+){0,2}?(?:support(?:ed|s)?|allow(?:ed|s)?|accept(?:ed|s)?|(?:be\s+)?empty)\b|(? new RegExp(pattern, "i")); export function reportsUpstreamChange(output) { - // Drop Markdown emphasis and join compound words so "**empty** note lists" and "empty-note-list" still match; + // Drop Markdown emphasis, straighten curly apostrophes and join compound words so "**empty** note lists", + // "aren’t" and "empty-note-list" match their plain forms; // fold "release notes" (even across spaces or a soft wrap) into one word before splitting so it never matches. - const plain = output.replace(/[*_`]/g, "").replace(/(?<=\w)-(?=\w)/g, " ").replace(/\brelease\s+notes?\b/gi, "releasenotes"); + const plain = output.replace(/[*_`]/g, "").replace(/[\u2018\u2019]/g, "'").replace(/(?<=\w)-(?=\w)/g, " ") + .replace(/\brelease\s+notes?\b/gi, "releasenotes"); return plain.split(/(?<=[.!?])\s+|\n+/).some((sentence) => !negated.test(sentence) && emptyNoteLists.some((pattern) => pattern.test(sentence))); } From 0512bd5d49b2ccaf90f2c02458d4ec77c34583d2 Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 14:57:21 -0800 Subject: [PATCH 07/15] Reject passive 'not handled' denials in remote pins grader Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 1 + .../marketplace-maintainer/skills/update-remote-pins/grader.mjs | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index 6c03ee6..9d65735 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -70,6 +70,7 @@ pinsTest("update-remote-pins rejects missing or unrelated upstream changes and a [`Lists with no notes are not supported. ${offline}`, /no empty-note-list change/], [`v1.1.0 doesn't support empty note lists. ${offline}`, /no empty-note-list change/], [`Lists with no notes aren\u2019t supported. ${offline}`, /no empty-note-list change/], + [`Lists with no notes aren't handled. ${offline}`, /no empty-note-list change/], [`Note lists that are empty are no longer supported. ${offline}`, /no empty-note-list change/], [`The release notes list is empty. ${offline}`, /no empty-note-list change/], [`The release\nnotes list is empty. ${offline}`, /no empty-note-list change/], diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 98067ca..3745539 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -5,7 +5,7 @@ import { check, isMain, json, runGrade } from "./common.mjs"; const note = String.raw`\bnotes?`; // Only a negation that denies the change counts ("not supported", "must not be empty"), not "no longer cause errors", // "previously unsupported" or "callers don't need to handle them". -const negated = /\b(?:not|never|no\s+longer|cannot|can't|don't|doesn't|isn't|aren't|won't)\s+(?:\w+\s+){0,2}?(?:support(?:ed|s)?|allow(?:ed|s)?|accept(?:ed|s)?|(?:be\s+)?empty)\b|(? Date: Wed, 25 Nov 2026 15:03:54 -0800 Subject: [PATCH 08/15] Accept historical contrast with an explicit now-supported affirmation Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 3 +++ .../skills/update-remote-pins/grader.mjs | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index 9d65735..427c932 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -53,6 +53,8 @@ pinsTest("update-remote-pins accepts the fixture's upstream change in exact and "Added support for empty note lists; verified offline, not against live GitHub.", "Added support for previously unsupported empty note lists.", "Empty note lists are now supported, so callers don't need to handle them specially.", + "Empty note lists weren't supported before; v1.1.0 now supports them.", + "Previously not supported, empty note lists are now supported.", ]) { const result = grade(`${summary} No new hooks or dependencies. ${offline}`); assert.equal(result.passed, true, `${summary}: ${result.evidence}`); @@ -71,6 +73,7 @@ pinsTest("update-remote-pins rejects missing or unrelated upstream changes and a [`v1.1.0 doesn't support empty note lists. ${offline}`, /no empty-note-list change/], [`Lists with no notes aren\u2019t supported. ${offline}`, /no empty-note-list change/], [`Lists with no notes aren't handled. ${offline}`, /no empty-note-list change/], + [`Empty note lists were supported before but are not supported now. ${offline}`, /no empty-note-list change/], [`Note lists that are empty are no longer supported. ${offline}`, /no empty-note-list change/], [`The release notes list is empty. ${offline}`, /no empty-note-list change/], [`The release\nnotes list is empty. ${offline}`, /no empty-note-list change/], diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 3745539..b868901 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -6,6 +6,8 @@ const note = String.raw`\bnotes?`; // Only a negation that denies the change counts ("not supported", "must not be empty"), not "no longer cause errors", // "previously unsupported" or "callers don't need to handle them". const negated = /\b(?:not|never|no\s+longer|cannot|can't|don't|doesn't|isn't|aren't|won't)\s+(?:\w+\s+){0,2}?(?:support(?:ed|s)?|allow(?:ed|s)?|accept(?:ed|s)?|handled|(?:be\s+)?empty)\b|(? !negated.test(sentence) + return plain.split(/(?<=[.!?])\s+|\n+/).some((sentence) => (!negated.test(sentence) || affirmed.test(sentence)) && emptyNoteLists.some((pattern) => pattern.test(sentence))); } From b831c7eb5cb7810bffa9e16753c932817bb9ac98 Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 15:11:32 -0800 Subject: [PATCH 09/15] Score empty-note-list support per clause Replace the sentence-wide 'now' override: current denials about the lists block the sentence, historical denials need a pronoun affirmation, and unrelated subjects don't block. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 5 +++++ .../skills/update-remote-pins/grader.mjs | 22 ++++++++++++++----- 2 files changed, 22 insertions(+), 5 deletions(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index 427c932..b865e1d 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -55,6 +55,8 @@ pinsTest("update-remote-pins accepts the fixture's upstream change in exact and "Empty note lists are now supported, so callers don't need to handle them specially.", "Empty note lists weren't supported before; v1.1.0 now supports them.", "Previously not supported, empty note lists are now supported.", + "Added support for empty note lists, which were not supported in v1.0.0.", + "Added support for empty note lists, but nested lists are not supported.", ]) { const result = grade(`${summary} No new hooks or dependencies. ${offline}`); assert.equal(result.passed, true, `${summary}: ${result.evidence}`); @@ -75,6 +77,9 @@ pinsTest("update-remote-pins rejects missing or unrelated upstream changes and a [`Lists with no notes aren't handled. ${offline}`, /no empty-note-list change/], [`Empty note lists were supported before but are not supported now. ${offline}`, /no empty-note-list change/], [`Note lists that are empty are no longer supported. ${offline}`, /no empty-note-list change/], + [`v1.1.0 now does not support empty note lists. ${offline}`, /no empty-note-list change/], + [`Empty note lists are not supported; v1.1.0 now supports headings. ${offline}`, /no empty-note-list change/], + [`Empty note lists weren't supported before; v1.1.0 now supports headings. ${offline}`, /no empty-note-list change/], [`The release notes list is empty. ${offline}`, /no empty-note-list change/], [`The release\nnotes list is empty. ${offline}`, /no empty-note-list change/], ["Upstream change: Add support for empty note lists. Verified on GitHub.", /no offline limit/], diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index b868901..3b75bd8 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -5,9 +5,13 @@ import { check, isMain, json, runGrade } from "./common.mjs"; const note = String.raw`\bnotes?`; // Only a negation that denies the change counts ("not supported", "must not be empty"), not "no longer cause errors", // "previously unsupported" or "callers don't need to handle them". -const negated = /\b(?:not|never|no\s+longer|cannot|can't|don't|doesn't|isn't|aren't|won't)\s+(?:\w+\s+){0,2}?(?:support(?:ed|s)?|allow(?:ed|s)?|accept(?:ed|s)?|handled|(?:be\s+)?empty)\b|(? (!negated.test(sentence) || affirmed.test(sentence)) - && emptyNoteLists.some((pattern) => pattern.test(sentence))); + return plain.split(/(?<=[.!?])\s+|\n+/).some(reportsInSentence); +} + +function reportsInSentence(sentence) { + const clauses = sentence.split(/\s*[;,:]\s*|\s+(?:but|while|whereas)\s+/i).filter(Boolean); + const mentions = (clause) => emptyNoteLists.some((pattern) => pattern.test(clause)); + const denies = (clause) => negated.test(clause) && !historical.test(clause); + if (clauses.some((clause) => denies(clause) && (mentions(clause) || aboutLists.test(clause)))) return false; + return clauses.some((clause) => mentions(clause) && !negated.test(clause)) + || (clauses.some((clause) => mentions(clause) && negated.test(clause)) && affirmsPronoun.test(sentence)); } export function evaluate(trajectory, workspace) { From 5f1651115fb588c4ea31c147302af76d4ef495ef Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 15:27:15 -0800 Subject: [PATCH 10/15] Split clauses linearly and limit fallback denials to subjectless clauses Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 2 ++ .../skills/update-remote-pins/grader.mjs | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index b865e1d..bbac3ad 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -57,6 +57,8 @@ pinsTest("update-remote-pins accepts the fixture's upstream change in exact and "Previously not supported, empty note lists are now supported.", "Added support for empty note lists, which were not supported in v1.0.0.", "Added support for empty note lists, but nested lists are not supported.", + "Added support for empty note lists, but it does not support nested lists.", + "Added support for empty note lists, but notes with attachments are not supported.", ]) { const result = grade(`${summary} No new hooks or dependencies. ${offline}`); assert.equal(result.passed, true, `${summary}: ${result.evidence}`); diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 3b75bd8..222923b 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -10,8 +10,8 @@ const negated = /\b(?:not|never|no\s+longer|cannot|can't|don't|doesn't|isn't|are const historical = /\b(?:before|previously|formerly|earlier|originally|v1\.0(?:\.0)?(?!\.?\d))/i; // "weren't supported before; v1.1.0 now supports them" needs the pronoun affirmation to report the change. const affirmsPronoun = /\bnow\s+(?:\w+\s+){0,2}?(?:support|handle|accept|allow)s?\s+(?:them|it)\b/i; -// A denial only blocks the sentence when it is about the lists, not another subject ("nested lists" aside). -const aboutLists = /\b(?:notes?|they|them|it)\b|^(?:are|is|were|was|aren't|isn't|weren't|wasn't|which|that)\b/i; +// Besides denials naming empty note lists, only subjectless denials ("but are not supported now") refer back to them. +const aboutLists = /^(?:(?:they|it)\s+)?(?:are|is|were|was|aren't|isn't|weren't|wasn't|which|that)\b/i; const emptyNoteLists = [ String.raw`\bempty\s+${note}\s+lists?\b`, String.raw`${note}\s+lists?\s+(?:(?:that|which|can|may|now|are|is|be)\s+){0,3}empty\b`, @@ -29,7 +29,7 @@ export function reportsUpstreamChange(output) { } function reportsInSentence(sentence) { - const clauses = sentence.split(/\s*[;,:]\s*|\s+(?:but|while|whereas)\s+/i).filter(Boolean); + const clauses = sentence.split(/[;,:]|(?<=\s)(?:but|while|whereas)(?=\s)/i).map((clause) => clause.trim()).filter(Boolean); const mentions = (clause) => emptyNoteLists.some((pattern) => pattern.test(clause)); const denies = (clause) => negated.test(clause) && !historical.test(clause); if (clauses.some((clause) => denies(clause) && (mentions(clause) || aboutLists.test(clause)))) return false; From b910e152a8f40cf024a082a675ba39f2b0ddd956 Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 15:33:46 -0800 Subject: [PATCH 11/15] Accept 'no longer rejects' and undenied pronoun affirmations Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 3 +++ .../skills/update-remote-pins/grader.mjs | 9 +++++---- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index bbac3ad..bcbf52c 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -59,6 +59,8 @@ pinsTest("update-remote-pins accepts the fixture's upstream change in exact and "Added support for empty note lists, but nested lists are not supported.", "Added support for empty note lists, but it does not support nested lists.", "Added support for empty note lists, but notes with attachments are not supported.", + "v1.1.0 no longer rejects empty note lists.", + "Empty note lists weren't supported in v1.0.0; v1.1.0 supports them.", ]) { const result = grade(`${summary} No new hooks or dependencies. ${offline}`); assert.equal(result.passed, true, `${summary}: ${result.evidence}`); @@ -82,6 +84,7 @@ pinsTest("update-remote-pins rejects missing or unrelated upstream changes and a [`v1.1.0 now does not support empty note lists. ${offline}`, /no empty-note-list change/], [`Empty note lists are not supported; v1.1.0 now supports headings. ${offline}`, /no empty-note-list change/], [`Empty note lists weren't supported before; v1.1.0 now supports headings. ${offline}`, /no empty-note-list change/], + [`Empty note lists weren't supported in v1.0.0; v1.1.0 still doesn't support them. ${offline}`, /no empty-note-list change/], [`The release notes list is empty. ${offline}`, /no empty-note-list change/], [`The release\nnotes list is empty. ${offline}`, /no empty-note-list change/], ["Upstream change: Add support for empty note lists. Verified on GitHub.", /no offline limit/], diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 222923b..975a9c5 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -5,11 +5,11 @@ import { check, isMain, json, runGrade } from "./common.mjs"; const note = String.raw`\bnotes?`; // Only a negation that denies the change counts ("not supported", "must not be empty"), not "no longer cause errors", // "previously unsupported" or "callers don't need to handle them". -const negated = /\b(?:not|never|no\s+longer|cannot|can't|don't|doesn't|isn't|aren't|wasn't|weren't|won't)\s+(?:\w+\s+){0,2}?(?:support(?:ed|s)?|allow(?:ed|s)?|accept(?:ed|s)?|handled|(?:be\s+)?empty)\b|(? negated.test(clause) && !historical.test(clause); if (clauses.some((clause) => denies(clause) && (mentions(clause) || aboutLists.test(clause)))) return false; return clauses.some((clause) => mentions(clause) && !negated.test(clause)) - || (clauses.some((clause) => mentions(clause) && negated.test(clause)) && affirmsPronoun.test(sentence)); + || (clauses.some((clause) => mentions(clause) && negated.test(clause)) + && clauses.some((clause) => affirmsPronoun.test(clause) && !negated.test(clause))); } export function evaluate(trajectory, workspace) { From 9ff2b5228a943f1c26fe52cb79a5108730c715b9 Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 15:39:13 -0800 Subject: [PATCH 12/15] Join soft-wrapped lines and accept passive pronoun affirmations Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 3 +++ .../skills/update-remote-pins/grader.mjs | 6 +++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index bcbf52c..2da19e7 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -61,6 +61,8 @@ pinsTest("update-remote-pins accepts the fixture's upstream change in exact and "Added support for empty note lists, but notes with attachments are not supported.", "v1.1.0 no longer rejects empty note lists.", "Empty note lists weren't supported in v1.0.0; v1.1.0 supports them.", + "Added support for empty\nnote lists.", + "Empty note lists weren't supported before; now they are supported.", ]) { const result = grade(`${summary} No new hooks or dependencies. ${offline}`); assert.equal(result.passed, true, `${summary}: ${result.evidence}`); @@ -85,6 +87,7 @@ pinsTest("update-remote-pins rejects missing or unrelated upstream changes and a [`Empty note lists are not supported; v1.1.0 now supports headings. ${offline}`, /no empty-note-list change/], [`Empty note lists weren't supported before; v1.1.0 now supports headings. ${offline}`, /no empty-note-list change/], [`Empty note lists weren't supported in v1.0.0; v1.1.0 still doesn't support them. ${offline}`, /no empty-note-list change/], + [`Empty note lists weren't supported before; they are still not supported. ${offline}`, /no empty-note-list change/], [`The release notes list is empty. ${offline}`, /no empty-note-list change/], [`The release\nnotes list is empty. ${offline}`, /no empty-note-list change/], ["Upstream change: Add support for empty note lists. Verified on GitHub.", /no offline limit/], diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 975a9c5..409a41f 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -9,7 +9,7 @@ const negated = /\b(?:not|never|no\s+longer|cannot|can't|don't|doesn't|isn't|are // A denial about an earlier release ("which were not supported in v1.0.0") describes the change instead of denying it. const historical = /\b(?:before|previously|formerly|earlier|originally|v1\.0(?:\.0)?(?!\.?\d))/i; // "weren't supported before; v1.1.0 supports them" needs an undenied pronoun affirmation to report the change. -const affirmsPronoun = /\b(?:(?:support|handle|accept|allow)s?|support\s+for)\s+(?:them|it)\b/i; +const affirmsPronoun = /\b(?:(?:support|handle|accept|allow)s?|support\s+for)\s+(?:them|it)\b|\b(?:they\s+are|they're|it\s+is|it's)\s+(?:now\s+)?(?:supported|handled|accepted|allowed)\b/i; // Besides denials naming empty note lists, only subjectless denials ("but are not supported now") refer back to them. const aboutLists = /^(?:(?:they|it)\s+)?(?:are|is|were|was|aren't|isn't|weren't|wasn't|which|that)\b/i; const emptyNoteLists = [ @@ -22,8 +22,8 @@ const emptyNoteLists = [ export function reportsUpstreamChange(output) { // Drop Markdown emphasis, straighten curly apostrophes and join compound words so "**empty** note lists", // "aren’t" and "empty-note-list" match their plain forms; - // fold "release notes" (even across spaces or a soft wrap) into one word before splitting so it never matches. - const plain = output.replace(/[*_`]/g, "").replace(/[\u2018\u2019]/g, "'").replace(/(?<=\w)-(?=\w)/g, " ") + // join soft-wrapped lines (but not list items, headings or paragraphs) and fold "release notes" (even across spaces or a soft wrap) into one word before splitting so it never matches. + const plain = output.replace(/\r?\n(?![ \t]*(?:[-*+][ \t]|\d+[.)][ \t]|#|\r?\n|$))/g, " ").replace(/[*_`]/g, "").replace(/[\u2018\u2019]/g, "'").replace(/(?<=\w)-(?=\w)/g, " ") .replace(/\brelease\s+notes?\b/gi, "releasenotes"); return plain.split(/(?<=[.!?])\s+|\n+/).some(reportsInSentence); } From 6ccce577d5c8ed89e911b0bcf675c236b064c618 Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 15:49:26 -0800 Subject: [PATCH 13/15] Accept affirmed changes with historical denials in remote pins grader Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 9 +++++++++ .../skills/update-remote-pins/grader.mjs | 6 +++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index 2da19e7..b2df794 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -63,6 +63,11 @@ pinsTest("update-remote-pins accepts the fixture's upstream change in exact and "Empty note lists weren't supported in v1.0.0; v1.1.0 supports them.", "Added support for empty\nnote lists.", "Empty note lists weren't supported before; now they are supported.", + "Adds support for empty note lists (previously not supported).", + "Adds support for empty note lists (not supported before).", + "Adds support for empty note lists that were not supported in v1.0.0.", + "Empty note lists (not allowed in v1.0.0) are now accepted.", + "Now supports empty note lists that previously weren't handled.", ]) { const result = grade(`${summary} No new hooks or dependencies. ${offline}`); assert.equal(result.passed, true, `${summary}: ${result.evidence}`); @@ -88,6 +93,10 @@ pinsTest("update-remote-pins rejects missing or unrelated upstream changes and a [`Empty note lists weren't supported before; v1.1.0 now supports headings. ${offline}`, /no empty-note-list change/], [`Empty note lists weren't supported in v1.0.0; v1.1.0 still doesn't support them. ${offline}`, /no empty-note-list change/], [`Empty note lists weren't supported before; they are still not supported. ${offline}`, /no empty-note-list change/], + [`Empty note lists are still not supported. ${offline}`, /no empty-note-list change/], + [`Release notes were updated. ${offline}`, /no empty-note-list change/], + [`v1.1.0 adds support for empty note lists, but they are not supported on Windows. ${offline}`, /no empty-note-list change/], + [`Empty note lists were previously not supported. ${offline}`, /no empty-note-list change/], [`The release notes list is empty. ${offline}`, /no empty-note-list change/], [`The release\nnotes list is empty. ${offline}`, /no empty-note-list change/], ["Upstream change: Add support for empty note lists. Verified on GitHub.", /no offline limit/], diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 409a41f..4d177e3 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -10,6 +10,9 @@ const negated = /\b(?:not|never|no\s+longer|cannot|can't|don't|doesn't|isn't|are const historical = /\b(?:before|previously|formerly|earlier|originally|v1\.0(?:\.0)?(?!\.?\d))/i; // "weren't supported before; v1.1.0 supports them" needs an undenied pronoun affirmation to report the change. const affirmsPronoun = /\b(?:(?:support|handle|accept|allow)s?|support\s+for)\s+(?:them|it)\b|\b(?:they\s+are|they're|it\s+is|it's)\s+(?:now\s+)?(?:supported|handled|accepted|allowed)\b/i; +// "Adds support for empty note lists (previously not supported)" affirms the change outside its historical denial. +const affirmsChange = /\b(?:add(?:s|ed|ing)?|support(?:s|ed|ing)?|accept(?:s|ed|ing)?|handl(?:e|es|ed|ing)|allow(?:s|ed|ing)?|now)\b/i; +const withoutDenials = (clause) => clause.replace(new RegExp(negated.source, "gi"), " "); // Besides denials naming empty note lists, only subjectless denials ("but are not supported now") refer back to them. const aboutLists = /^(?:(?:they|it)\s+)?(?:are|is|were|was|aren't|isn't|weren't|wasn't|which|that)\b/i; const emptyNoteLists = [ @@ -33,7 +36,8 @@ function reportsInSentence(sentence) { const mentions = (clause) => emptyNoteLists.some((pattern) => pattern.test(clause)); const denies = (clause) => negated.test(clause) && !historical.test(clause); if (clauses.some((clause) => denies(clause) && (mentions(clause) || aboutLists.test(clause)))) return false; - return clauses.some((clause) => mentions(clause) && !negated.test(clause)) + // Denials left here are historical, since current denials of the lists already returned false. + return clauses.some((clause) => mentions(clause) && (!negated.test(clause) || affirmsChange.test(withoutDenials(clause)))) || (clauses.some((clause) => mentions(clause) && negated.test(clause)) && clauses.some((clause) => affirmsPronoun.test(clause) && !negated.test(clause))); } From d92c02c7b21b39da85224c3445010e063aefa43b Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 15:55:57 -0800 Subject: [PATCH 14/15] Bind historical denial exemptions to each denial in remote pins grader Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 3 +++ .../skills/update-remote-pins/grader.mjs | 20 ++++++++++++++----- 2 files changed, 18 insertions(+), 5 deletions(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index b2df794..b476a58 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -97,6 +97,9 @@ pinsTest("update-remote-pins rejects missing or unrelated upstream changes and a [`Release notes were updated. ${offline}`, /no empty-note-list change/], [`v1.1.0 adds support for empty note lists, but they are not supported on Windows. ${offline}`, /no empty-note-list change/], [`Empty note lists were previously not supported. ${offline}`, /no empty-note-list change/], + [`v1.1.0 no longer supports empty note lists that were supported in v1.0.0. ${offline}`, /no empty-note-list change/], + [`Empty note lists are not supported now or before. ${offline}`, /no empty-note-list change/], + [`Empty note lists were previously not supported and headings are now supported. ${offline}`, /no empty-note-list change/], [`The release notes list is empty. ${offline}`, /no empty-note-list change/], [`The release\nnotes list is empty. ${offline}`, /no empty-note-list change/], ["Upstream change: Add support for empty note lists. Verified on GitHub.", /no offline limit/], diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 4d177e3..0f74f2f 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -10,9 +10,9 @@ const negated = /\b(?:not|never|no\s+longer|cannot|can't|don't|doesn't|isn't|are const historical = /\b(?:before|previously|formerly|earlier|originally|v1\.0(?:\.0)?(?!\.?\d))/i; // "weren't supported before; v1.1.0 supports them" needs an undenied pronoun affirmation to report the change. const affirmsPronoun = /\b(?:(?:support|handle|accept|allow)s?|support\s+for)\s+(?:them|it)\b|\b(?:they\s+are|they're|it\s+is|it's)\s+(?:now\s+)?(?:supported|handled|accepted|allowed)\b/i; -// "Adds support for empty note lists (previously not supported)" affirms the change outside its historical denial. -const affirmsChange = /\b(?:add(?:s|ed|ing)?|support(?:s|ed|ing)?|accept(?:s|ed|ing)?|handl(?:e|es|ed|ing)|allow(?:s|ed|ing)?|now)\b/i; -const withoutDenials = (clause) => clause.replace(new RegExp(negated.source, "gi"), " "); +// "Adds support for empty note lists (previously not supported)" passes only when every denial in the clause is bound +// to an earlier release and the remaining text directly affirms the empty-note-list change. +const historicalDenial = new RegExp(String.raw`(\b(?:previously|formerly|originally|earlier)\s+)?(?:${negated.source})(\s+(?:in\s+)?(?:before|previously|formerly|earlier|originally|v1\.0(?:\.0)?(?!\.?\d))\b)?`, "gi"); // Besides denials naming empty note lists, only subjectless denials ("but are not supported now") refer back to them. const aboutLists = /^(?:(?:they|it)\s+)?(?:are|is|were|was|aren't|isn't|weren't|wasn't|which|that)\b/i; const emptyNoteLists = [ @@ -21,6 +21,17 @@ const emptyNoteLists = [ String.raw`\bempty\s+lists?\s+of\s+${note}\b`, String.raw`\blists?\s+(?:with|containing)\s+(?:no|zero)\s+${note}\b`, ].map((pattern) => new RegExp(pattern, "i")); +const mention = emptyNoteLists.map((pattern) => `(?:${pattern.source})`).join("|"); +const affirmsMention = new RegExp(String.raw`\b(?:now\s+)?(?:add(?:s|ed)?\s+support\s+for|supports?|supported|accepts?|accepted|handles?|handled|allows?|allowed)\s+(?:${mention})|(?:${mention})\s*(?:\(\s*\)\s*)?(?:are|is)\s+now\s+(?:supported|accepted|handled|allowed)\b`, "i"); + +function affirmsDespiteHistoricalDenial(clause) { + let historicalOnly = true; + const rest = clause.replace(historicalDenial, (match, before, after) => { + if ((!before && !after) || /^no\s+longer/i.test(match.slice(before?.length ?? 0))) historicalOnly = false; + return ""; + }); + return historicalOnly && affirmsMention.test(rest); +} export function reportsUpstreamChange(output) { // Drop Markdown emphasis, straighten curly apostrophes and join compound words so "**empty** note lists", @@ -36,8 +47,7 @@ function reportsInSentence(sentence) { const mentions = (clause) => emptyNoteLists.some((pattern) => pattern.test(clause)); const denies = (clause) => negated.test(clause) && !historical.test(clause); if (clauses.some((clause) => denies(clause) && (mentions(clause) || aboutLists.test(clause)))) return false; - // Denials left here are historical, since current denials of the lists already returned false. - return clauses.some((clause) => mentions(clause) && (!negated.test(clause) || affirmsChange.test(withoutDenials(clause)))) + return clauses.some((clause) => mentions(clause) && (!negated.test(clause) || affirmsDespiteHistoricalDenial(clause))) || (clauses.some((clause) => mentions(clause) && negated.test(clause)) && clauses.some((clause) => affirmsPronoun.test(clause) && !negated.test(clause))); } From 26958a1d292856edf21b586b2924d30fa6352ab5 Mon Sep 17 00:00:00 2001 From: Jon Gallant Date: Wed, 25 Nov 2026 16:06:29 -0800 Subject: [PATCH 15/15] Treat past adverbs inside denials as historical in remote pins grader Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/scripts/update-remote-pins.test.mjs | 1 + .../skills/update-remote-pins/grader.mjs | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/scripts/update-remote-pins.test.mjs b/.github/scripts/update-remote-pins.test.mjs index b476a58..df6d53f 100644 --- a/.github/scripts/update-remote-pins.test.mjs +++ b/.github/scripts/update-remote-pins.test.mjs @@ -68,6 +68,7 @@ pinsTest("update-remote-pins accepts the fixture's upstream change in exact and "Adds support for empty note lists that were not supported in v1.0.0.", "Empty note lists (not allowed in v1.0.0) are now accepted.", "Now supports empty note lists that previously weren't handled.", + "Added support for empty note lists that were not previously supported.", ]) { const result = grade(`${summary} No new hooks or dependencies. ${offline}`); assert.equal(result.passed, true, `${summary}: ${result.evidence}`); diff --git a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs index 0f74f2f..ad4ed6c 100644 --- a/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs +++ b/evals/marketplace-maintainer/skills/update-remote-pins/grader.mjs @@ -27,7 +27,9 @@ const affirmsMention = new RegExp(String.raw`\b(?:now\s+)?(?:add(?:s|ed)?\s+supp function affirmsDespiteHistoricalDenial(clause) { let historicalOnly = true; const rest = clause.replace(historicalDenial, (match, before, after) => { - if ((!before && !after) || /^no\s+longer/i.test(match.slice(before?.length ?? 0))) historicalOnly = false; + const denial = match.slice(before?.length ?? 0); + const past = before || after || /\b(?:previously|formerly|originally|earlier)\b/i.test(denial); + if (!past || /^no\s+longer/i.test(denial)) historicalOnly = false; return ""; }); return historicalOnly && affirmsMention.test(rest);