Repository navigation
Pattern miner: Add cross-repository monitor archetype from contribution-check pattern - #320
Conversation
…ping tip Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Reviewer dispatch: auto → both (docs change in .github/copilot-instructions.md + structured pattern data in patterns/*.json, no TS/JS/CSS code touched).
Reviewed the new cross-repo-monitor archetype, the issue-hierarchy-manager tip addition, and the manifest/instructions updates.
Findings: no blocking issues.
- All modified/added JSON (
manifest.json,workflow-generation.json,cross-repo-monitor.json,issue-hierarchy-manager.json) parses correctly and follows the existing archetype schema (id,recommended_triggers,recommended_safe_outputs/recommended_tools,permissions,capabilities,bodytemplate placeholders). .github/copilot-instructions.mdcount bump (33→34) and curated-archetype list addition match the new manifest entry, consistent with whattest/copilot-instructions.test.jsandtest/patterns.test.jsassert (archetype count, curated vs. empirical listing, every manifest id having a matching archetype file).- The new archetype's
bodytemplate referencestarget-reposafe outputs in prose ("pre-configuredtarget-reposafe outputs"), but — same as the existingcontribution-guidelines-checkerprecedent — the generator (src/js/workflow.js) has no logic that actually injectstarget-repo:into generated safe-output blocks; it's left as a manual follow-up, matching the pattern already established elsewhere in this codebase rather than a regression introduced here. icon: "repo"andprompt_style: "role-steps"reuse existing conventions; no new vocabulary introduced.
Nothing here warrants REQUEST_CHANGES. (Note: this PR shows as already merged at review time.)
Warning
Firewall blocked 2 domains
The following domains were blocked by the firewall during workflow execution:
github.comregistry.npmjs.org
To allow these domains, add them to the network.allowed list in your workflow frontmatter:
network:
allowed:
- defaults
- "github.com"
- "registry.npmjs.org"See Network Configuration for more information.
Generated by Specialist PR Review for #320 · copilot · auto · 95.5 AIC · ⌖ 7.4 AIC · ⊞ 7.9K
Caution
Protected files were modified in this change.
This pull request is in
request_reviewmode and requires explicit human scrutiny before merge.Protected files:
.github/copilot-instructions.mdMined pattern: cross-repository monitor/orchestrator
Upstream evidence
githubnext-agentics/files/workflows/contribution-check.md— a schedule-triggered orchestrator that reads PRs from${{ vars.TARGET_REPOSITORY }}, dispatches each PR to a stateless sub-agent (.github/agents/contribution-checker.agent.md) for evaluation, compiles results into one report issue in the home repo, and writesadd-labels/add-commentback to the target repo usingtarget-repo:.github-gh-aw/files/.github/aw/workflow-patterns.md(lines 284-293) — the "Cross-Repository Pattern" section explicitly documents this as a recommended architecture: enable the needed GitHub toolsets for the external repo, configure PAT/GitHub App auth for cross-repo writes insafe-outputs:, settarget-repoexplicitly, and document required token scopes in the prompt.One upstream workflow demonstrates the shape, and upstream documentation explicitly describes it as a recommended pattern, satisfying the mining threshold.
Why the library did not already cover it
recommended_triggers/recommended_safe_outputsrepresented reading one repository and writing to another with atarget-repo-based split (checked via a text search ofcurrent-library.jsonfortarget-repo,TARGET_REPOSITORY,cross-repo,orchestrator).contribution-guidelines-checkerhas a one-line tip mentioningtarget-repoas an aside, but no archetype is built around the monitor/orchestrator shape itself (pre-filter → dispatch → compile report → write back cross-repo).What changed in
patterns/patterns/archetypes/cross-repo-monitor.json(new curated archetype,success_rate: null,count: 0) describing the schedule-triggered monitor/orchestrator shape, with safe outputsissues,add-labels,add-comment, and tips coveringtarget-repo, pre-filtering insteps:, per-item dispatch, report compilation withclose-older-issues, and token-scope documentation.cross-repo-monitortoarchetypesinpatterns/manifest.json.patterns/workflow-generation.json(icon,capabilities,instructions: [workflow-patterns.md],body)..github/copilot-instructions.md: bumped the archetype count to 34 and addedcross-repo-monitorto the curated-archetypes list, sotest/copilot-instructions.test.jsstays in sync.Small refinement
patterns/archetypes/issue-hierarchy-manager.json: added one tip aboutcreate-issue'sgroup: trueoption (groups several new findings as linked sub-issues under one parent). Evidenced by two upstream workflows —githubnext-agentics/files/workflows/issue-arborist.md(group: truewithmax: 5) andgithubnext-agentics/files/workflows/duplicate-code-detector.md(group: truewithmax: 3) — plus the documented option ingithub-gh-aw/files/.github/aw/safe-outputs-content.md(line 102). No existing archetype's tips mentionedgroup: true.Validation
npm test: 19 test files, 329 tests passed (includingtest/copilot-instructions.test.jsandtest/patterns.test.js, which assert every manifest archetype id has a matching file and is listed in the instructions).npm run build: succeeded;dist/patterns/archetypes/cross-repo-monitor.jsonis emitted alongside the other archetype files.Candidates deliberately left out
repository-quality-improver.md,efficiency-improver.md,tech-content-editorial-board.md) is already captured via the cache-memory rotation tips oncode-health-auditorandperformance-nut.pre_activationgate (11 upstream workflows) is already present as a tip oncode-improvement,documentation-updater,daily-test-improver,repo-maintainer,performance-nut, andlink-checker.discussion-task-miner.md) was considered but only one upstream workflow demonstrates it with no corroborating documented pattern beyond the general issue/discussion safe-output reference, so it did not meet the two-workflow-or-documented-pattern bar as a standalone archetype.agentic-wiki-writer.md,agentic-wiki-coder.md) uses thegollumtrigger andrepo-memory, butgollumis not documented as a supported trigger anywhere in the minedgithub-gh-awdocs, so it was left out pending confirmed trigger support.