@solaqua/ghosts 0.4.27 → 0.4.29
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
CHANGED
|
@@ -53,6 +53,7 @@ For installation selectors, use the source path, such as `--include skills/code-
|
|
|
53
53
|
| Skill | What it helps with |
|
|
54
54
|
| --- | --- |
|
|
55
55
|
| [coding](engineering/skills/coding/SKILL.md) | Keep implementation simple and tests focused on meaningful behavior. |
|
|
56
|
+
| [yamato](engineering/skills/yamato/SKILL.md) | Implement, review and fix, then simplify the change in one workflow. |
|
|
56
57
|
| [code-review](engineering/skills/code-review/SKILL.md) | Review correctness, downstream contracts, design, and complexity; verify material safety assumptions without editing the change. |
|
|
57
58
|
| [test-review](engineering/skills/test-review/SKILL.md) | Find missing test protection and tests that cost more than they protect. |
|
|
58
59
|
| [docstring-review](engineering/skills/docstring-review/SKILL.md) | Find function summaries that obscure their domain purpose with implementation details. |
|
|
@@ -3,12 +3,14 @@ name: ghosts:code-review
|
|
|
3
3
|
description: Use only when the user explicitly requests a code review or invokes this skill. Do not trigger for implementation, debugging, refactoring, or routine verification requests. Performs a broad, read-only code review using general agents and complete result synthesis.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
Review the change read-only. Use two general subagents by default. Give each the change context
|
|
6
|
+
Review the change read-only. Use two general subagents by default. Give each the change context, the common instructions below, and its assigned question blocks. Do not add roles, review commands, or extra prompts.
|
|
7
7
|
|
|
8
8
|
Before assigning questions, the main agent identifies the key assumptions the change depends on and the affected boundaries, then uses them to guide its own verification in proportion to risk.
|
|
9
9
|
|
|
10
10
|
Consider every question below. Mark irrelevant questions `N/A — <reason>`. The main agent answers each applicable question. Assign applicable questions once across the selected subagents without overlap.
|
|
11
11
|
|
|
12
|
+
Common instructions:
|
|
13
|
+
|
|
12
14
|
```text
|
|
13
15
|
Review the change read-only:
|
|
14
16
|
|
|
@@ -16,16 +18,46 @@ Write findings and summaries using ISO 24495-1:2023 Plain Language principles.
|
|
|
16
18
|
|
|
17
19
|
AI-generated changes can overcomplicate simple problems; question whether added code or tests are needed at all, and consider omission before adding another layer.
|
|
18
20
|
|
|
19
|
-
- Any correctness or operational risks, including bugs, edge cases, race conditions, resource leaks, performance bottlenecks, scalability concerns, or security issues?
|
|
20
|
-
- Any downstream contract breaks beyond the diff: callers, persisted data, wire formats, cross-language consumers, feature flags, or lifecycle ordering? Trace concrete failure paths, including transitive dependencies; check pinned dependency versions and local patches where behavior depends on them.
|
|
21
|
-
- Any design or API issues when viewed from the intended caller's perspective and from outside-in, deep-module, and dependency-direction perspectives, including whether the module hides state, lifecycle, and ordering details, or exposes internal collaboration methods as public API; also consider hidden obligations, awkward call sites, leaky abstractions, or circular dependencies?
|
|
22
|
-
- Any unnecessary variables, intermediate state, interfaces, or abstractions that can be omitted? Could standard features, existing code reuse, a different design, or clearer naming solve the problem more simply?
|
|
23
|
-
- Any test smells or test-suite bloat—such as brittle or implementation-coupled tests, tautological tests that repeat the implementation or assert only mock setup, tests that only recheck documented dependency guarantees, over-mocking, conditional tests that bypass required assertions or choose expectations from actual results, unclear intent, missing negative-path coverage, surviving mutants, or redundant, overlapping, or low-signal tests whose maintenance, execution, and review costs outweigh the independent behavioral confidence they add? Any one-off checks retained as permanent regression tests, or hypothetical concurrency/timing tests without a credible execution path or meaningful failure impact? Could removal or consolidation preserve meaningful behavior, edge-case, and risk coverage? Any behavior already protected by existing tests beyond the diff, including through public entrypoints, judged by comparing scenarios and assertions rather than names alone? Could an existing case or suite be extended instead of adding a separate test, while preserving distinct behavior or regression coverage?
|
|
24
|
-
Flag every `if` statement or conditional expression in test code, including setup, helpers, and assertions. Require separate cases or parameterization with inputs and expected outcomes defined before execution instead of branching.
|
|
25
|
-
Do not request or retain tests that only recheck declared configuration or documented dependency behavior (for example, FastAPI/Pydantic's default 422 for an invalid field). Require a credible application-specific regression and an observable outcome.
|
|
26
21
|
Report findings with locations, evidence, and the smallest useful fix. Say when no actionable issue is found.
|
|
27
22
|
```
|
|
28
23
|
|
|
24
|
+
Question blocks:
|
|
25
|
+
|
|
26
|
+
```text
|
|
27
|
+
- Any correctness risks, including bugs or unhandled edge cases?
|
|
28
|
+
- Any race conditions, resource leaks, or lifecycle ordering risks?
|
|
29
|
+
- Any performance bottlenecks or scalability concerns?
|
|
30
|
+
- Any security issues?
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
```text
|
|
34
|
+
- Any downstream contract breaks affecting callers, persisted data, wire formats, cross-language consumers, or feature flags?
|
|
35
|
+
- Trace concrete failure paths beyond the diff, including transitive dependencies.
|
|
36
|
+
- Check pinned dependency versions and local patches where behavior depends on them.
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
```text
|
|
40
|
+
- Any design or API issues from the intended caller’s perspective, using outside-in and deep-module perspectives?
|
|
41
|
+
- Does the module expose internal collaboration methods or make callers manage state, lifecycle, ordering, or other hidden obligations?
|
|
42
|
+
- Any awkward call sites, leaky abstractions, circular dependencies, or dependency-direction issues?
|
|
43
|
+
- Any unjustified departures from patterns used by nearby code or code serving similar purposes, including naming, structure, error handling, or abstraction level? Prefer established conventions unless the task provides a concrete reason to differ.
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
```text
|
|
47
|
+
- Any unnecessary variables or intermediate state?
|
|
48
|
+
- Any unnecessary interfaces or abstractions?
|
|
49
|
+
- Could omission, standard features, existing code reuse, a different design, or clearer naming solve the problem more simply?
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
```text
|
|
53
|
+
- Any brittle or implementation-coupled tests, over-mocking, unclear intent, or tautological assertions that repeat the implementation or only verify mock setup?
|
|
54
|
+
- Any missing negative-path coverage or surviving mutants that reveal meaningful gaps?
|
|
55
|
+
- Any `if` statements or conditional expressions in tests, including setup, helpers, and assertions? Flag each; require separate cases or parameterization with inputs and expected outcomes defined before execution.
|
|
56
|
+
- Any tests that only recheck declared configuration or documented dependency behavior? Do not request or retain them; require a credible application-specific regression and an observable outcome.
|
|
57
|
+
- Any one-off checks kept as permanent tests, or concurrency or timing tests without a credible execution path and meaningful failure impact?
|
|
58
|
+
- Any redundant or low-signal tests whose costs outweigh their added confidence? Compare scenarios and assertions with existing tests beyond the diff, including public entrypoints. Prefer removal, consolidation, or extending an existing case when meaningful behavior, edge-case, and risk coverage is preserved.
|
|
59
|
+
```
|
|
60
|
+
|
|
29
61
|
After all agents respond and before synthesizing the final findings, triage every candidate point through this question: `Does this feedback identify a real, evidenced, material issue, or would addressing it add unnecessary complexity, flag a nonexistent or unsupported bug, or provide little value?` Judge the feedback itself, not only whether another agent made the same point. Do not omit any candidate point. Assign `P0`, `P1`, `P2`, or `P3` when it is actionable; assign `SKIP` only as a priority label when it is false, unsupported, duplicate, contradicted, out of scope, or not worth acting on. `SKIP` never means remove the item: every candidate must remain in `Findings` with its priority and the reason for that judgment. Do not leave skipped candidates only in `Reviewer Results`.
|
|
30
62
|
|
|
31
63
|
- Write in the user's language.
|
|
@@ -3,18 +3,22 @@ name: ghosts:coding
|
|
|
3
3
|
description: Use when writing, modifying, or refactoring code, including tests. Apply these coding standards during implementation.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
Use the checklist below during implementation. Before writing, identify the applicable items and inspect existing code with a similar role to guide the implementation.
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
After implementation, verify every applicable item against the final diff, relevant surrounding code, and checks where needed. Fix unmet items and recheck them; rerun affected checks after changes. Mark an item complete only when supported by what you inspected or ran, and mark irrelevant items `N/A` with a reason.
|
|
9
9
|
|
|
10
|
-
-
|
|
11
|
-
-
|
|
12
|
-
-
|
|
13
|
-
-
|
|
14
|
-
-
|
|
15
|
-
-
|
|
16
|
-
-
|
|
17
|
-
-
|
|
18
|
-
-
|
|
19
|
-
-
|
|
20
|
-
-
|
|
10
|
+
- [ ] Prefer omission, existing code reuse, and language or standard-library features over unnecessary variables, interfaces, abstractions, or tests.
|
|
11
|
+
- [ ] Design outside-in from caller usage and domain invariants.
|
|
12
|
+
- [ ] Hide internal state, lifecycle, ordering, and retry details that callers need not manage.
|
|
13
|
+
- [ ] Revisit abstractions that require repeated workarounds or type escape hatches. If successive fixes fail under the same premise, challenge that premise before patching again.
|
|
14
|
+
- [ ] Prefer a rerunnable tool when it reduces execution or verification cost.
|
|
15
|
+
- [ ] Follow naming, structure, error-handling, and abstraction conventions from nearby code or code with a similar role, unless there is a concrete reason to differ.
|
|
16
|
+
- [ ] Order functions so each callee appears below its caller.
|
|
17
|
+
- [ ] Write function and method docstring and TSDoc summaries as concise statements of purpose in domain terms. Describe what the function accomplishes without narrating internal steps or enumerating permissions, side effects, and error handling. Prefer summaries that remain accurate as fields or conditions are added, provided the function's purpose stays the same. Add contract details separately only when callers need them to use the function correctly. Prefer one sentence; expand only when necessary.
|
|
18
|
+
- [ ] Write tests as behavioral specifications: each test docstring or doc comment must stand alone, describe the scenario and observable outcome, and avoid relying on surrounding context, implementation details, or comparative wording. Keep names concise and behavior-based (JS/TS `it(...)` / `test(...)` descriptions suffice), and structure the body with Gherkin keywords (`Given`, `When`, `Then`, `And`) as appropriate.
|
|
19
|
+
- [ ] Never use `if` statements or conditional expressions in test code, including setup, helpers, and assertions. Define each case's inputs and expected outcomes before execution; use separate cases or parameterization instead of branching.
|
|
20
|
+
- [ ] When complex setup, concurrency, timing, or multi-step control flow makes a test hard to follow, add concise comments at key transitions to explain the scenario and synchronization; do not narrate obvious code.
|
|
21
|
+
- [ ] Add tests only for meaningful current, externally observable behavior or substantive regression risks; prefer outside-in integration tests through public interfaces. Avoid brittle, implementation-coupled, over-mocked tests and assertions that merely restate literals, constants, configuration wiring, or documented dependency guarantees. Do not add temporary tests for intermediate layers better covered by a planned integration test unless omission leaves an immediate regression or safety gap.
|
|
22
|
+
- [ ] Search existing tests beyond the diff and compare scenarios and assertions before adding coverage. Extend an existing case or suite when it clearly covers the behavior; add separate tests only for independent behavioral confidence or a distinct regression risk. Update or remove obsolete tests, including tests for intentionally removed paths.
|
|
23
|
+
- [ ] Do not expose private members solely for testing.
|
|
24
|
+
- [ ] Do not preserve backward compatibility. Remove obsolete paths instead of adding compatibility layers, fallbacks, or migrations.
|
|
@@ -23,8 +23,8 @@ For delegated implementation, send the task and the complete workflow in one pro
|
|
|
23
23
|
|
|
24
24
|
```text
|
|
25
25
|
1. Implement the task.
|
|
26
|
-
2. After implementation, invoke ghosts:code-review. When the read-only review is complete, fix applicable findings. Skip fixes if there are none.
|
|
27
|
-
3. After review and any fixes, invoke ghosts:slop-shaking and apply useful cleanups.
|
|
26
|
+
2. After implementation, invoke $ghosts:code-review. When the read-only review is complete, fix applicable findings. Skip fixes if there are none.
|
|
27
|
+
3. After review and any fixes, invoke $ghosts:slop-shaking and apply useful cleanups.
|
|
28
28
|
|
|
29
29
|
Apply each skill at its stage. Complete the workflow and report results, or explain what blocks completion.
|
|
30
30
|
```
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ghosts:yamato
|
|
3
|
+
description: Implement a task, review and fix the change, then remove unnecessary complexity.
|
|
4
|
+
disable-model-invocation: true
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Run these stages in order in the current session. Read and follow each skill when its stage begins:
|
|
8
|
+
|
|
9
|
+
1. Apply $ghosts:coding to implement the task and verify its checklist.
|
|
10
|
+
2. Run $ghosts:code-review. After the read-only review, fix applicable findings and verify the fixes. Skip fixes if there are none.
|
|
11
|
+
3. Run $ghosts:slop-shaking and apply useful cleanups.
|
|
12
|
+
|
|
13
|
+
Continue through all stages unless a blocker requires user input.
|
package/package.json
CHANGED
package/registry/skul.refs.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"target": "skills",
|
|
5
5
|
"name": "insane-search",
|
|
6
6
|
"source": "fivetaku/insane-search",
|
|
7
|
-
"ref": "
|
|
7
|
+
"ref": "82211894339e45e7e848c54d47ef4743460bd5df"
|
|
8
8
|
},
|
|
9
9
|
{
|
|
10
10
|
"target": "skills",
|
|
@@ -16,13 +16,13 @@
|
|
|
16
16
|
"target": "skills",
|
|
17
17
|
"name": "context7-cli",
|
|
18
18
|
"source": "upstash/context7",
|
|
19
|
-
"ref": "
|
|
19
|
+
"ref": "6e68ffcbad0e23cf4fa8c11795ce9e551aeef19b"
|
|
20
20
|
},
|
|
21
21
|
{
|
|
22
22
|
"target": "skills",
|
|
23
23
|
"name": "ego-browser",
|
|
24
24
|
"source": "citrolabs/ego-lite",
|
|
25
|
-
"ref": "
|
|
25
|
+
"ref": "bacaece43900e8ca68eea3b6f1663835ea38df9e"
|
|
26
26
|
},
|
|
27
27
|
{
|
|
28
28
|
"target": "skills",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"target": "skills",
|
|
36
36
|
"name": "orca-cli",
|
|
37
37
|
"source": "stablyai/orca",
|
|
38
|
-
"ref": "
|
|
38
|
+
"ref": "7777f352d83180e447495d5e69bd9f8840dd628b"
|
|
39
39
|
},
|
|
40
40
|
{
|
|
41
41
|
"target": "skills",
|