@mrciphersmith/keryx 0.2.164 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +85355 -56749
- package/dist/core.js +28605 -18901
- package/package.json +2 -2
- package/src/gdgraph/affected-report.ts +141 -0
- package/src/gdgraph/build.ts +170 -23
- package/src/gdgraph/service.ts +6 -0
- package/src/gdgraph/staleness.ts +253 -45
- package/src/gdskills/bundled/agents/codebase-navigator.md +55 -0
- package/src/gdskills/bundled/agents/design-advisor.md +64 -0
- package/src/gdskills/bundled/agents/docs-maintainer.md +56 -0
- package/src/gdskills/bundled/agents/end-to-end-tester.md +56 -0
- package/src/gdskills/bundled/agents/error-path-auditor.md +57 -0
- package/src/gdskills/bundled/agents/go-build-fixer.md +52 -0
- package/src/gdskills/bundled/agents/go-code-auditor.md +49 -0
- package/src/gdskills/bundled/agents/performance-auditor.md +63 -0
- package/src/gdskills/bundled/agents/python-build-fixer.md +52 -0
- package/src/gdskills/bundled/agents/python-code-auditor.md +49 -0
- package/src/gdskills/bundled/agents/refactoring-steward.md +61 -0
- package/src/gdskills/bundled/agents/security-auditor.md +62 -0
- package/src/gdskills/bundled/agents/test-first-driver.md +61 -0
- package/src/gdskills/bundled/agents/work-planner.md +62 -0
- package/src/gdskills/bundled/install-manifest.json +530 -0
- package/src/gdskills/bundled/rules/core/skill-lifecycle.mdc +29 -1
- package/src/gdskills/bundled/rules/core/skills-storage-workflow.mdc +2 -2
- package/src/gdskills/bundled/skills/review/code-style-review/SKILL.md +1 -1
- package/src/gdskills/bundled/skills/review/review-orchestrator/SKILL.md +74 -246
- package/src/gdskills/bundled/skills/review/review-orchestrator/output-contract.schema.json +19 -0
- package/src/gdskills/bundled/skills/review/review-orchestrator/reviewer-finding.schema.json +10 -0
- package/src/gdskills/bundled/skills/review/review-orchestrator/reviewer-input.schema.json +5 -0
- package/src/gdskills/bundled/skills/review/review-orchestrator/templates/pr-comment-backend.md +50 -0
- package/src/gdskills/bundled/skills/review/review-orchestrator/templates/pr-comment-frontend.md +52 -0
- package/src/gdskills/bundled/skills/review/review-orchestrator/templates/review-report.md +143 -0
- package/src/gdskills/bundled/stacks/go/agent-refs.json +3 -0
- package/src/gdskills/bundled/stacks/go/governance/eval.json +1745 -0
- package/src/gdskills/bundled/stacks/go/governance/scout.json +31 -0
- package/src/gdskills/bundled/stacks/go/pack.json +41 -0
- package/src/gdskills/bundled/stacks/go/rules/coding-style.mdc +85 -0
- package/src/gdskills/bundled/stacks/go/rules/patterns.mdc +65 -0
- package/src/gdskills/bundled/stacks/go/rules/security.mdc +73 -0
- package/src/gdskills/bundled/stacks/go/rules/testing.mdc +68 -0
- package/src/gdskills/bundled/stacks/go/skills/go-build-fix/SKILL.md +138 -0
- package/src/gdskills/bundled/stacks/go/skills/go-build-fix/evals.json +75 -0
- package/src/gdskills/bundled/stacks/go/skills/go-code-review/SKILL.md +121 -0
- package/src/gdskills/bundled/stacks/go/skills/go-code-review/evals.json +72 -0
- package/src/gdskills/bundled/stacks/go/skills/go-implementation/SKILL.md +122 -0
- package/src/gdskills/bundled/stacks/go/skills/go-implementation/evals.json +76 -0
- package/src/gdskills/bundled/stacks/go/skills/go-testing/SKILL.md +126 -0
- package/src/gdskills/bundled/stacks/go/skills/go-testing/evals.json +73 -0
- package/src/gdskills/bundled/stacks/python/agent-refs.json +3 -0
- package/src/gdskills/bundled/stacks/python/governance/eval.json +1758 -0
- package/src/gdskills/bundled/stacks/python/governance/scout.json +34 -0
- package/src/gdskills/bundled/stacks/python/pack.json +41 -0
- package/src/gdskills/bundled/stacks/python/rules/coding-style.mdc +63 -0
- package/src/gdskills/bundled/stacks/python/rules/patterns.mdc +88 -0
- package/src/gdskills/bundled/stacks/python/rules/security.mdc +84 -0
- package/src/gdskills/bundled/stacks/python/rules/testing.mdc +77 -0
- package/src/gdskills/bundled/stacks/python/skills/python-build-fix/SKILL.md +144 -0
- package/src/gdskills/bundled/stacks/python/skills/python-build-fix/evals.json +74 -0
- package/src/gdskills/bundled/stacks/python/skills/python-code-review/SKILL.md +155 -0
- package/src/gdskills/bundled/stacks/python/skills/python-code-review/evals.json +72 -0
- package/src/gdskills/bundled/stacks/python/skills/python-implementation/SKILL.md +143 -0
- package/src/gdskills/bundled/stacks/python/skills/python-implementation/evals.json +78 -0
- package/src/gdskills/bundled/stacks/python/skills/python-testing/SKILL.md +132 -0
- package/src/gdskills/bundled/stacks/python/skills/python-testing/evals.json +73 -0
- package/src/gdskills/bundled/stacks/react/agent-refs.json +4 -0
- package/src/gdskills/bundled/stacks/react/governance/eval.json +2188 -0
- package/src/gdskills/bundled/stacks/react/governance/scout.json +40 -0
- package/src/gdskills/bundled/stacks/react/pack.json +42 -0
- package/src/gdskills/bundled/stacks/react/rules/coding-style.mdc +58 -0
- package/src/gdskills/bundled/stacks/react/rules/patterns.mdc +79 -0
- package/src/gdskills/bundled/stacks/react/rules/security.mdc +70 -0
- package/src/gdskills/bundled/stacks/react/rules/testing.mdc +60 -0
- package/src/gdskills/bundled/stacks/react/skills/react-build-fix/SKILL.md +139 -0
- package/src/gdskills/bundled/stacks/react/skills/react-build-fix/evals.json +72 -0
- package/src/gdskills/bundled/stacks/react/skills/react-code-review/SKILL.md +148 -0
- package/src/gdskills/bundled/stacks/react/skills/react-code-review/evals.json +74 -0
- package/src/gdskills/bundled/stacks/react/skills/react-implementation/SKILL.md +140 -0
- package/src/gdskills/bundled/stacks/react/skills/react-implementation/evals.json +74 -0
- package/src/gdskills/bundled/stacks/react/skills/react-testing/SKILL.md +142 -0
- package/src/gdskills/bundled/stacks/react/skills/react-testing/evals.json +83 -0
- package/src/gdskills/bundled/stacks/react/skills/react-upgrade-migration/SKILL.md +155 -0
- package/src/gdskills/bundled/stacks/react/skills/react-upgrade-migration/evals.json +74 -0
- package/src/gdskills/bundled/stacks/ts-js-node/agent-refs.json +4 -0
- package/src/gdskills/bundled/stacks/ts-js-node/governance/eval.json +2155 -0
- package/src/gdskills/bundled/stacks/ts-js-node/governance/scout.json +40 -0
- package/src/gdskills/bundled/stacks/ts-js-node/pack.json +41 -0
- package/src/gdskills/bundled/stacks/ts-js-node/rules/coding-style.mdc +73 -0
- package/src/gdskills/bundled/stacks/ts-js-node/rules/patterns.mdc +61 -0
- package/src/gdskills/bundled/stacks/ts-js-node/rules/security.mdc +71 -0
- package/src/gdskills/bundled/stacks/ts-js-node/rules/testing.mdc +63 -0
- package/src/gdskills/bundled/stacks/ts-js-node/skills/nodejs-build-fix/SKILL.md +137 -0
- package/src/gdskills/bundled/stacks/ts-js-node/skills/nodejs-build-fix/evals.json +73 -0
- package/src/gdskills/bundled/stacks/ts-js-node/skills/nodejs-code-review/SKILL.md +124 -0
- package/src/gdskills/bundled/stacks/ts-js-node/skills/nodejs-code-review/evals.json +74 -0
- package/src/gdskills/bundled/stacks/ts-js-node/skills/nodejs-esm-migration/SKILL.md +152 -0
- package/src/gdskills/bundled/stacks/ts-js-node/skills/nodejs-esm-migration/evals.json +71 -0
- package/src/gdskills/bundled/stacks/ts-js-node/skills/nodejs-implementation/SKILL.md +127 -0
- package/src/gdskills/bundled/stacks/ts-js-node/skills/nodejs-implementation/evals.json +72 -0
- package/src/gdskills/bundled/stacks/ts-js-node/skills/nodejs-testing/SKILL.md +134 -0
- package/src/gdskills/bundled/stacks/ts-js-node/skills/nodejs-testing/evals.json +70 -0
|
@@ -13,7 +13,7 @@ triggers:
|
|
|
13
13
|
- "review --legacy-profiles"
|
|
14
14
|
metadata:
|
|
15
15
|
author: "MrCipherSmith"
|
|
16
|
-
version: "1.
|
|
16
|
+
version: "1.10.0"
|
|
17
17
|
category: "review"
|
|
18
18
|
compatible_harnesses: "cursor,codex,zed,opencode,claude"
|
|
19
19
|
license: "MIT"
|
|
@@ -1551,92 +1551,67 @@ When writing review report metadata or a PR comment:
|
|
|
1551
1551
|
STATUS: DONE | DONE_WITH_CONCERNS
|
|
1552
1552
|
```
|
|
1553
1553
|
|
|
1554
|
-
`DONE` — no blockers or majors
|
|
1555
|
-
`DONE_WITH_CONCERNS` — one or more blocker or major findings
|
|
1554
|
+
`DONE` — no blockers or majors in the changed code.
|
|
1555
|
+
`DONE_WITH_CONCERNS` — one or more blocker or major findings in the changed code.
|
|
1556
|
+
|
|
1557
|
+
The machine `verdict` is unchanged (`APPROVE`, `APPROVE_WITH_SUGGESTIONS`,
|
|
1558
|
+
`REQUEST_CHANGES`). The prose does not print those tokens. It prints the line
|
|
1559
|
+
in `templates/review-report.md`: `Changes requested` or `No blockers, merge-ready`.
|
|
1560
|
+
|
|
1561
|
+
Render the human report from that file. Do not invent a second skeleton here.
|
|
1556
1562
|
|
|
1557
1563
|
```markdown
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
## Verdict: APPROVE | APPROVE_WITH_SUGGESTIONS | REQUEST_CHANGES
|
|
1561
|
-
<!-- APPROVE: zero blockers/majors. APPROVE_WITH_SUGGESTIONS: minors/info only.
|
|
1562
|
-
REQUEST_CHANGES: one or more blocker or major. -->
|
|
1563
|
-
|
|
1564
|
-
## Summary
|
|
1565
|
-
<2-4 sentences: what the change does, overall code health, key concerns.>
|
|
1566
|
-
|
|
1567
|
-
## Review Scope
|
|
1568
|
-
- Branch: `<BRANCH>`
|
|
1569
|
-
- Parent ref: `<PARENT>`
|
|
1570
|
-
- Merge-base: `<BASE_SHA>`
|
|
1571
|
-
- Scope mode: `<default-with-uncommitted | explicit-hash-range>`
|
|
1572
|
-
- Reviewers dispatched: <comma-separated list>
|
|
1573
|
-
- Changed files: <count>
|
|
1574
|
-
- Context mode: `<none | light | full>`
|
|
1575
|
-
- Model strategy: `<ask | adaptive>`
|
|
1576
|
-
- Current model: `<actual current model id/name, or unknown>`
|
|
1577
|
-
- Model assignment: `<per-reviewer tier/model from each dispatch's \`model\` block | unsupported>`
|
|
1578
|
-
- Token budget: `<used/limit if known; omissions count>`
|
|
1579
|
-
|
|
1580
|
-
## Stats
|
|
1581
|
-
- blocker: N
|
|
1582
|
-
- major: N
|
|
1583
|
-
- minor: N
|
|
1584
|
-
- info: N
|
|
1564
|
+
**Changes requested — 1 Blocker, 2 Major, 4 Minor, 1 question.** Reviewed `<head>` against `<base>` (round N). <what holds, and where the risk is.>
|
|
1585
1565
|
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1611
|
-
reviewer
|
|
1612
|
-
|
|
1613
|
-
## Positive Notes
|
|
1614
|
-
<Optional. Highlight things done well. Keep brief.>
|
|
1566
|
+
### Blocker
|
|
1567
|
+
**F-001. <one-sentence claim>.** `path/to/file.ts:line`, in the diff.
|
|
1568
|
+
<proof: traced path, probe, or failing scenario>
|
|
1569
|
+
Fix: <concrete>
|
|
1570
|
+
|
|
1571
|
+
### Major
|
|
1572
|
+
**F-002. <one-sentence claim>.** `path/to/file.ts:line`, pre-existing — render under Pre-existing instead when location_class says so.
|
|
1573
|
+
|
|
1574
|
+
### Minor
|
|
1575
|
+
- **F-010. <claim>.** `path:line`, in the diff — <proof and fix, one to three sentences>.
|
|
1576
|
+
|
|
1577
|
+
### Questions
|
|
1578
|
+
1. <an info finding that needs an author answer; other info is not published>
|
|
1579
|
+
|
|
1580
|
+
### Pre-existing (not blocking)
|
|
1581
|
+
- **F-020. <claim>.** `path:line` — <why it is out of this diff>
|
|
1582
|
+
|
|
1583
|
+
### Verified clean
|
|
1584
|
+
- <what was checked> — <how>
|
|
1585
|
+
|
|
1586
|
+
### How this review was run
|
|
1587
|
+
- **Run by:** @<gh-login> with `review-orchestrator`
|
|
1588
|
+
- **Scope:** `<base>..<head>`, round N, PR #N
|
|
1589
|
+
- **Orchestrator:** `review-orchestrator`
|
|
1590
|
+
- **<actual model name>:** <reviewers on that model>
|
|
1591
|
+
- **Not run:** <reviewer — reason>
|
|
1592
|
+
- **Verification:** <mode>; confirmed N, refuted N, unverifiable N, unverified N
|
|
1615
1593
|
```
|
|
1616
1594
|
|
|
1617
|
-
|
|
1595
|
+
Pick the domain file the same way reviewers are picked: frontend scope, or a
|
|
1596
|
+
fullstack / paired PR, reads `templates/pr-comment-frontend.md`. Backend-only
|
|
1597
|
+
reads `templates/pr-comment-backend.md`. A paired PR always uses the frontend
|
|
1598
|
+
file and must include the wire-contract line.
|
|
1618
1599
|
|
|
1619
|
-
|
|
1620
|
-
same report" is a virtue; it tells a later round nothing, because no round was
|
|
1621
|
-
going to claim otherwise. "The drift bar cannot contradict the drift badge —
|
|
1622
|
-
`schema-drift-table.ts:61` always seeds `ddl` and `distributed` is a primitive
|
|
1623
|
-
boolean that is always serialized, so a backend match implies a `ddlTextDiffers`
|
|
1624
|
-
match" is a **retired hypothesis**: it names the bug that was hunted and the fact
|
|
1625
|
-
that kills it.
|
|
1600
|
+
## Stage counts
|
|
1626
1601
|
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
on.
|
|
1602
|
+
Required in **How this review was run**, copied from `scope.md`, not re-counted
|
|
1603
|
+
by hand. State what each stage removed. Never state it as a precision
|
|
1604
|
+
improvement: no precision baseline exists to improve on. The line carries
|
|
1605
|
+
`verification_mode` (`off | annotate | filter`), confirmed / refuted /
|
|
1606
|
+
unverifiable / unverified, and retained.
|
|
1633
1607
|
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
code, and should be asked once what it examined.
|
|
1608
|
+
`## Checked and cleared` is now **Verified clean**. Same rule: a hypothesis
|
|
1609
|
+
that was tested and died, with the evidence, not a list of virtues. There is
|
|
1610
|
+
no Positive Notes section. A compliment is not a result.
|
|
1638
1611
|
|
|
1639
|
-
|
|
1612
|
+
Tables: counts, ids, `file:line`, statuses, before/after, pass/fail only. A
|
|
1613
|
+
finding is a paragraph or a list item. A cell longer than about ten words is
|
|
1614
|
+
not a table cell.
|
|
1640
1615
|
|
|
1641
1616
|
## Skill Learning Handoff
|
|
1642
1617
|
|
|
@@ -1668,188 +1643,41 @@ the orchestrator's step.
|
|
|
1668
1643
|
|
|
1669
1644
|
## PR Review Report Publication
|
|
1670
1645
|
|
|
1671
|
-
When the review target is a GitHub pull request, ask whether to publish
|
|
1672
|
-
|
|
1673
|
-
Ask before publishing unless `publish_pr_review_report` was explicitly set by automation settings:
|
|
1646
|
+
When the review target is a GitHub pull request, ask whether to publish after
|
|
1647
|
+
the report exists, unless `publish_pr_review_report` is already set:
|
|
1674
1648
|
|
|
1675
1649
|
```text
|
|
1676
1650
|
Publish this review report to the PR?
|
|
1677
1651
|
|
|
1678
|
-
A)
|
|
1679
|
-
B)
|
|
1652
|
+
A) PR comment only
|
|
1653
|
+
B) PR comment + follow-up file (recommended when a fix round will follow)
|
|
1680
1654
|
C) Do not publish
|
|
1681
1655
|
|
|
1682
1656
|
> pick a letter (default: C)
|
|
1683
1657
|
```
|
|
1684
1658
|
|
|
1685
|
-
|
|
1686
|
-
- `publish_pr_review_report: comment` or legacy `true` -> publish the concise PR comment only.
|
|
1687
|
-
- `publish_pr_review_report: comment-and-ai-artifact` -> publish the concise PR comment and generate the detailed AI markdown artifact.
|
|
1688
|
-
- `publish_pr_review_report: none` or legacy `false` -> do not publish.
|
|
1689
|
-
|
|
1690
|
-
**Default:** do not publish without explicit confirmation. If no PR number can be resolved, skip publication and state that no PR target was available.
|
|
1691
|
-
|
|
1692
|
-
### Concise PR Comment
|
|
1693
|
-
|
|
1694
|
-
The visible PR comment is for humans. It must be written in English only and stay
|
|
1695
|
-
concise, under the brevity rule above: **the summary is at most two sentences and
|
|
1696
|
-
carries a link to the artifact holding the detail.**
|
|
1697
|
-
|
|
1698
|
-
The finding rows below are a bounded exception, not a licence: they exist because
|
|
1699
|
-
a reviewer scanning a PR needs the blockers in front of them. Keep them to the
|
|
1700
|
-
`blocker` and `major` rows; everything at `minor` or below goes behind the
|
|
1701
|
-
`<details>` fold or, better, into the AI artifact and is linked. The full findings
|
|
1702
|
-
set, the round history and the reasoning belong in the flow package — pasting them
|
|
1703
|
-
here is the failure this rule names.
|
|
1704
|
-
|
|
1705
|
-
```markdown
|
|
1706
|
-
## AI Review Report
|
|
1707
|
-
|
|
1708
|
-
**Verdict:** REQUEST_CHANGES
|
|
1709
|
-
**Summary:** At most two sentences: the overall risk and the main merge blocker. Detail: <link to the AI artifact or the flow package>.
|
|
1710
|
-
|
|
1711
|
-
| Severity | Area | Finding | Suggested Fix | Owner |
|
|
1712
|
-
|---|---|---|---|---|
|
|
1713
|
-
| blocker | `src/file.ts:42` | What is broken and why it matters. | Concrete fix direction, not a vague instruction. | author |
|
|
1714
|
-
|
|
1715
|
-
<details>
|
|
1716
|
-
<summary>Minor / info findings</summary>
|
|
1717
|
-
|
|
1718
|
-
| Severity | Area | Finding | Suggested Fix |
|
|
1719
|
-
|---|---|---|---|
|
|
1720
|
-
| minor | `src/other.ts:10` | ... | ... |
|
|
1721
|
-
|
|
1722
|
-
</details>
|
|
1723
|
-
|
|
1724
|
-
### Meta
|
|
1725
|
-
| Field | Value |
|
|
1726
|
-
|---|---|
|
|
1727
|
-
| Orchestrator | `review-orchestrator` |
|
|
1728
|
-
| Model | `<actual current model id/name, or unknown; never inherit or unsupported>` |
|
|
1729
|
-
| Model strategy | `<ask | adaptive>` |
|
|
1730
|
-
| Model assignment | `<per-reviewer tier/model from each dispatch's \`model\` block | unsupported>` |
|
|
1731
|
-
| Agents run | `<reviewers actually dispatched, including fallback runtimes when used>` |
|
|
1732
|
-
| Available reviewers | `<all reviewers considered by the orchestrator for this repository/runtime, grouped briefly as generic/convention/project/legacy when useful>` |
|
|
1733
|
-
| Skipped reviewers | `<reviewers not dispatched with short reasons, e.g. no matching files, optional group not selected, unavailable native agent, PR number missing>` |
|
|
1734
|
-
| Selection basis | `<auto-detected scope, explicit flags, user-selected optional groups, and why this reviewer set was chosen>` |
|
|
1735
|
-
| Fallback/blocked reviewers | `<reviewers run via fallback or blocked because native agent/skill was unavailable, otherwise none>` |
|
|
1736
|
-
| Scope | `<PR #N, base..head, merge-base>` |
|
|
1737
|
-
| Commit | `<HEAD sha>` |
|
|
1738
|
-
| Context | `<job/context path if provided, otherwise none>` |
|
|
1739
|
-
| AI artifact | `<markdown link or file path to the detailed AI report when generated, otherwise none>` |
|
|
1740
|
-
| AI artifact description | `<one concise human-readable sentence explaining that the linked markdown file contains detailed findings, fix guidance, patch guidance, regression coverage, validation plan, and follow-up agent context>` |
|
|
1741
|
-
| Reviewed at | `<UTC timestamp>` |
|
|
1742
|
-
```
|
|
1743
|
-
|
|
1744
|
-
### Detailed AI Markdown Artifact
|
|
1745
|
-
|
|
1746
|
-
When the user chooses option B, generate a separate English-only markdown artifact for AI follow-up work. Prefer a repository-local job/review path such as:
|
|
1747
|
-
|
|
1748
|
-
```text
|
|
1749
|
-
jobs/reviews/pr-<number>/review-ai-report.md
|
|
1750
|
-
```
|
|
1751
|
-
|
|
1752
|
-
If the review is running inside `job-orchestrator`, write it under the active job docs, for example:
|
|
1753
|
-
|
|
1754
|
-
```text
|
|
1755
|
-
.metaproject/jobs/<job-name>/ai/review-ai-report.md
|
|
1756
|
-
```
|
|
1757
|
-
|
|
1758
|
-
If the environment provides an external artifact mechanism, attach or upload that markdown file and put the link/path in the concise PR comment `AI artifact` meta row. If no attachment/upload mechanism exists, keep the file path in the comment and in `review_context.review_plan.publication_plan.ai_artifact_path`.
|
|
1759
|
-
|
|
1760
|
-
The concise PR comment must also include an `AI artifact description` meta row whenever an AI artifact is generated. The description is for human readers and must explain what was added and what the file contains, for example: `Detailed AI follow-up report with expanded findings, fix guidance, illustrative patch guidance, Gherkin regression coverage, validation plan, and context for follow-up agents.`
|
|
1761
|
-
|
|
1762
|
-
The AI artifact must use this structure:
|
|
1763
|
-
|
|
1764
|
-
```markdown
|
|
1765
|
-
---
|
|
1766
|
-
review_run_id: <stable id, e.g. pr-5462-2026-06-13T10-22-00Z>
|
|
1767
|
-
orchestrator: review-orchestrator
|
|
1768
|
-
verdict: <APPROVE | APPROVE_WITH_SUGGESTIONS | REQUEST_CHANGES>
|
|
1769
|
-
context_mode: <none | light | full>
|
|
1770
|
-
model_strategy: <ask | adaptive>
|
|
1771
|
-
current_model: <actual current model id/name, or unknown>
|
|
1772
|
-
model_assignment: <per-reviewer tier/model from each dispatch's `model` block | unsupported>
|
|
1773
|
-
agents:
|
|
1774
|
-
- <reviewer>
|
|
1775
|
-
scope:
|
|
1776
|
-
pr: <number or null>
|
|
1777
|
-
base: <base sha/ref>
|
|
1778
|
-
head: <head sha/ref>
|
|
1779
|
-
files_changed: <count>
|
|
1780
|
-
generated_at: <UTC timestamp>
|
|
1781
|
-
---
|
|
1782
|
-
|
|
1783
|
-
# AI Review Report
|
|
1784
|
-
|
|
1785
|
-
## Executive Summary
|
|
1786
|
-
<Short machine-readable summary of merge risk and required fix order.>
|
|
1787
|
-
|
|
1788
|
-
## Review Context
|
|
1789
|
-
<Bounded description of diff scope, requirements, omitted context, and assumptions.>
|
|
1790
|
-
|
|
1791
|
-
## Findings
|
|
1792
|
-
|
|
1793
|
-
### F-NNN: <title>
|
|
1794
|
-
|
|
1795
|
-
- Severity: blocker | major | minor | info
|
|
1796
|
-
- Reviewer: <reviewer>
|
|
1797
|
-
- File: `path/to/file.ts`
|
|
1798
|
-
- Lines: <line or range>
|
|
1799
|
-
- Confidence: high | medium | low
|
|
1800
|
-
- Status: open
|
|
1801
|
-
|
|
1802
|
-
Problem:
|
|
1803
|
-
<Detailed explanation of what is wrong.>
|
|
1804
|
-
|
|
1805
|
-
Why it matters:
|
|
1806
|
-
<Correctness, safety, maintainability, performance, or UX impact.>
|
|
1807
|
-
|
|
1808
|
-
Evidence:
|
|
1809
|
-
<Specific code references or behavior observed.>
|
|
1810
|
-
|
|
1811
|
-
Suggested fix:
|
|
1812
|
-
<Detailed fix plan with steps.>
|
|
1813
|
-
|
|
1814
|
-
Patch guidance:
|
|
1815
|
-
```diff
|
|
1816
|
-
<Optional illustrative diff. Keep it minimal and clearly mark if illustrative.>
|
|
1817
|
-
```
|
|
1818
|
-
|
|
1819
|
-
Regression coverage:
|
|
1820
|
-
```gherkin
|
|
1821
|
-
Feature: <feature or invariant>
|
|
1659
|
+
Automation values, names unchanged:
|
|
1822
1660
|
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
Then <expected result>
|
|
1827
|
-
```
|
|
1661
|
+
- `comment` or legacy `true` -> the PR comment only.
|
|
1662
|
+
- `comment-and-ai-artifact` -> the PR comment plus the follow-up file.
|
|
1663
|
+
- `none` or legacy `false` -> do not publish.
|
|
1828
1664
|
|
|
1829
|
-
|
|
1830
|
-
1. <Blocker/major fix sequencing with dependencies.>
|
|
1665
|
+
Default is do not publish. No resolvable PR number means skip and say so.
|
|
1831
1666
|
|
|
1832
|
-
|
|
1833
|
-
|
|
1667
|
+
The comment is the report in `templates/review-report.md`, English, with the
|
|
1668
|
+
domain file chosen above. It does not use a tool heading, a finding table, or
|
|
1669
|
+
a meta table. It does not carry a co-author line, a `Generated with` trailer,
|
|
1670
|
+
or any sentence that names a vendor or a product as the author. Say who ran
|
|
1671
|
+
the orchestrator and which reviewers ran; do not sign the comment as them.
|
|
1834
1672
|
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
Formatting rules for PR comments and AI artifacts:
|
|
1840
|
-
- English only, regardless of chat language or reviewer output language.
|
|
1841
|
-
- Keep the visible comment concise: max 10 blocker/major rows before `<details>`.
|
|
1842
|
-
- Put minor/info findings under `<details>` unless there are no higher severity findings.
|
|
1843
|
-
- Every blocker/major row must include a concrete suggested fix.
|
|
1844
|
-
- Include enough metadata to reproduce the review, but do not include internal prompts, raw logs, secrets, or unrelated local paths.
|
|
1845
|
-
- The PR comment metadata must distinguish `Agents run` from `Available reviewers` and `Skipped reviewers`; never use a single `Agents` row that hides skipped or unavailable reviewers.
|
|
1846
|
-
- `Skipped reviewers` must include short reasons from `review_context.routing.reasons`, `review_context.review_plan.skipped`, and dispatch/runtime compatibility checks.
|
|
1847
|
-
- If the list is long, keep `Agents run` complete and summarize `Available reviewers` / `Skipped reviewers` by group with counts plus notable names; put full details in the AI artifact when one is generated.
|
|
1848
|
-
- When `comment-and-ai-artifact` is selected, the PR comment meta section must include both `AI artifact` and `AI artifact description`; do not rely on the link alone.
|
|
1849
|
-
- In the metadata table, `Model` must be the actual model id/name. Put `unsupported`, `adaptive`, or `ask` under `Model strategy` / `Model assignment`, not under `Model`.
|
|
1850
|
-
- If posting via CLI, write the body to a temp file and use `gh pr comment <pr-number> --body-file <file>`; never inline a large heredoc into shell history.
|
|
1673
|
+
The follow-up file path and the metadata rules (real model names, Run vs Not
|
|
1674
|
+
run, no `adaptive` in the model slot) live in that same template. Write the
|
|
1675
|
+
body to a temp file and post with `gh pr comment <n> --body-file <file>`.
|
|
1851
1676
|
|
|
1852
|
-
|
|
1677
|
+
Re-read head and the thread immediately before posting. If head moved, re-check
|
|
1678
|
+
the findings against the new head and name the commits that were not reviewed.
|
|
1679
|
+
Do not post a finding another reviewer already filed on this head; if yours
|
|
1680
|
+
extends theirs, cite theirs.
|
|
1853
1681
|
|
|
1854
1682
|
## Job Context Awareness
|
|
1855
1683
|
|
|
@@ -65,6 +65,25 @@
|
|
|
65
65
|
"reviewed_at": {
|
|
66
66
|
"type": "string"
|
|
67
67
|
},
|
|
68
|
+
"publication": {
|
|
69
|
+
"type": "object",
|
|
70
|
+
"description": "How the prose report was rendered. Does not replace verdict or status.",
|
|
71
|
+
"properties": {
|
|
72
|
+
"template": {
|
|
73
|
+
"type": "string",
|
|
74
|
+
"enum": ["frontend", "backend"]
|
|
75
|
+
},
|
|
76
|
+
"visible_verdict": {
|
|
77
|
+
"type": "string",
|
|
78
|
+
"enum": ["changes-requested", "merge-ready"]
|
|
79
|
+
},
|
|
80
|
+
"questions": {
|
|
81
|
+
"type": "integer",
|
|
82
|
+
"minimum": 0
|
|
83
|
+
}
|
|
84
|
+
},
|
|
85
|
+
"additionalProperties": false
|
|
86
|
+
},
|
|
68
87
|
"token_policy": {
|
|
69
88
|
"type": "object",
|
|
70
89
|
"additionalProperties": true
|
|
@@ -121,6 +121,16 @@
|
|
|
121
121
|
"type": "boolean",
|
|
122
122
|
"default": false
|
|
123
123
|
},
|
|
124
|
+
"location_class": {
|
|
125
|
+
"type": "string",
|
|
126
|
+
"enum": ["in-diff", "pre-existing", "pr-process"],
|
|
127
|
+
"description": "Where the finding sits, for rendering only. in-diff counts toward the merge verdict. pre-existing does not block. pr-process renders under Scope, not as a code finding. Absent means in-diff."
|
|
128
|
+
},
|
|
129
|
+
"publication": {
|
|
130
|
+
"type": "string",
|
|
131
|
+
"enum": ["finding", "question", "omit"],
|
|
132
|
+
"description": "How an info finding is shown. question renders under Questions. omit stays in the keryx:findings block and is not published as a finding. Absent means finding. Never changes severity."
|
|
133
|
+
},
|
|
124
134
|
"class_scope": {
|
|
125
135
|
"title": "Every site of this shape, and how the set was derived",
|
|
126
136
|
"description": "A finding anchored to one file:line is a claim about one site. Repeatedly, a fix repaired that site and left its siblings — one writer of five, one operator instruction of four, six readers of eight — and the next review round found them. Required for blocker and major; optional below, because enumerating the class for every info finding is theatre. Kept identical to src/gdskills/contracts/review-finding.schema.json, which is stricter (additionalProperties: false) and would reject this property if it were declared only here.",
|
|
@@ -190,6 +190,11 @@
|
|
|
190
190
|
"null"
|
|
191
191
|
],
|
|
192
192
|
"description": "What the fix offered as proof: the test added, the mutation that went red, the command run."
|
|
193
|
+
},
|
|
194
|
+
"prior_findings_status": {
|
|
195
|
+
"type": "string",
|
|
196
|
+
"enum": ["open", "closed", "partial", "regressed", "withdrawn"],
|
|
197
|
+
"description": "What this round concluded about the prior finding, after checking the code. Distinct from claimed_disposition, which is what the fix asserted. Optional; the report still owes one line per prior finding."
|
|
193
198
|
}
|
|
194
199
|
},
|
|
195
200
|
"additionalProperties": true
|
package/src/gdskills/bundled/skills/review/review-orchestrator/templates/pr-comment-backend.md
ADDED
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
# PR comment — backend
|
|
2
|
+
|
|
3
|
+
Use when the scope is backend and there is no frontend twin in this PR.
|
|
4
|
+
A fullstack or paired change uses `templates/pr-comment-frontend.md` instead,
|
|
5
|
+
and still records the wire contract there.
|
|
6
|
+
|
|
7
|
+
Skeleton: `templates/review-report.md`. Render a Verified-clean bullet only
|
|
8
|
+
if that check was actually run.
|
|
9
|
+
|
|
10
|
+
## Verified clean — render only what was checked
|
|
11
|
+
|
|
12
|
+
API and DTO
|
|
13
|
+
|
|
14
|
+
- The contract change is backward compatible, or the break is named and the
|
|
15
|
+
consumer PR is linked with a deploy order.
|
|
16
|
+
- Input is validated at the boundary, not trusted from the caller.
|
|
17
|
+
- Error codes match what the client branches on.
|
|
18
|
+
- The frontend consumer was read, not assumed.
|
|
19
|
+
|
|
20
|
+
Data
|
|
21
|
+
|
|
22
|
+
- Migrations reverse, and the reverse was read against the volume they run on.
|
|
23
|
+
- New filters have an index, or the finding says why the scan is bounded.
|
|
24
|
+
- Writes that must be atomic sit in a transaction; the isolation level is the
|
|
25
|
+
one the invariant needs.
|
|
26
|
+
|
|
27
|
+
Security
|
|
28
|
+
|
|
29
|
+
- Every new or changed endpoint checks authz, not only authentication.
|
|
30
|
+
- Queries are scoped to tenant / case / workspace.
|
|
31
|
+
- No string-built query, no secret in a log or a fixture.
|
|
32
|
+
|
|
33
|
+
Concurrency
|
|
34
|
+
|
|
35
|
+
- A retried command is idempotent, or the finding names the double-apply.
|
|
36
|
+
- Locks have a TTL and a heartbeat, or they are not locks.
|
|
37
|
+
- Retry has a bound and backpressure; a queue has a depth limit.
|
|
38
|
+
- Cache invalidation names the writer that was checked.
|
|
39
|
+
|
|
40
|
+
Tests
|
|
41
|
+
|
|
42
|
+
- The level matches the failure mode (unit for a branch, contract for a wire
|
|
43
|
+
shape, integration for a transaction).
|
|
44
|
+
- A wire-format change has a contract test against the bytes, not the builder.
|
|
45
|
+
- A fix cites the test that failed before it and passes after it.
|
|
46
|
+
|
|
47
|
+
## Scope notes
|
|
48
|
+
|
|
49
|
+
Same as the frontend template: process remarks render under `### Scope` with
|
|
50
|
+
`location_class: pr-process`. They do not block on their own.
|
package/src/gdskills/bundled/skills/review/review-orchestrator/templates/pr-comment-frontend.md
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# PR comment — frontend
|
|
2
|
+
|
|
3
|
+
Use when the scope is frontend, or when the PR is fullstack / paired with a
|
|
4
|
+
backend PR. A paired PR uses this template and must include the wire-contract
|
|
5
|
+
line.
|
|
6
|
+
|
|
7
|
+
Skeleton: `templates/review-report.md`. This file is the Verified-clean
|
|
8
|
+
checklist. Render a bullet only if that check was actually run.
|
|
9
|
+
|
|
10
|
+
## Verified clean — render only what was checked
|
|
11
|
+
|
|
12
|
+
React / MobX
|
|
13
|
+
|
|
14
|
+
- `observer` on every component that reads an observable.
|
|
15
|
+
- `runInAction` (or an action) after every `await` that writes state.
|
|
16
|
+
- Disposers run on unmount; an async callback checks them before writing.
|
|
17
|
+
- State that outlives the view lives in the store, not in `useState`.
|
|
18
|
+
|
|
19
|
+
Vantage conventions (skip a line the repository has no rule for)
|
|
20
|
+
|
|
21
|
+
- `t()` only in render, no `defaultValue`.
|
|
22
|
+
- Arabic plurals and FSI/PDI isolates where the catalog has them.
|
|
23
|
+
- `notifyError` on failure paths; no empty `catch`.
|
|
24
|
+
- No `as`, no `any`.
|
|
25
|
+
- `Storage` wrapper, not `localStorage`.
|
|
26
|
+
- Tailwind tokens, no inline `style` for theme values.
|
|
27
|
+
- Icon-only buttons have an `aria-label`.
|
|
28
|
+
|
|
29
|
+
`src/core` boundaries
|
|
30
|
+
|
|
31
|
+
- No import from a feature into core.
|
|
32
|
+
- A vendored surface (for example `report-blocks`) has no dependency on the app.
|
|
33
|
+
|
|
34
|
+
Tests
|
|
35
|
+
|
|
36
|
+
- The test level matches the behaviour under change.
|
|
37
|
+
- Network is mocked at the boundary (MSW), not by stubbing the client method.
|
|
38
|
+
- No test that cannot fail.
|
|
39
|
+
- A new component has the three stories the repository asks for.
|
|
40
|
+
|
|
41
|
+
Wire contract — required when a paired backend PR exists
|
|
42
|
+
|
|
43
|
+
- The payload, the error codes, and the null-vs-zero defaults were read in the
|
|
44
|
+
paired PR at a pinned ref, not assumed from the consumer.
|
|
45
|
+
- Deploy order is named. If the producer is still open and must merge first,
|
|
46
|
+
that is a finding against the call site, not a note.
|
|
47
|
+
|
|
48
|
+
## Scope notes
|
|
49
|
+
|
|
50
|
+
A process remark (one task, size, missing Why / In scope / Out of scope) is
|
|
51
|
+
`location_class: pr-process` and renders under `### Scope`, not as a code
|
|
52
|
+
finding. Merge state is an input to the verdict, not a finding.
|