@mrciphersmith/keryx 0.4.27 → 0.4.28
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/README.md +2 -2
- package/dist/cli.js +105165 -104989
- package/dist/core.js +21 -197
- package/dist/keryx-general-worker-entry.js +22 -201
- package/package.json +3 -3
- package/src/gdskills/bundled/agents/work-planner.md +1 -1
- package/src/gdskills/bundled/install-manifest.json +3 -26
- package/src/gdskills/bundled/rules/core/code-review-learned-profile.mdc +1 -2
- package/src/gdskills/bundled/rules/core/definition-of-done.mdc +0 -1
- package/src/gdskills/bundled/rules/core/implementation-doc-mandate.mdc +4 -5
- package/src/gdskills/bundled/rules/core/jobs-documentation.mdc +8 -8
- package/src/gdskills/bundled/rules/core/skills-storage-workflow.mdc +7 -10
- package/src/gdskills/bundled/skills/core/reviewer-skill-creator/SKILL.md +1 -1
- package/src/gdskills/bundled/skills/orchestration/context-collector/SKILL.md +12 -21
- package/src/gdskills/bundled/skills/orchestration/feature-analyzer/SKILL.md +3 -3
- package/src/gdskills/bundled/skills/orchestration/flow-orchestrator/SKILL.md +1 -1
- package/src/gdskills/bundled/skills/orchestration/job-orchestrator/SKILL.md +1 -1
- package/src/gdskills/bundled/skills/orchestration/task-implementer/input-contract.schema.json +1 -1
- package/src/gdskills/bundled/skills/planning/autodoc-orchestrator/SKILL.md +1 -1
- package/src/gdskills/bundled/skills/planning/brainstorm/SKILL.md +1 -1
- package/src/gdskills/bundled/skills/planning/interview/SKILL.md +3 -4
- package/src/gdskills/bundled/skills/planning/interviewer/SKILL.md +1 -1
- package/src/gdskills/bundled/skills/quality/git-publish/SKILL.md +60 -0
- package/src/gdskills/bundled/skills/quality/pr-issue-documenter/SKILL.md +1 -1
- package/src/gdskills/bundled/skills/review/code-learned-review/SKILL.md +3 -3
- package/src/gdskills/bundled/skills/review/review-architecture/SKILL.md +7 -7
- package/src/gdskills/bundled/skills/review/review-backend/SKILL.md +22 -22
- package/src/gdskills/bundled/skills/review/review-clean-code/SKILL.md +15 -15
- package/src/gdskills/bundled/skills/review/review-core-boundaries/SKILL.md +2 -2
- package/src/gdskills/bundled/skills/review/review-degradation/SKILL.md +7 -7
- package/src/gdskills/bundled/skills/review/review-flow-graph/SKILL.md +2 -2
- package/src/gdskills/bundled/skills/review/review-frontend/SKILL.md +34 -30
- package/src/gdskills/bundled/skills/review/review-frontend-conventions/SKILL.md +2 -2
- package/src/gdskills/bundled/skills/review/review-highload/SKILL.md +64 -135
- package/src/gdskills/bundled/skills/review/review-logic/SKILL.md +4 -4
- package/src/gdskills/bundled/skills/review/review-orchestrator/SKILL.detail.md +18 -20
- package/src/gdskills/bundled/skills/review/review-orchestrator/SKILL.md +12 -18
- package/src/gdskills/bundled/skills/review/review-orchestrator/reviewer-finding.schema.json +2 -2
- package/src/gdskills/bundled/skills/review/review-orchestrator/reviewer-input.schema.json +2 -10
- package/src/gdskills/bundled/skills/review/review-performance/SKILL.md +35 -35
- package/src/gdskills/bundled/skills/review/review-pr-contract/SKILL.md +4 -5
- package/src/gdskills/bundled/skills/review/review-premise/SKILL.md +2 -2
- package/src/gdskills/bundled/skills/review/review-regression/SKILL.md +3 -5
- package/src/gdskills/bundled/skills/review/review-security-code/SKILL.md +14 -15
- package/src/gdskills/bundled/skills/review/review-style/SKILL.md +14 -13
- package/src/gdskills/bundled/skills/review/review-testing-practices/SKILL.md +11 -11
- package/src/gdskills/bundled/skills/review/review-ui-ux/SKILL.md +10 -11
- package/src/gdskills/bundled/skills/review/review-verifier/SKILL.md +5 -5
- package/src/gdskills/bundled/skills/shared/git-merge-base.md +1 -1
- package/src/gdskills/bundled/stacks/mobx/agent-refs.json +1 -1
- package/src/gdskills/bundled/stacks/mobx/governance/scout.json +2 -2
- package/src/gdskills/bundled/stacks/mobx/skills/mobx-store-implementation/SKILL.md +2 -2
- package/src/gdskills/bundled/stacks/vue/governance/scout.json +1 -1
- package/src/gdskills/contracts/review-finding.schema.json +2 -2
- package/src/gdskills/bundled/rules/core/code-review-ai-assistant.mdc +0 -49
- package/src/gdskills/bundled/rules/core/gproject-contracts.mdc +0 -198
- package/src/gdskills/bundled/skills/orchestration/feature-dev/SKILL.md +0 -177
- package/src/gdskills/bundled/skills/orchestration/job-documenter/SKILL.md +0 -414
- package/src/gdskills/bundled/skills/orchestration/job-documenter/input-contract.schema.json +0 -55
- package/src/gdskills/bundled/skills/orchestration/job-documenter/output-contract.schema.json +0 -58
- package/src/gdskills/bundled/skills/planning/consistency-checker/SKILL.codex.md +0 -209
- package/src/gdskills/bundled/skills/planning/consistency-checker/SKILL.cursor.md +0 -209
- package/src/gdskills/bundled/skills/planning/consistency-checker/SKILL.md +0 -208
- package/src/gdskills/bundled/skills/planning/patterns-researcher/SKILL.codex.md +0 -255
- package/src/gdskills/bundled/skills/planning/patterns-researcher/SKILL.cursor.md +0 -255
- package/src/gdskills/bundled/skills/planning/patterns-researcher/SKILL.md +0 -254
- package/src/gdskills/bundled/skills/planning/planner/SKILL.codex.md +0 -209
- package/src/gdskills/bundled/skills/planning/planner/SKILL.cursor.md +0 -209
- package/src/gdskills/bundled/skills/planning/planner/SKILL.md +0 -208
- package/src/gdskills/bundled/skills/planning/problem-definer/SKILL.codex.md +0 -171
- package/src/gdskills/bundled/skills/planning/problem-definer/SKILL.cursor.md +0 -171
- package/src/gdskills/bundled/skills/planning/problem-definer/SKILL.md +0 -170
- package/src/gdskills/bundled/skills/planning/project-discovery/SKILL.codex.md +0 -184
- package/src/gdskills/bundled/skills/planning/project-discovery/SKILL.cursor.md +0 -184
- package/src/gdskills/bundled/skills/planning/project-discovery/SKILL.md +0 -183
- package/src/gdskills/bundled/skills/planning/spec-writer/SKILL.codex.md +0 -249
- package/src/gdskills/bundled/skills/planning/spec-writer/SKILL.cursor.md +0 -249
- package/src/gdskills/bundled/skills/planning/spec-writer/SKILL.md +0 -248
- package/src/gdskills/bundled/skills/planning/stack-advisor/SKILL.codex.md +0 -199
- package/src/gdskills/bundled/skills/planning/stack-advisor/SKILL.cursor.md +0 -199
- package/src/gdskills/bundled/skills/planning/stack-advisor/SKILL.md +0 -198
- package/src/gdskills/bundled/skills/quality/commit/SKILL.md +0 -87
- package/src/gdskills/bundled/skills/quality/pr/SKILL.md +0 -95
- package/src/gdskills/bundled/skills/quality/push/SKILL.md +0 -73
- package/src/gdskills/bundled/skills/review/code-ai-review/SKILL.md +0 -238
- package/src/gdskills/bundled/skills/review/code-mobx-store-review/SKILL.md +0 -301
- package/src/gdskills/bundled/skills/review/code-style-review/SKILL.md +0 -208
|
@@ -55,16 +55,13 @@ path.
|
|
|
55
55
|
excludes the harness reading it. This is the only field in the tree of
|
|
56
56
|
which that is true.
|
|
57
57
|
|
|
58
|
-
Case 2 is why
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
`
|
|
64
|
-
|
|
65
|
-
excludes Claude. These builds are NOT identical copies and must not be deleted
|
|
66
|
-
as such; `src/gdskills/build-parity.test.ts` exempts this one hunk, by name,
|
|
67
|
-
for these seven skills only, and its allow-list is where any widening has to be
|
|
58
|
+
Case 2 is why such a build may differ from its `SKILL.md` by exactly one line:
|
|
59
|
+
it adds `compatible_harnesses: "cursor,codex,zed,opencode"`, while the
|
|
60
|
+
`SKILL.md` declares no harness list, because it is the Claude build and cannot
|
|
61
|
+
carry one that excludes Claude. No shipped skill has such a build today. Such a
|
|
62
|
+
build is NOT an identical copy and must not be deleted as one;
|
|
63
|
+
`src/gdskills/build-parity.test.ts` exempts this one hunk, by name, for the
|
|
64
|
+
skills it lists only, and its allow-list is where any widening has to be
|
|
68
65
|
argued. Every other difference between a build and its `SKILL.md` is drift and
|
|
69
66
|
gets reconciled.
|
|
70
67
|
|
|
@@ -236,7 +236,7 @@ undocumented is drift that will be silently "fixed" by whoever refreshes next.
|
|
|
236
236
|
| Refresh one whose origin drifted | YES | — |
|
|
237
237
|
| Create an entity/module project-skill | NO | `entity-skill-creator` |
|
|
238
238
|
| Change a reviewer keryx ships | NO | edit `src/gdskills/bundled/skills/review/` and open a PR |
|
|
239
|
-
| Update a skill from review findings | NO | `
|
|
239
|
+
| Update a skill from review findings | NO | `keryx skills learn` |
|
|
240
240
|
| Decide which reviewers a round dispatches | NO | `review-orchestrator` |
|
|
241
241
|
| Import a tree of overlay reviewers | YES — `keryx review import --from <dir> --only '<glob>'`, dry-run first (`SKILL.detail.md`) | — |
|
|
242
242
|
| Import a non-review SKILL.md / GitHub URL | NO | `entity-skill-creator` / `keryx skills import` |
|
|
@@ -39,7 +39,7 @@ Collects and maintains a **unified context document** for a job. The context doc
|
|
|
39
39
|
6. Keep the context document up-to-date as the job evolves (version-tracked updates)
|
|
40
40
|
|
|
41
41
|
**Input:** Task description + job name + project path (from orchestrator or user)
|
|
42
|
-
**Output:** `context.md` document in `.metaproject/jobs/<job-name>/ai/` and `.metaproject/jobs/<job-name>/man/`,
|
|
42
|
+
**Output:** `context.md` document in `.metaproject/jobs/<job-name>/ai/` and `.metaproject/jobs/<job-name>/man/`, written straight into the job folder `keryx job init` created
|
|
43
43
|
|
|
44
44
|
## When to Use
|
|
45
45
|
|
|
@@ -55,7 +55,7 @@ Phase 1: RECEIVE -> Parse input, determine scope and focus areas
|
|
|
55
55
|
Phase 2: LOCAL -> Scan local docs, jobs, rules, codebase for relevant context
|
|
56
56
|
Phase 3: EXTERNAL -> Fetch external docs for libraries, APIs, best practices
|
|
57
57
|
Phase 4: SYNTHESIZE -> Merge all findings into a single context document
|
|
58
|
-
Phase 5: DOCUMENT -> Save
|
|
58
|
+
Phase 5: DOCUMENT -> Save into the job folder, return result
|
|
59
59
|
```
|
|
60
60
|
|
|
61
61
|
---
|
|
@@ -487,27 +487,18 @@ When updating an existing context:
|
|
|
487
487
|
|
|
488
488
|
Save the context document and notify orchestrator.
|
|
489
489
|
|
|
490
|
-
### 5.1 Save
|
|
490
|
+
### 5.1 Save into the job folder (when running within a job)
|
|
491
491
|
|
|
492
|
-
If JOB_NAME is provided,
|
|
492
|
+
If JOB_NAME is provided, the job folder already exists — `keryx job init` creates
|
|
493
|
+
it, and the orchestrator owns it. Write the full context document, metadata block
|
|
494
|
+
included, to `<JOBS_ROOT>/<JOB_NAME>/ai/context.md` and `<JOBS_ROOT>/<JOB_NAME>/man/context.md`.
|
|
493
495
|
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
DATA:
|
|
500
|
-
DOC_TYPE: context
|
|
501
|
-
TARGET: both
|
|
502
|
-
TITLE: Context — <task description short>
|
|
503
|
-
CONTENT: <full context document>
|
|
504
|
-
AGENT: context-collector
|
|
505
|
-
TASK: Collect context for <task description>
|
|
506
|
-
VERSION: <1.0 for new, incremented for update>
|
|
507
|
-
DOC_STATUS: final
|
|
508
|
-
```
|
|
496
|
+
Do not record it with `keryx job document`: that command takes only `analysis`,
|
|
497
|
+
`implementation-report`, `review` and `verification-report`, and recording a type a
|
|
498
|
+
second time replaces the first file, so filing a context document under
|
|
499
|
+
`analysis` would overwrite the real analysis.
|
|
509
500
|
|
|
510
|
-
For ACTION=update,
|
|
501
|
+
For ACTION=update, write to the same paths — the new revision replaces the existing `context.md`.
|
|
511
502
|
|
|
512
503
|
### 5.2 Save directly (when running standalone without a job)
|
|
513
504
|
|
|
@@ -667,5 +658,5 @@ Stop and re-read this skill if you are thinking:
|
|
|
667
658
|
| "The task mentions React, so I should fetch React documentation." | Rule 10: no external fetch for well-known patterns already covered by project rules. External research is for the specific API, version gotcha or convention this task turns on — not for a topic overview. |
|
|
668
659
|
| "This section of the existing context looks stale, so I'll drop it while updating." | 4.3 and Rule 4: preserve existing sections unless they are explicitly outdated. "Looks stale" from inside a scoped update usually means "I did not re-research it" — removing it silently deletes a decision another agent is relying on. |
|
|
669
660
|
| "I fixed the small inconsistency I noticed in the source file while reading it." | Rule 11: this skill writes only into the job folder. An edit made during collection lands in a diff nobody attributed to a task, and the implementer inherits it without knowing. |
|
|
670
|
-
| "The context is written, so I can return —
|
|
661
|
+
| "The context is written, so I can return — saving it can happen later." | Phase 5 is part of the skill. A `context.md` that was never written to the job folder leaves the next phase resolving `CONTEXT_LOCATION` to nothing. |
|
|
671
662
|
| "The content changed only slightly, so bumping the Version and update log is overkill." | Rule 12 and Rule 3: version, timestamp and update log are mandatory. Without them, two agents reading different revisions have no way to tell which one they have. |
|
|
@@ -291,9 +291,9 @@ Check `AGENTS.md` for available tools (`playwright-testing.mdc`, `storybook-guid
|
|
|
291
291
|
## Step 8: Integration with Other Skills
|
|
292
292
|
|
|
293
293
|
Before finalizing, consider running:
|
|
294
|
-
- `skills/review/
|
|
295
|
-
- `skills/review/
|
|
296
|
-
- `skills/review/
|
|
294
|
+
- `skills/review/review-architecture` — if architecture changes detected
|
|
295
|
+
- `skills/review/review-logic` — for self-validation of findings
|
|
296
|
+
- `skills/review/review-frontend` — if store changes found
|
|
297
297
|
|
|
298
298
|
---
|
|
299
299
|
|
|
@@ -290,7 +290,7 @@ Recommended worker routing:
|
|
|
290
290
|
| `test` | `tests-creator` or `test-gen` |
|
|
291
291
|
| `implement` | `task-implementer` |
|
|
292
292
|
| `review` | `review-orchestrator` |
|
|
293
|
-
| `docs` | `
|
|
293
|
+
| `docs` | `prd-creator`, a documentation-specific project skill, or `keryx job document` to file a document in a job folder |
|
|
294
294
|
|
|
295
295
|
**Before the first `task-implementer` dispatch of the run:** when `review.jev.edit_guard` is on (`.metaproject/tasks.config.json`), confirm the guard is active — `keryx review jev-edit-guard status`, else `keryx review jev-edit-guard install` — and say why in one line.
|
|
296
296
|
|
|
@@ -988,7 +988,7 @@ journal line is the record.
|
|
|
988
988
|
`review-orchestrator` is the review path. It is not one strategy among several: it is
|
|
989
989
|
the only entry point that produces a **managed review record**, and every round this
|
|
990
990
|
skill runs is a round that must be citable afterwards. The legacy alternatives —
|
|
991
|
-
launching `code
|
|
991
|
+
launching a `code-*` profile (`code-learned-review`, or the retired ones) by hand, or the
|
|
992
992
|
never-bundled `code-review` 4-agent skill — are gone. They emitted prose into a chat
|
|
993
993
|
transcript and nothing else, which is precisely the failure the managed pipeline
|
|
994
994
|
replaced.
|
package/src/gdskills/bundled/skills/orchestration/task-implementer/input-contract.schema.json
CHANGED
|
@@ -182,7 +182,7 @@
|
|
|
182
182
|
"reviewer": {
|
|
183
183
|
"type": "string",
|
|
184
184
|
"description": "Which review skill found this",
|
|
185
|
-
"examples": ["
|
|
185
|
+
"examples": ["review-logic", "review-frontend", "code-learned-review"]
|
|
186
186
|
},
|
|
187
187
|
"premise_verdict": {
|
|
188
188
|
"type": "string",
|
|
@@ -5,7 +5,7 @@ description: >
|
|
|
5
5
|
and produces comprehensive developer documentation without user involvement after initial setup.
|
|
6
6
|
Use when the user provides a repo path, asks to document existing code, or wants
|
|
7
7
|
onboarding docs, an API reference, or an architecture overview generated automatically.
|
|
8
|
-
NOT for: writing new PRDs or planning new features (use
|
|
8
|
+
NOT for: writing new PRDs or planning new features (use docpack-orchestrator).
|
|
9
9
|
triggers:
|
|
10
10
|
- "autodoc"
|
|
11
11
|
- "document codebase"
|
|
@@ -74,7 +74,7 @@ Launch 3 agents simultaneously:
|
|
|
74
74
|
3. **Next steps** — concrete action items
|
|
75
75
|
|
|
76
76
|
### Step 5: Discuss
|
|
77
|
-
Offer to go deeper on any option or
|
|
77
|
+
Offer to go deeper on any option or start `job-orchestrator` or `/prd-creator`.
|
|
78
78
|
|
|
79
79
|
## Quick Mode (--quick)
|
|
80
80
|
Skip agents. Inline: 3-5 options in table, score each, recommend one.
|
|
@@ -21,7 +21,7 @@ Proceed directly with your assigned task.
|
|
|
21
21
|
|
|
22
22
|
# Interview
|
|
23
23
|
|
|
24
|
-
Critical requirements interviewer that asks targeted clarifying questions before expensive operations begin. The goal is to eliminate ambiguity and gather precise context so downstream skills (job-orchestrator,
|
|
24
|
+
Critical requirements interviewer that asks targeted clarifying questions before expensive operations begin. The goal is to eliminate ambiguity and gather precise context so downstream skills (job-orchestrator, flow-orchestrator, prd-creator) produce accurate results.
|
|
25
25
|
|
|
26
26
|
## Input Contract
|
|
27
27
|
|
|
@@ -31,7 +31,7 @@ When called by another skill (orchestrated mode):
|
|
|
31
31
|
"goal": "what needs to be done (issue title, feature description, task)",
|
|
32
32
|
"context": "collected context from context-collector or another agent",
|
|
33
33
|
"domain": "implement | review | design | migrate | custom",
|
|
34
|
-
"caller": "job-orchestrator |
|
|
34
|
+
"caller": "job-orchestrator | flow-orchestrator | user | prd-creator",
|
|
35
35
|
"known_facts": ["already known facts or decisions"],
|
|
36
36
|
"max_questions": null
|
|
37
37
|
}
|
|
@@ -143,7 +143,7 @@ After all questions are answered:
|
|
|
143
143
|
### Phase 5: Handoff
|
|
144
144
|
|
|
145
145
|
Return the output contract to the calling skill, or if standalone — ask what the user wants to do next:
|
|
146
|
-
- "Start implementing? I can run
|
|
146
|
+
- "Start implementing? I can run the `job-orchestrator` pipeline"
|
|
147
147
|
- "Create a PRD? I can run `/prd-creator`"
|
|
148
148
|
- "Need more brainstorming? Try `/brainstorm`"
|
|
149
149
|
|
|
@@ -168,7 +168,6 @@ Skip options when:
|
|
|
168
168
|
|
|
169
169
|
```
|
|
170
170
|
job-orchestrator → context-collector → interview → plan → execute
|
|
171
|
-
feature-dev → interview (Phase 1) → design → implement
|
|
172
171
|
prd-creator → interview → requirements document
|
|
173
172
|
```
|
|
174
173
|
|
|
@@ -52,7 +52,7 @@ blockers?: string[] — unresolved critical unknowns
|
|
|
52
52
|
|
|
53
53
|
## When to Use
|
|
54
54
|
|
|
55
|
-
- Called by `job-orchestrator
|
|
55
|
+
- Called by `job-orchestrator` and `brainstorm` at start of Phase 0
|
|
56
56
|
- Directly by user: `/interviewer <topic>` — runs context-collector first if no context provided
|
|
57
57
|
- When requirements are vague or ambiguous
|
|
58
58
|
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: git-publish
|
|
3
|
+
description: "Use when committing changes, pushing a branch to the remote, or opening a pull request: commit, push and PR rules for staging, hooks, upstream and force. NOT for documenting a pull request that is already open, or its linked issue (use `pr-issue-documenter`)."
|
|
4
|
+
triggers:
|
|
5
|
+
- "commit changes"
|
|
6
|
+
- "git commit"
|
|
7
|
+
- "conventional commit"
|
|
8
|
+
- "Commit this"
|
|
9
|
+
- "push branch"
|
|
10
|
+
- "git push"
|
|
11
|
+
- "publish branch"
|
|
12
|
+
- "Push to remote"
|
|
13
|
+
- "open PR"
|
|
14
|
+
- "create pull request"
|
|
15
|
+
- "draft PR"
|
|
16
|
+
- "Open pull request"
|
|
17
|
+
metadata:
|
|
18
|
+
author: "MrCipherSmith"
|
|
19
|
+
version: "1.0.0"
|
|
20
|
+
category: "quality"
|
|
21
|
+
compatible_harnesses: "cursor,codex,zed,opencode,claude"
|
|
22
|
+
license: "MIT"
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
# Git publishing rules
|
|
26
|
+
|
|
27
|
+
Apply to every commit, push and pull request you create.
|
|
28
|
+
|
|
29
|
+
## Commit
|
|
30
|
+
|
|
31
|
+
- Stage explicit paths that belong to the change. Never `git add -A`, `--all` or `.`, never `commit -a`:
|
|
32
|
+
other agents or the user may have unrelated edits in the same tree.
|
|
33
|
+
- Never stage `.env`, credentials, keys or large binaries. Ask before staging an untracked file that
|
|
34
|
+
does not look like part of this change.
|
|
35
|
+
- Subject `<type>(<scope>): <description>`, English, at most 72 characters, naming the change.
|
|
36
|
+
- No `Co-Authored-By` or "Generated with" trailers.
|
|
37
|
+
- Never `--no-verify`. If a hook fails, fix the cause, re-stage and make a new commit; amend only when
|
|
38
|
+
the user asked for an amend.
|
|
39
|
+
|
|
40
|
+
## Push
|
|
41
|
+
|
|
42
|
+
- Ask first if the tree has uncommitted changes, or if the branch is `main`/`master`.
|
|
43
|
+
- A branch without an upstream is pushed with `git push -u origin <branch>`.
|
|
44
|
+
- Never force (`--force`, `--force-with-lease`, `+ref`) unless the user said "force push" in this
|
|
45
|
+
conversation. A rejected push is rebased onto the remote and pushed normally, or handed back.
|
|
46
|
+
|
|
47
|
+
## Pull request
|
|
48
|
+
|
|
49
|
+
- Push the branch with `-u` before `gh pr create`; never open a PR from `main`/`master` or over a
|
|
50
|
+
dirty tree without asking.
|
|
51
|
+
- Title under 70 characters describing the whole branch. Body covers every commit in
|
|
52
|
+
`<base>..HEAD`: Summary, Changes, Test plan.
|
|
53
|
+
- Reference only issues the branch or its commits actually link; never guess a `Closes #N`.
|
|
54
|
+
- Ask before opening a PR of 10 or more commits.
|
|
55
|
+
- Report the PR URL.
|
|
56
|
+
|
|
57
|
+
## Verification
|
|
58
|
+
|
|
59
|
+
- Done when `git show --stat HEAD` lists exactly the intended files.
|
|
60
|
+
- Done when `git log @{upstream}..HEAD` is empty.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: pr-issue-documenter
|
|
3
|
-
description: "Use when documenting PR changes, adding a PR description, creating a linked issue for a PR, or updating an existing issue body. NOT for opening the pull request in the first place (use `
|
|
3
|
+
description: "Use when documenting PR changes, adding a PR description, creating a linked issue for a PR, or updating an existing issue body. NOT for opening the pull request in the first place (use `git-publish`)."
|
|
4
4
|
triggers:
|
|
5
5
|
- "document PR"
|
|
6
6
|
- "PR description"
|
|
@@ -214,9 +214,9 @@ following `code-review-learned-profile.mdc`. It has no opinions of its own.
|
|
|
214
214
|
| Concern | This skill | Use instead |
|
|
215
215
|
| -------------------------------------------------------------- | ---------- | ------------------------ |
|
|
216
216
|
| This project's accumulated review conventions | ✅ YES | — |
|
|
217
|
-
| General
|
|
218
|
-
| MobX store internals (actions, computed, reactions) | ❌ NO | `
|
|
219
|
-
| Pure style/naming/architecture pattern audit | ❌ NO | `
|
|
217
|
+
| General review (broader quality, performance, UX) | ❌ NO | `review-orchestrator` |
|
|
218
|
+
| MobX store internals (actions, computed, reactions) | ❌ NO | `review-frontend` |
|
|
219
|
+
| Pure style/naming/architecture pattern audit | ❌ NO | `review-style` |
|
|
220
220
|
| Logic correctness with no learned lesson behind it | ❌ NO | `review-logic` |
|
|
221
221
|
|
|
222
222
|
---
|
|
@@ -16,7 +16,7 @@ triggers:
|
|
|
16
16
|
- "check layers"
|
|
17
17
|
metadata:
|
|
18
18
|
author: "MrCipherSmith"
|
|
19
|
-
version: "1.
|
|
19
|
+
version: "1.2.0"
|
|
20
20
|
category: "review"
|
|
21
21
|
compatible_harnesses: "cursor,codex,zed,opencode,claude"
|
|
22
22
|
license: "MIT"
|
|
@@ -26,7 +26,7 @@ license: "MIT"
|
|
|
26
26
|
|
|
27
27
|
Specialized reviewer for **architectural patterns and structural decisions**.
|
|
28
28
|
Reviews only changes introduced in the current branch (merge-base to HEAD).
|
|
29
|
-
Focuses exclusively on verifiable structural violations — not style opinions or hypothetical concerns. Its inputs are the reviewer payload only; session memory and earlier conversation are not inputs. It runs no command unless its payload's `allowed_tools` says `run-tests`, except the read-only `git log`, `git blame` and `git show` where its host gives a read-only child git (keryx shell does not: there the payload supplies the history).
|
|
29
|
+
Focuses exclusively on verifiable structural violations — not style opinions or hypothetical concerns. Its inputs are the reviewer payload only; session memory and earlier conversation are not inputs. It runs no command unless its payload's `allowed_tools` says `run-tests`, except the read-only `git log`, `git blame` and `git show` where its host gives a read-only child git (keryx shell does not: there the payload supplies the history), and the read-only layer commands the orchestrator lists (`keryx gdgraph affected|find`, `keryx test related`, `keryx wiki ask`, `keryx memory search`, `keryx ctx rg|read`); it never writes in the reviewed tree.
|
|
30
30
|
|
|
31
31
|
---
|
|
32
32
|
|
|
@@ -197,7 +197,7 @@ Focus on **SRP** and **DIP** — the two most commonly violated in practice.
|
|
|
197
197
|
| Security vulnerabilities (injection, auth bypass) | NO | `review-security-code` |
|
|
198
198
|
| Style, naming, import order | NO | `review-style` |
|
|
199
199
|
| Performance (bundle size, render cost, query plan) | NO | `review-performance` |
|
|
200
|
-
| MobX store internals deep-dive | surface violations only | `
|
|
200
|
+
| MobX store internals deep-dive | surface violations only | `review-frontend` for full store audit |
|
|
201
201
|
|
|
202
202
|
---
|
|
203
203
|
|
|
@@ -257,13 +257,13 @@ conditions land under that rubric, not a second rubric.
|
|
|
257
257
|
|---|---|---|
|
|
258
258
|
| Circular dependency that fails at runtime (an import resolves to `undefined` on a path the change reaches) | `blocker` | Crash |
|
|
259
259
|
| Module scope mismatch that produces wrong data across requests | `blocker` | Data corruption |
|
|
260
|
-
| Layer violation — API/IO call in a component, business logic in a controller, domain importing infrastructure | `major`
|
|
261
|
-
| Broken DIP; cross-module coupling
|
|
260
|
+
| Layer violation — API/IO call in a component, business logic in a controller, domain importing infrastructure | `minor` — `major` only when a concrete defect it causes is named (trigger and outcome) or a stated project rule makes it one | Structural cost lands on the next editor. Identical to `review-frontend` and `review-backend` for the same condition |
|
|
261
|
+
| Broken DIP; cross-module coupling | `minor` — `major` under the same condition | Same |
|
|
262
262
|
| SRP smell with a clear separation path; ISP violation; a component reading several raw observables instead of a computed | `minor` | The code is correct; the cost is to whoever restructures it next |
|
|
263
263
|
| Architectural opinion with no named violation | `info` | Shared laws 1 and 2 |
|
|
264
264
|
|
|
265
|
-
|
|
266
|
-
|
|
265
|
+
This lens owns circular imports: one that resolves cleanly is `minor`, not a
|
|
266
|
+
`blocker`; `review-style` and `review-clean-code` defer to this rating.
|
|
267
267
|
|
|
268
268
|
## Iron Laws
|
|
269
269
|
|
|
@@ -15,7 +15,7 @@ triggers:
|
|
|
15
15
|
- "review NestJS"
|
|
16
16
|
metadata:
|
|
17
17
|
author: "MrCipherSmith"
|
|
18
|
-
version: "1.
|
|
18
|
+
version: "1.3.0"
|
|
19
19
|
category: "review"
|
|
20
20
|
compatible_harnesses: "cursor,codex,zed,opencode,claude"
|
|
21
21
|
stack_requires: "nestjs,prisma"
|
|
@@ -26,7 +26,7 @@ license: "MIT"
|
|
|
26
26
|
|
|
27
27
|
Focused backend reviewer covering NestJS patterns, REST API design, database access patterns,
|
|
28
28
|
and TypeScript correctness for service-layer code. This skill does NOT duplicate security or
|
|
29
|
-
performance checks — those belong to `review-security-code` and `review-performance`. Its inputs are the reviewer payload only; session memory and earlier conversation are not inputs. It runs no command unless its payload's `allowed_tools` says `run-tests`, except the read-only `git log`, `git blame` and `git show` where its host gives a read-only child git (keryx shell does not: there the payload supplies the history).
|
|
29
|
+
performance checks — those belong to `review-security-code` and `review-performance`. Its inputs are the reviewer payload only; session memory and earlier conversation are not inputs. It runs no command unless its payload's `allowed_tools` says `run-tests`, except the read-only `git log`, `git blame` and `git show` where its host gives a read-only child git (keryx shell does not: there the payload supplies the history), and the read-only layer commands the orchestrator lists (`keryx gdgraph affected|find`, `keryx test related`, `keryx wiki ask`, `keryx memory search`, `keryx ctx rg|read`); it never writes in the reviewed tree.
|
|
30
30
|
|
|
31
31
|
---
|
|
32
32
|
|
|
@@ -79,7 +79,7 @@ git diff --name-status "${BASE_SHA}" && git diff "${BASE_SHA}" && git ls-files -
|
|
|
79
79
|
|
|
80
80
|
**Module structure**
|
|
81
81
|
- `@Module()` declaration present; providers, imports, exports are correctly listed
|
|
82
|
-
- Circular dependency risk: two modules importing each other —
|
|
82
|
+
- Circular dependency risk: two modules importing each other — defer the cycle to `review-architecture`; suggest `forwardRef()`
|
|
83
83
|
- Feature modules do not import `AppModule`
|
|
84
84
|
|
|
85
85
|
**Provider scope**
|
|
@@ -91,18 +91,17 @@ git diff --name-status "${BASE_SHA}" && git diff "${BASE_SHA}" && git ls-files -
|
|
|
91
91
|
- All controller methods accepting user input (body, query, param) have a DTO class decorated with `class-validator` decorators
|
|
92
92
|
- Required fields: `@IsString()`, `@IsNumber()`, `@IsEmail()`, etc. present and accurate
|
|
93
93
|
- `@IsOptional()` used only on truly optional fields; non-optional fields must not have `@IsOptional()`
|
|
94
|
-
- `ValidationPipe` applied globally (in `main.ts`) or explicitly via `@UsePipes(ValidationPipe)` —
|
|
94
|
+
- `ValidationPipe` applied globally (in `main.ts`) or explicitly via `@UsePipes(ValidationPipe)` — missing on an endpoint accepting user input is rated by the DTO row of the conditions table
|
|
95
95
|
- `@Transform()` used where input coercion is needed (e.g., string → number from query params)
|
|
96
96
|
|
|
97
97
|
**Guards and roles**
|
|
98
98
|
- Protected endpoints have `@UseGuards(...)` with appropriate guard(s)
|
|
99
|
-
- Role-based access uses `@Roles(...)` decorator with a roles guard — missing guard on an endpoint that should be protected is
|
|
99
|
+
- Role-based access uses `@Roles(...)` decorator with a roles guard — a missing guard on an endpoint that should be protected is rated by the auth-guard row of the conditions table
|
|
100
100
|
- Public endpoints explicitly marked with `@Public()` or equivalent decorator, not just left unguarded
|
|
101
101
|
|
|
102
102
|
**Controller responsibilities**
|
|
103
|
-
- Controllers are thin: no business logic, no direct ORM calls, no computation
|
|
104
|
-
-
|
|
105
|
-
- If business logic is in a controller method, flag as `major` ("move to service layer")
|
|
103
|
+
- Controllers are thin: no business logic, no direct ORM calls, no computation; a method does parse input → delegate to service → return response
|
|
104
|
+
- If business logic is in a controller method, flag it per the controller row of the conditions table (`minor`: "move to service layer")
|
|
106
105
|
|
|
107
106
|
**Service layer**
|
|
108
107
|
- Business logic lives in services
|
|
@@ -131,7 +130,7 @@ git diff --name-status "${BASE_SHA}" && git diff "${BASE_SHA}" && git ls-files -
|
|
|
131
130
|
**Error handling**
|
|
132
131
|
- Async controller methods must have error handling: either `try/catch` or a global exception filter
|
|
133
132
|
- Unhandled promise rejections (async method without try/catch, no global filter) — **blocker**
|
|
134
|
-
- Exception messages must not leak internal details (stack traces, ORM error strings) to the HTTP response — leaking is
|
|
133
|
+
- Exception messages must not leak internal details (stack traces, ORM error strings) to the HTTP response — leaking is rated by the stack-trace row of the conditions table
|
|
135
134
|
- NestJS built-in exceptions (`NotFoundException`, `BadRequestException`, etc.) preferred over generic `Error`
|
|
136
135
|
|
|
137
136
|
---
|
|
@@ -139,7 +138,7 @@ git diff --name-status "${BASE_SHA}" && git diff "${BASE_SHA}" && git ls-files -
|
|
|
139
138
|
### 3. Database Patterns (ORM)
|
|
140
139
|
|
|
141
140
|
**N+1 queries**
|
|
142
|
-
- Relation loaded inside a loop without eager loading (`relations`, `leftJoinAndSelect`) or a DataLoader —
|
|
141
|
+
- Relation loaded inside a loop without eager loading (`relations`, `leftJoinAndSelect`) or a DataLoader — rated by the N+1 row of the conditions table
|
|
143
142
|
- Example: `for (const user of users) { user.orders = await orderRepo.find(...) }` — flag with concrete suggestion to use `relations: ['orders']` or batch query
|
|
144
143
|
|
|
145
144
|
**Transactions**
|
|
@@ -148,9 +147,9 @@ git diff --name-status "${BASE_SHA}" && git diff "${BASE_SHA}" && git ls-files -
|
|
|
148
147
|
- NestJS TypeORM: use `dataSource.transaction(async (manager) => { ... })` or `@Transaction()` decorator pattern
|
|
149
148
|
|
|
150
149
|
**Raw query safety**
|
|
151
|
-
- String interpolation in raw queries
|
|
150
|
+
- String interpolation in raw queries: SQL injection risk, rated by the raw-SQL row of the conditions table
|
|
152
151
|
- Use parameterized queries: `query('SELECT * FROM users WHERE id = $1', [id])`
|
|
153
|
-
- Flag `createQueryBuilder().where('id = ' + id)`
|
|
152
|
+
- Flag `createQueryBuilder().where('id = ' + id)` under that row
|
|
154
153
|
|
|
155
154
|
**Soft deletes**
|
|
156
155
|
- If the project schema uses `deletedAt` / `@DeleteDateColumn()`, deletions must use `.softRemove()` / `.softDelete()`, not `.remove()` / `.delete()`
|
|
@@ -159,7 +158,7 @@ git diff --name-status "${BASE_SHA}" && git diff "${BASE_SHA}" && git ls-files -
|
|
|
159
158
|
**Migration safety**
|
|
160
159
|
- Column removed in migration — check that no application code still references it
|
|
161
160
|
- Dropping a column without a deprecation period in a live system flagged as `major`
|
|
162
|
-
- `NOT NULL` column added without a default value to a populated table —
|
|
161
|
+
- `NOT NULL` column added without a default value to a populated table — `major`; `blocker` only on shown truncation
|
|
163
162
|
|
|
164
163
|
---
|
|
165
164
|
|
|
@@ -205,15 +204,16 @@ is, and a condition that cannot name one is not a `blocker`.
|
|
|
205
204
|
|
|
206
205
|
| Condition | Severity | Shape |
|
|
207
206
|
|---|---|---|
|
|
208
|
-
| Missing DTO validation on an endpoint accepting user input | `blocker` | Exploitable vulnerability |
|
|
209
|
-
| String interpolation in raw SQL query | `blocker` | Exploitable vulnerability |
|
|
210
|
-
| Leaking stack trace / raw ORM error to API response | `blocker` | Exploitable vulnerability
|
|
207
|
+
| Missing DTO validation on an endpoint accepting user input | `blocker` with an attack vector stated (input, entry point, impact — `review-security-code` law); `major` with a named malformed input and wrong outcome; else `info` | Exploitable vulnerability only when the vector is shown |
|
|
208
|
+
| String interpolation in raw SQL query | `blocker` with an attack vector stated (input, entry point, impact); `major` with a named input and wrong outcome; else `info` | Exploitable vulnerability only when the vector is shown |
|
|
209
|
+
| Leaking stack trace / raw ORM error to API response | `blocker` with an attack vector stated (what is disclosed, to whom, through which entry point); `major` when the leak is shown reaching a response; else `info` | Exploitable vulnerability only when the vector is shown; a shown leak is a wrong outcome |
|
|
210
|
+
| Missing auth guard on an endpoint that should be protected | `blocker` with an attack vector stated (caller, entry point, impact); `major` with a named caller and the wrong outcome it gets; else `info` | Exploitable vulnerability only when the vector is shown |
|
|
211
211
|
| `REQUEST`-scoped provider injected into a `Singleton` | `blocker` | Data corruption — one request's state is served to another |
|
|
212
212
|
| Unhandled promise rejection in a controller method | `blocker` | Crash |
|
|
213
|
-
| `NOT NULL` column added without a default to a populated table | `blocker` | Data loss
|
|
214
|
-
| N+1 query (relation loaded in a loop) | `major`
|
|
213
|
+
| `NOT NULL` column added without a default to a populated table | `major` — the migration fails on deploy against existing rows; `blocker` only where the tool shown truncates or backfills wrong values | Data loss only when rows are shown destroyed or wrong. Same rating as `review-highload` |
|
|
214
|
+
| N+1 query (relation loaded in a loop) | `major` with the reachable loop size or call frequency named; else `info` | Cost stated with its frequency; degradation, not an outage |
|
|
215
215
|
| Missing transaction on a multi-step atomic mutation | `major` — `blocker` where a partial write corrupts persisted state | The outcome decides |
|
|
216
|
-
| Business logic in a controller | `major` | Layer violation. Same rating as `review-architecture` |
|
|
216
|
+
| Business logic in a controller | `minor` — `major` only with a concrete defect it causes (trigger and outcome) or a stated project rule it breaks | Layer violation. Same rating as `review-architecture` |
|
|
217
217
|
| Missing pagination on an unbounded list endpoint | `major` — `blocker` where an attacker-reachable request exhausts memory | Degradation vs. crash/DoS |
|
|
218
218
|
|
|
219
219
|
---
|
|
@@ -282,7 +282,7 @@ STATUS: DONE | DONE_WITH_CONCERNS | NEEDS_CONTEXT | BLOCKED
|
|
|
282
282
|
```markdown
|
|
283
283
|
# Backend Review Report
|
|
284
284
|
|
|
285
|
-
|
|
285
|
+
<!-- No merge verdict: the orchestrator owns it. A standalone run summarizes findings only. -->
|
|
286
286
|
|
|
287
287
|
## Summary
|
|
288
288
|
<2-4 sentences covering what changed, overall backend health, key concerns.>
|
|
@@ -343,8 +343,8 @@ When dispatched by `review-orchestrator` or `job-orchestrator`, the prompt MAY c
|
|
|
343
343
|
|----------------|-----------------|
|
|
344
344
|
| "ValidationPipe is probably configured somewhere" | Always verify it is applied; assumption lets injection reach service layer |
|
|
345
345
|
| "The N+1 only runs on small datasets now" | Data grows; flag it now with a clear fix, not after the incident |
|
|
346
|
-
| "The controller has some logic but it's minor" |
|
|
347
|
-
| "Stack trace in response only shows in dev" | Config can be wrong in prod;
|
|
346
|
+
| "The controller has some logic but it's minor" | Logic in a controller is `minor` unless a defect is named; say which, do not rate by feeling |
|
|
347
|
+
| "Stack trace in response only shows in dev" | Config can be wrong in prod; report it per the stack-trace row; blocker needs a shown vector |
|
|
348
348
|
| "I'll skip the migration check — it's just a column rename" | Column renames without fallback break zero-downtime deploys |
|
|
349
349
|
|
|
350
350
|
<!-- keryx:layers-block:start -->
|
|
@@ -18,7 +18,7 @@ triggers:
|
|
|
18
18
|
- "Uncle Bob review"
|
|
19
19
|
metadata:
|
|
20
20
|
author: "MrCipherSmith"
|
|
21
|
-
version: "1.
|
|
21
|
+
version: "1.2.0"
|
|
22
22
|
category: "review"
|
|
23
23
|
compatible_harnesses: "cursor,codex,zed,opencode,claude"
|
|
24
24
|
license: "MIT"
|
|
@@ -27,7 +27,7 @@ license: "MIT"
|
|
|
27
27
|
# Review: Clean Code + SOLID
|
|
28
28
|
|
|
29
29
|
Specialized reviewer for **Clean Code principles** (Robert C. Martin) and **SOLID** at the
|
|
30
|
-
function and class level. Focuses on code in the current branch diff only. Its inputs are the reviewer payload only; session memory and earlier conversation are not inputs. It runs no command unless its payload's `allowed_tools` says `run-tests`, except the read-only `git log`, `git blame` and `git show` where its host gives a read-only child git (keryx shell does not: there the payload supplies the history).
|
|
30
|
+
function and class level. Focuses on code in the current branch diff only. Its inputs are the reviewer payload only; session memory and earlier conversation are not inputs. It runs no command unless its payload's `allowed_tools` says `run-tests`, except the read-only `git log`, `git blame` and `git show` where its host gives a read-only child git (keryx shell does not: there the payload supplies the history), and the read-only layer commands the orchestrator lists (`keryx gdgraph affected|find`, `keryx test related`, `keryx wiki ask`, `keryx memory search`, `keryx ctx rg|read`); it never writes in the reviewed tree.
|
|
31
31
|
|
|
32
32
|
The goal is not stylistic nitpicking — every finding here points to a concrete
|
|
33
33
|
maintainability, readability, or extensibility problem that will cause friction
|
|
@@ -162,7 +162,7 @@ Clean Code guideline: functions should do **one thing** at one level of abstract
|
|
|
162
162
|
- [ ] Functions with a `And` or `Or` in the name, describing two operations
|
|
163
163
|
|
|
164
164
|
Flags:
|
|
165
|
-
- Function body >40 lines — **
|
|
165
|
+
- Function body >40 lines — **minor** (clear overload; flag specific function by name)
|
|
166
166
|
- Function body 20–40 lines with visible mixed abstraction — **minor**
|
|
167
167
|
- `doXAndY()` naming explicitly stating two operations — **minor**
|
|
168
168
|
|
|
@@ -176,8 +176,8 @@ Flags:
|
|
|
176
176
|
- [ ] Output arguments: a function that mutates its argument instead of returning a value (`populate(result)`)
|
|
177
177
|
|
|
178
178
|
Flags:
|
|
179
|
-
- Function with ≥4 parameters not using an options/config object — **
|
|
180
|
-
- Boolean flag parameter (`enabled: boolean`) passed to control function flow — **
|
|
179
|
+
- Function with ≥4 parameters not using an options/config object — **minor**
|
|
180
|
+
- Boolean flag parameter (`enabled: boolean`) passed to control function flow — **minor** (split into two functions)
|
|
181
181
|
- Output argument (mutating parameter instead of returning) — **minor**
|
|
182
182
|
- Three parameters where a plain named object would be clearer — **minor**
|
|
183
183
|
|
|
@@ -270,8 +270,8 @@ These are the correct uses of comments — do NOT flag:
|
|
|
270
270
|
- [ ] `catch (err: any)` — loses type safety; use `catch (err: unknown)`
|
|
271
271
|
|
|
272
272
|
Flags:
|
|
273
|
-
- `catch` block with empty body or only a comment — **major** (silent failure)
|
|
274
|
-
- Returning `null` / `undefined` from a function to signal "not found" in a critical path — **major**
|
|
273
|
+
- `catch` block with empty body or only a comment — **major** when a named failure is hidden from the caller (silent failure; conditions table), else **minor**
|
|
274
|
+
- Returning `null` / `undefined` from a function to signal "not found" in a critical path — **minor**; **major** only with a named trigger where the caller then produces a wrong outcome
|
|
275
275
|
- Log + rethrow in the same catch block — **minor**
|
|
276
276
|
- Untyped error in catch — **minor**
|
|
277
277
|
|
|
@@ -295,7 +295,7 @@ Flags:
|
|
|
295
295
|
- [ ] Multiple functions doing the same transformation with slightly different wrapping
|
|
296
296
|
|
|
297
297
|
Flags:
|
|
298
|
-
- 3+ identical or near-identical blocks in the diff that could be extracted — **
|
|
298
|
+
- 3+ identical or near-identical blocks in the diff that could be extracted — **minor** (Clean Code law 3; this lens owns duplication, `review-style` defers)
|
|
299
299
|
- 2 occurrences — **minor** (note, do not raise unless the pattern is clearly intentional duplication)
|
|
300
300
|
|
|
301
301
|
#### E2. Magic Numbers and Strings
|
|
@@ -323,8 +323,8 @@ A class should have **one reason to change**: one owner (one part of the system
|
|
|
323
323
|
- [ ] A constructor that does real work: making network calls, reading files, computing state — constructors should only assign
|
|
324
324
|
|
|
325
325
|
Flags:
|
|
326
|
-
- Class with two clearly distinct responsibilities that have different change drivers — **
|
|
327
|
-
- Constructor performing I/O or async operations — **major**
|
|
326
|
+
- Class with two clearly distinct responsibilities that have different change drivers — **minor**
|
|
327
|
+
- Constructor performing I/O or async operations — **minor**; **major** only with a named defect it causes (e.g. an unhandled rejection on construction)
|
|
328
328
|
- Service method doing validation + transformation + persistence inline — **minor**
|
|
329
329
|
|
|
330
330
|
#### F2. Open/Closed Principle (OCP)
|
|
@@ -348,8 +348,8 @@ Subtypes must be substitutable for their base types without changing the program
|
|
|
348
348
|
- [ ] Override that weakens postconditions (returns less than the parent guarantees)
|
|
349
349
|
|
|
350
350
|
Flags:
|
|
351
|
-
- Override throwing "not supported" — **major**
|
|
352
|
-
- Override requiring `instanceof` self-check — **
|
|
351
|
+
- Override throwing "not supported" — **minor**; **major** (or **blocker**) when a named call site reaches it through the base type (conditions table)
|
|
352
|
+
- Override requiring `instanceof` self-check — **minor**, same condition as the line above
|
|
353
353
|
|
|
354
354
|
#### F4. Interface Segregation Principle (ISP)
|
|
355
355
|
|
|
@@ -369,7 +369,7 @@ High-level modules should not depend on low-level modules. Both should depend on
|
|
|
369
369
|
- [ ] Class importing a concrete implementation class from another module instead of an interface/abstract class
|
|
370
370
|
|
|
371
371
|
Flags:
|
|
372
|
-
- `new ConcreteService()` inside a class method that should receive it via DI — **
|
|
372
|
+
- `new ConcreteService()` inside a class method that should receive it via DI — **minor**
|
|
373
373
|
- Import of concrete implementation where an interface or abstract type exists — **minor**
|
|
374
374
|
|
|
375
375
|
---
|
|
@@ -445,9 +445,9 @@ conditions land under that rubric, not a second rubric.
|
|
|
445
445
|
|---|---|---|
|
|
446
446
|
| Swallowed exception hiding a failed operation | `major` — `blocker` only if the caller then persists or returns wrong data | Same wording as `review-logic`, deliberately. Silent failure is wrong behaviour; corruption is a different shape |
|
|
447
447
|
| LSP violation that produces a wrong result or a crash at a named call site | `major`, or `blocker` on the crash/corruption outcome | The outcome decides, not the principle's name |
|
|
448
|
-
| Constructor performing I/O | `major`
|
|
448
|
+
| Constructor performing I/O | `minor` — `major` only with a named defect it causes (trigger and outcome) | The I/O running is not wrong behaviour; untestable is a maintenance cost |
|
|
449
449
|
| Function > 40 lines; ≥ 4 parameters without an options object; boolean flag argument; class with two distinct responsibilities; `new ConcreteService()` bypassing DI | `minor` | The code is correct. The cost is to whoever reads or edits it next — that is exactly `minor` |
|
|
450
|
-
| Poor naming; redundant comment; magic number; 20–40 line function; OCP/ISP smell; log-and-rethrow | `minor` | Same |
|
|
450
|
+
| Poor naming; redundant or stale comment; duplication (3+ sites); magic number; 20–40 line function; OCP/ISP smell; log-and-rethrow | `minor` | Same. This lens owns duplication and comments; `review-style` defers to it |
|
|
451
451
|
| Stylistic opinion; a future issue with no current violation | `info` | Neither trigger nor a named maintenance cost |
|
|
452
452
|
|
|
453
453
|
**Clean Code findings are `minor` by default.** A long function with a named
|
|
@@ -16,7 +16,7 @@ triggers:
|
|
|
16
16
|
- "review core boundaries"
|
|
17
17
|
metadata:
|
|
18
18
|
author: "MrCipherSmith"
|
|
19
|
-
version: "1.
|
|
19
|
+
version: "1.1.0"
|
|
20
20
|
category: "review"
|
|
21
21
|
license: "MIT"
|
|
22
22
|
---
|
|
@@ -24,7 +24,7 @@ license: "MIT"
|
|
|
24
24
|
# Review — Core Boundaries
|
|
25
25
|
|
|
26
26
|
Reviewer for shared infrastructure modules. A core module should provide stable foundations
|
|
27
|
-
used by feature modules; it should not accumulate feature-specific behaviour. Its inputs are the reviewer payload only; session memory and earlier conversation are not inputs. It runs no command unless its payload's `allowed_tools` says `run-tests`, except the read-only `git log`, `git blame` and `git show` where its host gives a read-only child git (keryx shell does not: there the payload supplies the history).
|
|
27
|
+
used by feature modules; it should not accumulate feature-specific behaviour. Its inputs are the reviewer payload only; session memory and earlier conversation are not inputs. It runs no command unless its payload's `allowed_tools` says `run-tests`, except the read-only `git log`, `git blame` and `git show` where its host gives a read-only child git (keryx shell does not: there the payload supplies the history), and the read-only layer commands the orchestrator lists (`keryx gdgraph affected|find`, `keryx test related`, `keryx wiki ask`, `keryx memory search`, `keryx ctx rg|read`); it never writes in the reviewed tree.
|
|
28
28
|
|
|
29
29
|
---
|
|
30
30
|
|