Route legacy task work to the operational skill and show clickable delivery

Use stock discovery metadata and an actual Markdown document-link example. Clarify the future explicit UI-link fixture and retain the original task request and all measured failures.

Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
DottaandPaperclip committed 2026-10-02 18:05:42 -05:00
1 parent 6c0e5cf47b
commit 5f868ab2f4
6 files changed
+72 -12

No files matched your search

+1 -1
View File
@@ -28,7 +28,7 @@ export function contextIntegrityScenario(id: string, nonce: string) {
id === "ordered-comment-continuation"
? `Maintain a packing list report document. Start with the initial scope: passport and charger. Save the initial report and leave this task waiting for follow-up comments. When follow-up comments arrive, copy each user's exact wording verbatim into one ordered ledger, including identical wording repeated more than once. After the follow-up batch, save one report containing both initial items and every verbatim request in arrival order. Add a separate section headed "## Final scope" outside the quoted ledger. Put only the final requested scope name as plain text in that section. Then finish. Do not invent extra comments, child tasks, or deliverables.`
: id === PAPERCLIP_DOCUMENT_CASE
? "Use the assigned Context integrity output skill. Save its requested document as a Paperclip document on this task, check the saved revision and content, and post a completion comment linking the saved document. A workspace file alone does not deliver this requested Paperclip document. Finish after delivery. Do not create child tasks or unrelated deliverables."
? "Use the assigned Context integrity output skill. Save its requested document as a Paperclip document on this task, check the saved revision and content, and post a completion comment with a clickable Markdown link to the saved document in the Paperclip task UI, including the company prefix. A workspace file alone does not deliver this requested Paperclip document. Finish after delivery. Do not create child tasks or unrelated deliverables."
: "Use the assigned Context integrity output skill for this task, then follow its instructions and finish the task. Do not create child tasks or unrelated deliverables.",
comments: [repeated, repeated, changed] as const,
};
+5 -1
View File
@@ -24,6 +24,8 @@ describe("explicit Paperclip document delivery", () => {
const { scenario, initial, final } = recording();
expect(gradeContextIntegrity({ ...scenario, checkpoints: [initial, final] }).every(row => row.passed)).toBe(true);
expect(scenario.prompt).toContain("Paperclip document");
expect(scenario.prompt).toContain("clickable Markdown link");
expect(scenario.prompt).toContain("Paperclip task UI");
expect(scenario.prompt).not.toContain(scenario.marker);
});
it.each(["https://paperclip.example/DOC/issues/DOC-1#document-report", "<https://paperclip.example/DOC/issues/DOC-1#document-report>"])("accepts the same-app document link %s", target => {
@@ -31,12 +33,14 @@ describe("explicit Paperclip document delivery", () => {
final.comments[0]!.body = `Saved [report](${target}).`;
expect(gradeContextIntegrity({ ...scenario, checkpoints: [initial, final] }).every(row => row.passed)).toBe(true);
});
it.each(["local-only", "missing-revision", "wrong-content", "local-link", "wrong-document-link", "other-app-link", "user-link-only"])(
it.each(["local-only", "missing-revision", "wrong-content", "local-link", "wrong-document-link", "other-app-link", "user-link-only", "bare-path", "code-formatted-path"])(
"rejects plausible %s delivery", variant => {
const { scenario, initial, final } = recording();
if (variant === "local-only") { final.documents = []; final.comments[0]!.body = "Saved report.md in the workspace."; }
if (variant === "missing-revision") final.documents[0]!.latestRevisionId = null;
if (variant === "wrong-content") final.documents[0]!.body = "A different report";
if (variant === "bare-path") final.comments[0]!.body = "Saved /DOC/issues/DOC-1#document-report.";
if (variant === "code-formatted-path") final.comments[0]!.body = "Saved `/DOC/issues/DOC-1#document-report`.";
if (variant === "local-link") final.comments[0]!.body = "Saved [report](./report.md).";
if (variant === "wrong-document-link") final.comments[0]!.body = "Saved [report](/DOC/issues/DOC-1#document-other).";
if (variant === "other-app-link") final.comments[0]!.body = "Saved [report](https://other.example/DOC/issues/DOC-1#document-report).";