Pattern miner: Add curated link-checker archetype from upstream pattern mining - #264
Draft
github-actions[bot] wants to merge 1 commit into
Draft
Conversation
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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.
Upstream sources mined
githubnext-agentics/files/workflows/link-checker.md— daily scheduled workflow that pre-tests all documentation links deterministically in asteps:block, then uses cache-memory to track links previously confirmed unfixable, and opens a PR viacreate-pull-requestwithprotected-files: fallback-to-issueandif-no-changes: warn, falling back tonoopwhen nothing needs fixing.githubnext-agentics/files/workflows/update-docs.md(line 99: "Check for broken links, missing images, or formatting issues") andgithub-gh-aw/files/.github/aw/triggers.md(line 19/41: "Govern documentation content (stale pages, broken links, outdated ownership)" / "Documentation governance: schedule (weekly) or pull_request... check stale ownership, broken links, and missing metadata") — corroborating upstream documentation recommending scheduled link/content governance as a recognized pattern distinct from general doc updates.Recurring pattern found
A dedicated "check and fix broken links" shape recurs distinctly from the existing
documentation-updaterarchetype: it is deterministic-first (pre-fetch/test links insteps:rather than agent judgment), usescache-memoryas a persistent skip-list for links with no available fix, and is scoped narrowly to link validity rather than general content accuracy. One direct upstream workflow (link-checker.md) demonstrates the full shape, corroborated by upstreamtriggers.mddocumentation explicitly calling out "broken links" governance as a canonicalschedule-triggered pattern with its owncreate-issue/add-commentoutput guidance, satisfying the "one workflow + explicit doc recommendation" bar.Why the existing library did not cover it
The existing
documentation-updaterarchetype only generically mentions "Fix inaccuracies, broken links, and outdated examples" in its runtime body text, but its curated tips do not capture the two evidence-backed techniques that distinguish this shape: (1) pre-fetching/testing links deterministically before the agent starts, and (2) persisting a cache-memory list of confirmed-unfixable links to avoid repeated wasted retries on a recurring schedule. No archetype inpatterns/archetypes/or entry inpatterns/manifest.jsoncovers this narrower, deterministic-first link-checking shape.What changed in
patterns/patterns/archetypes/link-checker.json— new curated archetype (success_rate: null,count: 0,top_repos: []) withscheduletrigger,pull-requestssafe output, and tips reflecting the deterministic pre-check + cache-memory skip-list pattern."link-checker"toarchetypesinpatterns/manifest.json.link-checkerentry topatterns/workflow-generation.jsonwith icon, capabilities, permissions, and a prompt body reflecting the mined process (read pre-fetched results, consult cache memory, fix confirmed replacements, open PR or noop).Validation
npm test— 18 test files, 319 tests passed.npm run build— production build succeeded (site + patterns copied intodist/).Candidates deliberately left out
discussion-task-miner.md) — only one upstream workflow demonstrates this shape (scan discussions → create issues); no corroborating upstream documentation recommends it as a distinct pattern, so it does not meet the two-workflow or doc-backed bar.sub-issue-closer.md) — largely already covered by the existingissue-hierarchy-managerarchetype'supdate-issue/close-parent tips.tech-content-editorial-board.md,unbloat-docs.md) — a useful refinement, but scoped tocode-improvement/documentation-updatertips that already mention the "skip scheduled runs once too many open PRs" guidance, so it is already represented.campaign.md,multi-agent-research.md) — these are meta-guidance documents, not recurring workflow shapes from actual upstream workflows, so they don't meet the archetype bar.