@starlein/paperclip-plugin-company-wizard 0.3.23 → 0.4.1
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/CHANGELOG.md +36 -0
- package/README.md +18 -13
- package/dist/manifest.js +1 -6
- package/dist/manifest.js.map +2 -2
- package/dist/ui/index.css +3 -0
- package/dist/ui/index.css.map +2 -2
- package/dist/ui/index.js +59 -30
- package/dist/ui/index.js.map +3 -3
- package/dist/worker.js +315 -86
- package/dist/worker.js.map +3 -3
- package/package.json +1 -1
- package/templates/ai-wizard/config-format.md +4 -4
- package/templates/ai-wizard/interview-system.md +3 -3
- package/templates/ai-wizard/single-shot-system.md +3 -3
- package/templates/bootstrap-instructions.md +3 -3
- package/templates/modules/architecture-plan/agents/ui-designer/skills/design-system.md +1 -1
- package/templates/modules/auto-assign/agents/ceo/heartbeat-section.md +2 -8
- package/templates/modules/auto-assign/agents/product-owner/heartbeat-section.md +2 -9
- package/templates/modules/auto-assign/module.meta.json +1 -1
- package/templates/modules/auto-assign/skills/auto-assign.md +18 -15
- package/templates/modules/backlog/agents/ceo/heartbeat-section.md +2 -9
- package/templates/modules/backlog/agents/product-owner/heartbeat-section.md +2 -14
- package/templates/modules/backlog/module.meta.json +1 -1
- package/templates/modules/backlog/skills/backlog-health.md +20 -21
- package/templates/modules/codebase-onboarding/skills/codebase-audit.md +29 -30
- package/templates/modules/github-repo/agents/engineer/skills/git-workflow.md +11 -7
- package/templates/modules/github-repo/docs/git-workflow.md +10 -6
- package/templates/modules/hiring-review/skills/hiring-review.md +40 -16
- package/templates/modules/market-analysis/agents/ux-researcher/skills/market-analysis.md +1 -1
- package/templates/modules/pr-review/README.md +13 -13
- package/templates/modules/pr-review/agents/code-reviewer/skills/code-review.md +16 -21
- package/templates/modules/pr-review/agents/devops/skills/infra-review.md +1 -1
- package/templates/modules/pr-review/agents/engineer/skills/pr-workflow.md +17 -11
- package/templates/modules/pr-review/agents/product-owner/skills/product-review.md +1 -1
- package/templates/modules/pr-review/agents/qa/skills/qa-review.md +40 -19
- package/templates/modules/pr-review/agents/security-engineer/skills/pr-security-review.md +27 -0
- package/templates/modules/pr-review/agents/ui-designer/skills/design-review.md +1 -1
- package/templates/modules/pr-review/agents/ux-researcher/skills/ux-review.md +1 -1
- package/templates/modules/pr-review/docs/pr-conventions.md +35 -23
- package/templates/modules/pr-review/module.meta.json +4 -3
- package/templates/modules/stall-detection/README.md +8 -8
- package/templates/modules/stall-detection/agents/ceo/heartbeat-section.md +2 -11
- package/templates/modules/stall-detection/agents/ceo/skills/stall-detection.md +22 -13
- package/templates/modules/stall-detection/module.meta.json +1 -1
- package/templates/modules/triage/skills/issue-triage.md +20 -33
- package/templates/roles/audio-designer/HEARTBEAT.md +37 -21
- package/templates/roles/ceo/HEARTBEAT.md +34 -56
- package/templates/roles/cmo/HEARTBEAT.md +37 -21
- package/templates/roles/code-reviewer/AGENTS.md +1 -1
- package/templates/roles/code-reviewer/HEARTBEAT.md +39 -19
- package/templates/roles/cto/HEARTBEAT.md +33 -25
- package/templates/roles/customer-success/HEARTBEAT.md +39 -19
- package/templates/roles/devops/HEARTBEAT.md +36 -25
- package/templates/roles/engineer/AGENTS.md +27 -9
- package/templates/roles/engineer/HEARTBEAT.md +35 -21
- package/templates/roles/game-artist/HEARTBEAT.md +37 -21
- package/templates/roles/game-designer/HEARTBEAT.md +37 -21
- package/templates/roles/level-designer/HEARTBEAT.md +37 -21
- package/templates/roles/product-owner/AGENTS.md +24 -8
- package/templates/roles/product-owner/HEARTBEAT.md +37 -19
- package/templates/roles/qa/AGENTS.md +26 -11
- package/templates/roles/qa/HEARTBEAT.md +37 -21
- package/templates/roles/security-engineer/AGENTS.md +21 -23
- package/templates/roles/security-engineer/HEARTBEAT.md +39 -19
- package/templates/roles/technical-writer/HEARTBEAT.md +39 -18
- package/templates/roles/ui-designer/AGENTS.md +26 -9
- package/templates/roles/ui-designer/HEARTBEAT.md +37 -21
- package/templates/roles/ux-researcher/HEARTBEAT.md +37 -21
|
@@ -1,30 +1,25 @@
|
|
|
1
|
-
# Skill: Code Review
|
|
1
|
+
# Skill: Code Review (advisory)
|
|
2
2
|
|
|
3
|
-
You
|
|
3
|
+
You provide an **advisory, non-binding** code review. You are *not a merge gate*: the merge is gated by executed verification — green CI, or QA running the tests (see `docs/pr-conventions.md`). Your value is a second pair of eyes on correctness, clarity, and simplicity that automated checks miss.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## What to look for
|
|
6
6
|
|
|
7
|
-
1. **Correctness** — Does the code do what
|
|
8
|
-
2. **
|
|
9
|
-
3. **
|
|
10
|
-
4. **
|
|
11
|
-
5. **
|
|
12
|
-
6. **Performance** — No obvious N+1 queries, unbounded loops, or unnecessary allocations. Flag only clear issues, not micro-optimizations.
|
|
13
|
-
7. **Test coverage** — Are new code paths tested? Are tests meaningful (test behavior, not implementation)?
|
|
7
|
+
1. **Correctness** — Does the code do what the PR claims? Are edge cases handled? Does the logic match the stated intent?
|
|
8
|
+
2. **Simplicity** — Is this the simplest solution that works? Could anything be removed without losing functionality?
|
|
9
|
+
3. **Clarity** — Naming, structure, comments. Will the next reader understand this?
|
|
10
|
+
4. **Security smells** — Obvious injection, exposed secrets, missing validation at boundaries. Defer deep security review to the Security Engineer when the change is security-relevant.
|
|
11
|
+
5. **Dead code** — Commented-out blocks, unused branches.
|
|
14
12
|
|
|
15
|
-
## How to
|
|
13
|
+
## How to comment
|
|
16
14
|
|
|
17
|
-
1. When
|
|
18
|
-
2.
|
|
19
|
-
|
|
20
|
-
- **changes_requested** with specific, actionable feedback if not
|
|
21
|
-
3. Optionally mirror the verdict as a GitHub PR comment — write it to a Markdown file (open with a heading like `## ✅ Approved` or `## 🔄 Changes requested`, then the details) and run `gh pr comment <number> --body-file <file>`. Never use inline `--body "..."`: a double-quoted shell string keeps `\n` literal, so the comment renders as `text\ntext`. See `docs/pr-conventions.md` → *Posting PR Bodies & Comments*.
|
|
15
|
+
1. When the PR has a review stage assigned to you, read the diff (check it out locally if useful).
|
|
16
|
+
2. Post your feedback as a GitHub PR comment via a Markdown file: open with a heading (`## 💬 Review notes`), then specific, actionable points, and run `gh pr comment <number> --body-file <file>`. Never inline `--body "..."` — `\n` stays literal in a double-quoted shell string. See `docs/pr-conventions.md` → *Posting PR Bodies & Comments*.
|
|
17
|
+
3. If you are a participant on an advisory review stage, record your notes there too — but understand it does not gate the merge.
|
|
22
18
|
|
|
23
19
|
## Rules
|
|
24
20
|
|
|
25
21
|
- Be constructive — suggest alternatives, don't just criticize.
|
|
26
|
-
- Focus on substance over style
|
|
27
|
-
- "Looks good" is not
|
|
28
|
-
-
|
|
29
|
-
- If
|
|
30
|
-
- Your review stage verdict is the governance signal. Do not block only because GitHub rejects formal review submission from the shared PR-author credential — GitHub-native approval is optional unless a distinct non-author reviewer credential is explicitly available.
|
|
22
|
+
- Focus on substance over style; auto-formatters handle style.
|
|
23
|
+
- "Looks good" is not useful feedback. Point at what you actually examined.
|
|
24
|
+
- Raise correctness or security concerns clearly so QA / the Security Engineer / the Engineer can act on them before merge.
|
|
25
|
+
- You do not gate the merge. If something must block, it belongs to QA (tests), the Security Engineer (security-relevant), or CI.
|
|
@@ -16,7 +16,7 @@ You review PRs for infrastructure impact, performance, security, and operational
|
|
|
16
16
|
|
|
17
17
|
1. When you are the active participant of a review stage on an issue with a PR link, review the PR.
|
|
18
18
|
2. Focus on infrastructure, deployment, runtime security, observability, and rollback risk.
|
|
19
|
-
3. Record your verdict
|
|
19
|
+
3. Record your verdict through the normal issue update route for your review stage:
|
|
20
20
|
- **approved** if operationally sound
|
|
21
21
|
- **changes_requested** with specific concerns if not
|
|
22
22
|
4. Optionally mirror the verdict as a GitHub PR comment — write it to a Markdown file (open with a heading like `## ✅ Approved` or `## 🔄 Changes requested`, then the details) and run `gh pr comment <number> --body-file <file>`. Never use inline `--body "..."`: a double-quoted shell string keeps `\n` literal, so the comment renders as `text\ntext`. See `docs/pr-conventions.md` → *Posting PR Bodies & Comments*.
|
|
@@ -4,20 +4,24 @@ When this skill is active, you work in feature branches and open PRs instead of
|
|
|
4
4
|
|
|
5
5
|
## Feature Branch Flow
|
|
6
6
|
|
|
7
|
-
1.
|
|
8
|
-
2.
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
7
|
+
1. Resolve the project/worktree base ref from the issue's `heartbeat-context` / project workspace metadata before branching. Use the configured `repoRef`, `defaultRef`, or `executionWorkspacePolicy.workspaceStrategy.baseRef` exactly as Paperclip provides it. Never guess from your shell's current branch and never rewrite the configured ref to `main`, `master`, or `origin/*`.
|
|
8
|
+
2. Fetch and update the base:
|
|
9
|
+
- external: `git fetch origin`, then branch from the configured base ref
|
|
10
|
+
- local: update from the configured local branch
|
|
11
|
+
3. Create branch from that base: `git checkout -b <prefix>-<N>/<short-description> <base-ref>`
|
|
12
|
+
4. Make your changes, commit with Conventional Commits format
|
|
13
|
+
5. Push branch: `git push -u origin <branch-name>`
|
|
14
|
+
6. Open PR against the same resolved base: derive the GitHub base branch from the configured ref (for example, strip the remote prefix only when the ref is remote-tracking), write the body (PR Body Template in `docs/pr-conventions.md`) to a file, then `gh pr create --base <github-base-branch> --head <branch-name> --title "<type>: <description>" --body-file <file>`. Never inline `--body "..."` — a double-quoted shell string keeps `\n` literal and the PR renders as `text\ntext` (see *Posting PR Bodies & Comments*).
|
|
15
|
+
7. Set the originating issue's `executionPolicy` to gate the merge on review, ending with your own merge gate:
|
|
16
|
+
- One `review` stage with **QA** when a QA agent exists (test adequacy / executed verification).
|
|
17
|
+
- One `review` stage with the **Security Engineer** only when the change is security-relevant (auth, secrets, input boundaries, crypto, dependencies, infra exposure).
|
|
18
|
+
- Additional `review` stages only for domain reviewers that should block this specific change. Code Reviewer and other specialists are advisory by default unless explicitly configured as participants.
|
|
15
19
|
- An `approval` stage with the **Product Owner** as participant (always) — the product sign-off.
|
|
16
20
|
- A final `approval` stage with **yourself (the Engineer)** as participant — the **merge gate**. This stage exists so you are woken *last*, after every reviewer and the Product Owner have cleared, to perform the merge.
|
|
17
21
|
- Resolve each role to its agentId first (look up active agents), then set the policy on the issue. Include the PR link in an issue comment so reviewers can find it.
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
22
|
+
8. Move the originating issue to `in_review`.
|
|
23
|
+
9. Wait for the issue to clear its review/approval stages. Each reviewer and the Product Owner records `approved` by PATCHing the issue toward `done`, or `changes_requested` by PATCHing it back to `in_progress`; Paperclip stores the reviewer/approver decision metadata on the issue. Verdicts may be mirrored as PR comments. A `changes_requested` routes the issue back to you — address it, push to the same branch, and that stage re-runs.
|
|
24
|
+
10. When the issue reaches your final **merge gate** stage (you are the current participant and every prior stage is approved): run `gh pr merge <number> --merge`, confirm the merge landed into the configured project base, then close/archive the isolated execution workspace if one exists and close-readiness allows it. **Only after merge and workspace close/cleanup succeeds** record `approved` on your stage — that closes the issue to `done`. Never record `approved` before the merge has actually succeeded, and never set the issue to `done` with the PR still open or an execution workspace still active.
|
|
21
25
|
|
|
22
26
|
## Rules
|
|
23
27
|
|
|
@@ -26,6 +30,8 @@ When this skill is active, you work in feature branches and open PRs instead of
|
|
|
26
30
|
- Always include `Closes [PREFIX-N]` in the PR body.
|
|
27
31
|
- If a reviewer requests changes, address them, push to the same branch, and re-request review (the stage re-runs).
|
|
28
32
|
- You are the merge owner — never ask reviewers to merge.
|
|
33
|
+
- Before creating a PR or merging, verify the PR base matches the configured project/worktree base. If the base is wrong, retarget the PR before review/merge.
|
|
29
34
|
- **Your merge gate must be the last stage.** The Product Owner's `approval` is the product sign-off, not the final stage. If it were last, their verdict would auto-close the issue to `done` and you would never be woken to merge — leaving the PR open on GitHub. Always append your own merge-gate `approval` stage after the Product Owner's, and do the merge there before recording your verdict.
|
|
30
35
|
- Do not create separate child review issues and do not use @-mentions to request review; the executionPolicy stages are the governance signal.
|
|
31
36
|
- Do not wait for GitHub-native approving reviews when all agents share the same GitHub credential; GitHub rejects self-approval. The Paperclip executionPolicy stages are the required signal unless a separate non-author GitHub reviewer credential is explicitly available.
|
|
37
|
+
- If Paperclip created an isolated execution workspace for this issue, do not leave it behind. Use the current execution workspace id from `heartbeat-context`, check close-readiness, and archive it after the PR is merged and the tree is clean. If archive/cleanup is blocked, leave the issue `blocked` or `in_review` with the exact cleanup blocker instead of marking `done`. If this issue runs in the shared project workspace, do not invent isolated-worktree cleanup.
|
|
@@ -14,7 +14,7 @@ You review PRs for intent alignment, scope discipline, and acceptance criteria.
|
|
|
14
14
|
## How to Review
|
|
15
15
|
|
|
16
16
|
1. When you are the active participant of the approval stage on an issue with a PR link, review the PR against the originating issue.
|
|
17
|
-
2. Record your verdict
|
|
17
|
+
2. Record your verdict through the normal issue update route for your approval stage:
|
|
18
18
|
- **approved** if the change meets product requirements
|
|
19
19
|
- **changes_requested** with specific feedback tied to acceptance criteria
|
|
20
20
|
3. Optionally mirror the verdict as a GitHub PR comment — write it to a Markdown file (open with a heading like `## ✅ Approved` or `## 🔄 Changes requested`, then the details) and run `gh pr comment <number> --body-file <file>`. Never use inline `--body "..."`: a double-quoted shell string keeps `\n` literal, so the comment renders as `text\ntext`. See `docs/pr-conventions.md` → *Posting PR Bodies & Comments*.
|
|
@@ -1,29 +1,50 @@
|
|
|
1
1
|
# Skill: QA Review
|
|
2
2
|
|
|
3
|
-
You review
|
|
3
|
+
You are the **substantive review gate** for pull requests. Review is by *doing*, not by reading: your verdict must rest on tests that actually ran. "Looks good" is not a review.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## Two modes
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
7
|
+
**CI is configured (hard gate = CI):**
|
|
8
|
+
Your job is to ensure the tests *mean something*. Green CI on a change with no real coverage is worthless. Verify:
|
|
9
|
+
- New code paths and edge cases are covered by tests that CI runs.
|
|
10
|
+
- Tests assert behavior, not implementation.
|
|
11
|
+
- Regression risk is covered.
|
|
12
|
+
- The CI build job is green, not only the test job.
|
|
13
|
+
Record `approved` only when CI is green AND coverage is adequate. If coverage is inadequate, record `changes_requested` with the specific missing test cases — even if CI is green.
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
**No CI configured (you are the gate):**
|
|
16
|
+
There is no machine arbiter, so you run it. Check out the branch, run the full test suite and the build locally, and paste the **real command output** into your stage-record verdict. A verdict without execution output is invalid.
|
|
16
17
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
18
|
+
Replace `<branch>` with the PR branch name and substitute your project's actual test and build commands:
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
git fetch origin && git checkout <branch>
|
|
22
|
+
<the project's test command> # e.g. pnpm test, pytest, go test ./...
|
|
23
|
+
<the project's build command> # e.g. pnpm build
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
Record `approved` only if the suite and build pass and coverage is adequate; otherwise `changes_requested` with the failing output and the gaps.
|
|
27
|
+
|
|
28
|
+
## Review checklist
|
|
29
|
+
|
|
30
|
+
1. **Test coverage** — new code paths and edge cases covered?
|
|
31
|
+
2. **Regression risk** — could this break existing behavior? Is the affected area covered?
|
|
32
|
+
3. **Error handling** — failure modes handled and tested?
|
|
33
|
+
4. **Boundary conditions** — empty/null/max/concurrent inputs respected?
|
|
34
|
+
5. **Data validation** — input validated at boundaries; API contracts enforced?
|
|
35
|
+
6. **Test quality** — tests assert behavior; readable and maintainable?
|
|
36
|
+
7. **Manual test plan** — for hard-to-automate changes, is a manual plan documented in the PR?
|
|
37
|
+
|
|
38
|
+
## How to record your verdict
|
|
39
|
+
|
|
40
|
+
1. You are the active participant of a `review` stage on the issue carrying the PR link.
|
|
41
|
+
2. Record on your stage through the normal issue update route: `approved` (with the evidence — commands + results) by PATCHing toward `done`, or `changes_requested` (with specific gaps and suggested test cases) by PATCHing back to `in_progress`.
|
|
42
|
+
3. Optionally mirror the verdict as a GitHub PR comment via a Markdown file: open with a heading (`## ✅ Approved` / `## 🔄 Changes requested`), then details, and run `gh pr comment <number> --body-file <file>`. Never inline `--body "..."` — a double-quoted shell string keeps `\n` literal. See `docs/pr-conventions.md` → *Posting PR Bodies & Comments*.
|
|
23
43
|
|
|
24
44
|
## Rules
|
|
25
45
|
|
|
46
|
+
- A verdict that does not cite executed verification (CI green, or your pasted test/build output) is invalid.
|
|
26
47
|
- Be constructive — suggest specific test cases, don't just say "needs more tests".
|
|
27
|
-
- Flag untested critical paths as blockers
|
|
28
|
-
- Approve trivial changes (docs, comments, config) without
|
|
29
|
-
- If CI is missing or broken,
|
|
48
|
+
- Flag untested critical paths as blockers; untested non-critical paths as suggestions.
|
|
49
|
+
- Approve trivial changes (docs, comments, config) without ceremony.
|
|
50
|
+
- If CI is missing or broken, that is a blocker — tests that don't run don't count.
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# Skill: PR Security Review
|
|
2
|
+
|
|
3
|
+
You review a **specific PR's diff** for security-relevant changes. You are added as a `review` stage **only when the change touches** authentication, authorization, secrets, input boundaries, cryptography, dependencies, or infrastructure exposure — i.e. when it is security-relevant. (For broader threat modeling, see your `security-review` skill from the security-audit module, if present.)
|
|
4
|
+
|
|
5
|
+
Review is by *probing*, not by reading. Your verdict must state what you actually checked.
|
|
6
|
+
|
|
7
|
+
## What to probe
|
|
8
|
+
|
|
9
|
+
1. **Input boundaries** — Is all external input validated and encoded? Any injection surface (SQL, command, path, template)?
|
|
10
|
+
2. **AuthN/AuthZ** — Are new endpoints/actions access-controlled? Any privilege escalation or missing ownership check?
|
|
11
|
+
3. **Secrets** — No secrets in code, logs, or error messages. Secret handling uses the established mechanism.
|
|
12
|
+
4. **Crypto** — No home-grown crypto; correct, current algorithms and key handling.
|
|
13
|
+
5. **Dependencies** — New/updated deps: known vulnerabilities? Is the source trustworthy?
|
|
14
|
+
6. **Data exposure** — Does the change leak data in responses, logs, or errors beyond what's intended?
|
|
15
|
+
|
|
16
|
+
## How to record your verdict
|
|
17
|
+
|
|
18
|
+
1. You are the active participant of a `review` stage on the issue carrying the PR link.
|
|
19
|
+
2. State **what you probed and how** (e.g. "checked the new `/upload` endpoint for path traversal with `../` inputs; validated the content-type allowlist"). A verdict without concrete checks is invalid.
|
|
20
|
+
3. Record the stage decision through the normal issue update route: `approved` by PATCHing the issue toward `done` with the checks performed, or `changes_requested` by PATCHing back to `in_progress` with the specific finding, impact, and remediation.
|
|
21
|
+
4. Optionally mirror as a GitHub PR comment via a Markdown file (`## ✅ Approved` / `## 🔄 Changes requested`), run `gh pr comment <number> --body-file <file>`. Never inline `--body "..."`. See `docs/pr-conventions.md` → *Posting PR Bodies & Comments*.
|
|
22
|
+
|
|
23
|
+
## Rules
|
|
24
|
+
|
|
25
|
+
- Block on exploitable issues (injection, auth bypass, secret exposure). Suggest on defense-in-depth hardening.
|
|
26
|
+
- Be specific: name the input, the path, the impact. "Looks secure" is not a review.
|
|
27
|
+
- If the change is not actually security-relevant, say so briefly and approve — don't manufacture findings.
|
|
@@ -16,7 +16,7 @@ You review PRs for visual quality, brand consistency, and accessibility. When a
|
|
|
16
16
|
|
|
17
17
|
1. When you are the active participant of a review stage on an issue with a PR link, review the PR.
|
|
18
18
|
2. Focus only on visual/design concerns — leave code logic to Code Reviewer and product scope to Product Owner.
|
|
19
|
-
3. Record your verdict
|
|
19
|
+
3. Record your verdict through the normal issue update route for your review stage:
|
|
20
20
|
- **approved** if visually sound
|
|
21
21
|
- **changes_requested** with specific, actionable feedback if not
|
|
22
22
|
4. Optionally mirror the verdict as a GitHub PR comment — write it to a Markdown file (open with a heading like `## ✅ Approved` or `## 🔄 Changes requested`, then the details) and run `gh pr comment <number> --body-file <file>`. Never use inline `--body "..."`: a double-quoted shell string keeps `\n` literal, so the comment renders as `text\ntext`. See `docs/pr-conventions.md` → *Posting PR Bodies & Comments*.
|
|
@@ -16,7 +16,7 @@ You review PRs for usability, user flow integrity, and alignment with user needs
|
|
|
16
16
|
|
|
17
17
|
1. When you are the active participant of a review stage on an issue with a PR link, review the PR.
|
|
18
18
|
2. Focus only on UX and usability concerns — leave code logic to Code Reviewer and visuals to UI Designer.
|
|
19
|
-
3. Record your verdict
|
|
19
|
+
3. Record your verdict through the normal issue update route for your review stage:
|
|
20
20
|
- **approved** if usability is sound
|
|
21
21
|
- **changes_requested** with specific, actionable feedback if not
|
|
22
22
|
4. Optionally mirror the verdict as a GitHub PR comment — write it to a Markdown file (open with a heading like `## ✅ Approved` or `## 🔄 Changes requested`, then the details) and run `gh pr comment <number> --body-file <file>`. Never use inline `--body "..."`: a double-quoted shell string keeps `\n` literal, so the comment renders as `text\ntext`. See `docs/pr-conventions.md` → *Posting PR Bodies & Comments*.
|
|
@@ -51,7 +51,6 @@ EOF
|
|
|
51
51
|
|
|
52
52
|
gh pr create --title "<type>: <description>" --body-file /tmp/pr-body.md
|
|
53
53
|
gh pr comment <number> --body-file /tmp/pr-body.md
|
|
54
|
-
gh pr review <number> --request-changes --body-file /tmp/pr-body.md
|
|
55
54
|
```
|
|
56
55
|
|
|
57
56
|
Every PR comment opens with a Markdown heading stating the verdict (`## ✅ Approved`, `## 🔄 Changes requested`, or `## 💬 Review notes`), followed by a short summary and bullet points or code blocks.
|
|
@@ -62,35 +61,48 @@ Apply one primary label: `feature`, `bug`, `docs`, `chore`, `infra`, `agent`.
|
|
|
62
61
|
|
|
63
62
|
## Review Workflow
|
|
64
63
|
|
|
65
|
-
Review runs through the issue's native `executionPolicy` (stages), not separate child issues
|
|
66
|
-
|
|
67
|
-
1. **Engineer**
|
|
68
|
-
2. **Engineer**
|
|
69
|
-
3. **Engineer** sets the originating issue
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
64
|
+
Review runs through the issue's native `executionPolicy` (stages), not separate child issues. The gate is **executed verification, not opinion**.
|
|
65
|
+
|
|
66
|
+
1. **Engineer** resolves the project/worktree base ref before branching from `heartbeat-context` / project workspace metadata. Use the configured `repoRef`, `defaultRef`, or `executionWorkspacePolicy.workspaceStrategy.baseRef` exactly as Paperclip provides it. PRs must target the corresponding GitHub base and must not silently target the wrong branch.
|
|
67
|
+
2. **Engineer** opens the PR on GitHub and adds the PR link as an issue comment.
|
|
68
|
+
3. **Engineer** sets the originating issue's `executionPolicy` stages, in order:
|
|
69
|
+
- a `review` stage for **QA** when a QA agent is on the team (test adequacy / running the tests),
|
|
70
|
+
- a `review` stage for the **Security Engineer** *only when the change is security-relevant* (auth, secrets, input boundaries, crypto, dependencies, infra exposure),
|
|
71
|
+
- an `approval` stage for the **Product Owner** (intent, scope, acceptance),
|
|
72
|
+
- a final `approval` stage for the **Engineer** as the merge gate.
|
|
73
|
+
Resolve each role to its agentId.
|
|
74
|
+
4. **Engineer** sets the issue to `in_review`.
|
|
75
|
+
5. **QA** (when present) reviews and records `approved`/`changes_requested` through the normal issue update route with executed evidence (see *Merge Rules*), preserving the issue-level review audit trail.
|
|
76
|
+
6. **Security Engineer** (when present as a stage) probes the security-relevant change and records a verdict stating what was checked.
|
|
77
|
+
7. **Code Reviewer** and other domain reviewers may add **advisory, non-blocking** PR comments. They do not gate the merge.
|
|
78
|
+
8. **Product Owner** reviews for intent match, scope discipline, and acceptance criteria, and records the `approval` verdict through the normal issue update route, preserving the issue-level approval audit trail.
|
|
79
|
+
9. **Engineer** owns the final `approval` stage (merge gate): once reviewers and the Product Owner have approved, the engineer satisfies the hard gate (CI green, or runs the tests/build and pastes the output), merges the PR into the correct configured base, confirms the merge landed, closes/archives the isolated execution workspace when one exists and close-readiness allows it, and only then records `approved` — which closes the issue to `done`. The merge and workspace cleanup must happen before the issue is `done`.
|
|
75
80
|
|
|
76
81
|
## Review Roles
|
|
77
82
|
|
|
78
|
-
- **
|
|
79
|
-
- **
|
|
80
|
-
- **Product Owner** (`approval` stage):
|
|
81
|
-
|
|
82
|
-
|
|
83
|
+
- **QA** (`review` stage, when present): the substantive gate. Test coverage, regression risk, and validation — backed by tests that actually ran.
|
|
84
|
+
- **Security Engineer** (`review` stage, only when the change is security-relevant): probes the diff for injection, auth, secrets, crypto, dependency, and exposure issues.
|
|
85
|
+
- **Product Owner** (`approval` stage): intent alignment, scope discipline, acceptance criteria.
|
|
86
|
+
- **Engineer** (`approval` stage, last): the merge gate and hard-gate backstop — see *Merge Rules*.
|
|
87
|
+
- **Code Reviewer / domain reviewers** (advisory): optional, non-blocking comments on correctness, clarity, design, accessibility, UX. They never gate the merge.
|
|
83
88
|
|
|
84
89
|
## Merge Rules
|
|
85
90
|
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
- CI must
|
|
89
|
-
-
|
|
90
|
-
-
|
|
91
|
-
-
|
|
92
|
-
-
|
|
91
|
+
The hard gate is **executed verification**, enforced on the Engineer's merge-gate stage and independent of which reviewers are present:
|
|
92
|
+
|
|
93
|
+
- **With CI:** CI (lint/test/build) must be **green** before the Engineer merges. This is machine-verified and cannot be skipped.
|
|
94
|
+
- **Without CI:** the Engineer must run the full test suite and build locally and paste the real output into the merge-gate verdict before merging. (When QA is present, QA already produced this evidence; the Engineer confirms it.)
|
|
95
|
+
- A verdict that does not cite executed verification — green CI, or pasted test/build output — is not valid.
|
|
96
|
+
- The Product Owner's `approval` stage must be approved.
|
|
97
|
+
- QA's `review` stage (when present) and the Security Engineer's `review` stage (when added) must be approved.
|
|
98
|
+
- The Code Reviewer and other domain reviewers are advisory — blocking only when they escalate a concern that QA, the Security Engineer, or the Engineer then acts on.
|
|
99
|
+
- No force pushes.
|
|
100
|
+
- Merge using `gh pr merge <number> --merge`.
|
|
101
|
+
- Before merge, verify the PR base matches the configured project/worktree base from `heartbeat-context`. Retarget before review/merge if needed.
|
|
102
|
+
- The Engineer is the merge owner — reviewers never merge.
|
|
93
103
|
- The engineer's merge gate must be the **last** `approval` stage. If the Product Owner's approval were last, it would auto-close the issue to `done` and the merge would be skipped, leaving the PR open on GitHub.
|
|
104
|
+
- If Paperclip created an isolated execution workspace for the issue, read its id from `heartbeat-context`, call close-readiness, and archive it after the PR is merged and the tree is clean. If cleanup is blocked or fails, do not mark the issue `done`; record the exact blocker and leave a concrete cleanup next action. If the issue runs in the shared project workspace, do not invent isolated-worktree cleanup.
|
|
105
|
+
- Do not configure GitHub branch protection to require approving reviews unless the project has distinct non-author GitHub reviewer credentials; all agents using one GitHub account cannot formally approve their own PRs.
|
|
94
106
|
|
|
95
107
|
## Dev Cycle Rules
|
|
96
108
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pr-review",
|
|
3
|
-
"description": "Coordinates
|
|
3
|
+
"description": "Coordinates substantive PR review through the issue's native executionPolicy. The merge gate is executed verification — green CI, or the engineer running the tests/build and pasting the output — not opinion. QA is the substantive reviewer when present; the Security Engineer reviews only security-relevant changes; the Code Reviewer is advisory.",
|
|
4
4
|
"requires": [
|
|
5
5
|
"github-repo"
|
|
6
6
|
],
|
|
@@ -11,6 +11,7 @@
|
|
|
11
11
|
"ui-designer",
|
|
12
12
|
"ux-researcher",
|
|
13
13
|
"qa",
|
|
14
|
+
"security-engineer",
|
|
14
15
|
"devops"
|
|
15
16
|
],
|
|
16
17
|
"capabilities": [],
|
|
@@ -20,11 +21,11 @@
|
|
|
20
21
|
"bootstrapPhase": "foundation",
|
|
21
22
|
"assignTo": "engineer",
|
|
22
23
|
"reviewGate": {
|
|
23
|
-
"reviewers": ["
|
|
24
|
+
"reviewers": ["qa"],
|
|
24
25
|
"approver": "product-owner",
|
|
25
26
|
"mergeGate": "engineer"
|
|
26
27
|
},
|
|
27
|
-
"description": "Document and verify the PR workflow:
|
|
28
|
+
"description": "Document and verify the PR workflow via the issue's executionPolicy. The merge gate is executed verification: with CI, builds must be green before merge; without CI, the engineer runs the test suite/build and pastes the output before merging. Stages: a review stage for QA when present, a review stage for the Security Engineer only on security-relevant changes, an approval stage for the Product Owner, and a final approval stage for the Engineer as the merge gate (woken last to merge the PR before recording approval, which closes the issue). The merge gate must be the last stage so the Product Owner's approval does not auto-close the issue with the PR still open. The Code Reviewer and other domain reviewers add advisory, non-blocking comments. Optional branch protection may disable direct pushes, but do not require GitHub-native approving reviews unless the project has distinct non-author GitHub reviewer credentials."
|
|
28
29
|
}
|
|
29
30
|
]
|
|
30
31
|
}
|
|
@@ -1,27 +1,27 @@
|
|
|
1
1
|
# Module: stall-detection
|
|
2
2
|
|
|
3
|
-
Adds
|
|
3
|
+
Adds scheduled stall detection as an assigned routine run.
|
|
4
4
|
|
|
5
5
|
## What it adds
|
|
6
6
|
|
|
7
|
-
- **CEO skill**: Stall check — detects issues stuck in `in_progress` or `in_review` for too long,
|
|
7
|
+
- **CEO skill**: Stall check — detects issues stuck in `in_progress` or `in_review` for too long, then records a structured next action, reassignment, blocker, or escalation.
|
|
8
8
|
|
|
9
9
|
## How it works
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
When the CEO is assigned a stall-detection routine run:
|
|
12
12
|
1. Are there issues in `in_progress` or `in_review` that haven't been updated recently?
|
|
13
13
|
2. If an issue appears stalled (no activity for a configurable period):
|
|
14
14
|
- Check if the assigned agent is running or idle
|
|
15
|
-
- If idle:
|
|
16
|
-
- If the agent has
|
|
17
|
-
3. This catches
|
|
15
|
+
- If idle: leave a structured next-action comment, reassign, or link a blocker as appropriate
|
|
16
|
+
- If the agent has already failed to respond: escalate to the board/CEO with exact evidence
|
|
17
|
+
3. This catches dropped handoffs without relying on generic mentions.
|
|
18
18
|
|
|
19
19
|
## Best for
|
|
20
20
|
|
|
21
|
-
- Any team
|
|
21
|
+
- Any team with multi-stage handoffs where ownership can become unclear
|
|
22
22
|
- Multi-agent teams where work can get dropped between agents
|
|
23
23
|
- Ensuring nothing falls through the cracks
|
|
24
24
|
|
|
25
25
|
## Example
|
|
26
26
|
|
|
27
|
-
An engineer finishes a PR and
|
|
27
|
+
An engineer finishes a PR and moves the issue to `in_review`, but the executionPolicy reviewer never acts. The CEO detects the stalled issue during the scheduled routine run, records the missing next action, and reassigns or escalates.
|
|
@@ -1,12 +1,3 @@
|
|
|
1
|
-
## Stall Detection
|
|
1
|
+
## Stall Detection Routine
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
1. Query active issues: `GET /api/companies/{companyId}/issues?status=in_progress,in_review`
|
|
6
|
-
2. For each issue, check the latest comment/activity timestamp.
|
|
7
|
-
3. If an issue has had no activity for more than 2 heartbeat cycles:
|
|
8
|
-
- Agent is `idle` → @-mention with a nudge.
|
|
9
|
-
- Agent is `running` → skip (may be mid-work).
|
|
10
|
-
- Agent is `error` or `paused` → escalate to the board.
|
|
11
|
-
4. If already nudged and still no progress → escalate to the board.
|
|
12
|
-
5. Record stall findings in daily notes.
|
|
3
|
+
Do not scan for stalled work during a normal heartbeat. When you are assigned a routine-run issue titled like "Stall detection", use `skills/stall-detection.md`, then summarize findings on the routine issue and exit.
|
|
@@ -1,21 +1,30 @@
|
|
|
1
1
|
# Skill: Stall Detection
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
You own stall detection when you are explicitly assigned a stall-detection routine run. This is not an every-heartbeat background scan.
|
|
4
|
+
|
|
5
|
+
## When To Use This Skill
|
|
6
|
+
|
|
7
|
+
Use this only when the current assigned issue/routine is titled like "Stall detection" or explicitly asks you to inspect stalled work. Otherwise follow the normal Paperclip heartbeat rule: only work assigned issues and do not scan the whole board.
|
|
4
8
|
|
|
5
9
|
## Stall Check
|
|
6
10
|
|
|
7
|
-
1.
|
|
8
|
-
2.
|
|
9
|
-
3.
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
-
|
|
13
|
-
-
|
|
14
|
-
|
|
15
|
-
|
|
11
|
+
1. Checkout the assigned routine-run issue.
|
|
12
|
+
2. Query active issues for the relevant company/project: `todo`, `in_progress`, `in_review`, and blocked work where applicable.
|
|
13
|
+
3. For each candidate, inspect latest comments/activity, execution state, blockers, approval/review state, and assigned agent status.
|
|
14
|
+
4. Skip issues with an active run, recent activity, valid `blockedByIssueIds`, or pending executionPolicy approval/review.
|
|
15
|
+
5. For a likely stall, leave a structured comment on the issue with:
|
|
16
|
+
- issue id/title
|
|
17
|
+
- assigned agent
|
|
18
|
+
- last activity timestamp/context
|
|
19
|
+
- why it appears stalled
|
|
20
|
+
- exact next action requested
|
|
21
|
+
6. Prefer reassignment, blocker linkage, or escalation to CEO/Product Owner over informal nudges.
|
|
22
|
+
7. If an agent is `error`, paused, or repeatedly non-responsive, escalate with an issue comment and assign the manager/CEO as appropriate.
|
|
23
|
+
8. Summarize findings on the routine-run issue and mark it done.
|
|
16
24
|
|
|
17
25
|
## Rules
|
|
18
26
|
|
|
19
|
-
-
|
|
20
|
-
-
|
|
21
|
-
-
|
|
27
|
+
- Do not @-mention as a generic nudge; use assignment, status, blockers, and explicit next-action comments.
|
|
28
|
+
- Do not interrupt running agents.
|
|
29
|
+
- Do not close or cancel another agent's work unless the issue explicitly grants that authority.
|
|
30
|
+
- Be specific: which issue, which agent, last activity, why stalled, and who owns the next action.
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"routines": [
|
|
6
6
|
{
|
|
7
7
|
"title": "Stall detection",
|
|
8
|
-
"description": "
|
|
8
|
+
"description": "Routine-run checklist: inspect in_progress/in_review issues for stale activity, verify blockers and executionPolicy gates, record a concrete next action/reassignment/escalation on each stalled issue, summarize on the routine issue, then exit.",
|
|
9
9
|
"assignTo": "ceo",
|
|
10
10
|
"schedule": "0 */3 * * *",
|
|
11
11
|
"priority": "medium",
|
|
@@ -1,42 +1,29 @@
|
|
|
1
1
|
# Skill: Issue Triage
|
|
2
2
|
|
|
3
|
-
You are responsible for processing inbound GitHub issues
|
|
3
|
+
You are responsible for processing inbound GitHub issues when assigned a triage issue or triage routine. Classify, respond, and convert actionable reports into Paperclip work.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## When To Use This Skill
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Use this only when the current assigned issue/routine asks for GitHub issue triage. Do not scan GitHub on every normal heartbeat.
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
2. **For each untriaged issue:**
|
|
11
|
-
a. Read the full issue body and any comments.
|
|
12
|
-
b. **Classify** by type:
|
|
13
|
-
- `bug` — Something is broken or behaves unexpectedly
|
|
14
|
-
- `feature` — New functionality request
|
|
15
|
-
- `enhancement` — Improvement to existing functionality
|
|
16
|
-
- `question` — User needs help or clarification
|
|
17
|
-
- `duplicate` — Already reported (link to original)
|
|
18
|
-
- `invalid` — Not actionable, out of scope, or spam
|
|
19
|
-
c. **Set priority** (P0–P3):
|
|
20
|
-
- P0: Production broken, data loss, security vulnerability
|
|
21
|
-
- P1: Major feature broken, blocking multiple users
|
|
22
|
-
- P2: Non-critical bug or important feature request
|
|
23
|
-
- P3: Minor issue, cosmetic, nice-to-have
|
|
24
|
-
d. **Apply labels** — `gh issue edit <number> --add-label "<type>,<priority>"`
|
|
25
|
-
e. **Respond to reporter:**
|
|
26
|
-
- Acknowledge the report
|
|
27
|
-
- Ask follow-up questions if reproduction steps are unclear (bugs)
|
|
28
|
-
- Set expectations ("we'll look into this" / "this is out of scope because...")
|
|
29
|
-
- For duplicates: link to the original issue and close
|
|
30
|
-
- For invalid: explain why and close politely
|
|
31
|
-
f. **Convert to Paperclip task** — For actionable issues (bug, feature, enhancement), create a corresponding issue in Paperclip via `POST /api/companies/{companyId}/issues` with the GitHub issue number in the description for traceability. Include the active `projectId` (and `goalId` / `parentId` when applicable).
|
|
9
|
+
## Triage Process
|
|
32
10
|
|
|
33
|
-
|
|
11
|
+
1. Checkout the assigned triage issue/routine.
|
|
12
|
+
2. Fetch new issues: `gh issue list --state open --label "" --json number,title,body,labels,createdAt` to find untriaged issues (no classification label yet).
|
|
13
|
+
3. For each untriaged issue:
|
|
14
|
+
- Read the full issue body and comments.
|
|
15
|
+
- Classify by type: `bug`, `feature`, `enhancement`, `question`, `duplicate`, `invalid`.
|
|
16
|
+
- Set priority P0-P3; P0 maps to urgent Paperclip priority.
|
|
17
|
+
- Apply labels with `gh issue edit <number> --add-label "<type>,<priority>"`.
|
|
18
|
+
- Respond to the reporter with acknowledgement, follow-up questions, or a polite close reason.
|
|
19
|
+
- For actionable issues, create a corresponding Paperclip issue via `POST /api/companies/{companyId}/issues`. Include GitHub issue URL/number, active `projectId`, and `goalId` / `parentId` when applicable.
|
|
20
|
+
4. Link bidirectionally: GitHub comment references the Paperclip issue, Paperclip issue references GitHub.
|
|
21
|
+
5. Summarize triage results on the assigned triage issue/routine and mark it done.
|
|
34
22
|
|
|
35
23
|
## Rules
|
|
36
24
|
|
|
37
|
-
-
|
|
38
|
-
-
|
|
39
|
-
-
|
|
40
|
-
-
|
|
41
|
-
-
|
|
42
|
-
- Escalate P0 issues immediately — create the Paperclip task with priority `urgent` and mention it in the CEO's daily notes.
|
|
25
|
+
- Do not triage from unrelated heartbeats.
|
|
26
|
+
- Respond respectfully and constructively, even for invalid or duplicate reports.
|
|
27
|
+
- Do not close legitimate issues without explanation.
|
|
28
|
+
- If you cannot classify an issue, ask for clarification and label `needs-info`.
|
|
29
|
+
- Escalate P0 issues immediately via Paperclip issue assignment/status and a CEO/Product Owner comment.
|