vstack 0.0.0__py3-none-any.whl
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.
- vstack/__init__.py +5 -0
- vstack/__main__.py +5 -0
- vstack/_templates/agents/_partials/agent-skill-boundary.md +5 -0
- vstack/_templates/agents/architect/config.yaml +38 -0
- vstack/_templates/agents/architect/template.md +84 -0
- vstack/_templates/agents/designer/config.yaml +36 -0
- vstack/_templates/agents/designer/template.md +99 -0
- vstack/_templates/agents/engineer/config.yaml +36 -0
- vstack/_templates/agents/engineer/template.md +88 -0
- vstack/_templates/agents/product/config.yaml +37 -0
- vstack/_templates/agents/product/template.md +87 -0
- vstack/_templates/agents/release/config.yaml +35 -0
- vstack/_templates/agents/release/template.md +86 -0
- vstack/_templates/agents/tester/config.yaml +41 -0
- vstack/_templates/agents/tester/template.md +90 -0
- vstack/_templates/instructions/git/config.yaml +4 -0
- vstack/_templates/instructions/git/template.md +36 -0
- vstack/_templates/instructions/python/config.yaml +4 -0
- vstack/_templates/instructions/python/template.md +37 -0
- vstack/_templates/prompts/code-review/config.yaml +10 -0
- vstack/_templates/prompts/code-review/template.md +39 -0
- vstack/_templates/skills/_partials/base-branch.md +8 -0
- vstack/_templates/skills/_partials/observability-checklist.md +36 -0
- vstack/_templates/skills/_partials/run-tests.md +22 -0
- vstack/_templates/skills/_partials/skill-context.md +21 -0
- vstack/_templates/skills/adr/config.yaml +17 -0
- vstack/_templates/skills/adr/template.md +167 -0
- vstack/_templates/skills/analyse/config.yaml +16 -0
- vstack/_templates/skills/analyse/template.md +188 -0
- vstack/_templates/skills/architecture/config.yaml +18 -0
- vstack/_templates/skills/architecture/template.md +213 -0
- vstack/_templates/skills/cicd/config.yaml +16 -0
- vstack/_templates/skills/cicd/template.md +169 -0
- vstack/_templates/skills/code-review/config.yaml +16 -0
- vstack/_templates/skills/code-review/template.md +180 -0
- vstack/_templates/skills/concise/config.yaml +16 -0
- vstack/_templates/skills/concise/template.md +128 -0
- vstack/_templates/skills/consult/config.yaml +18 -0
- vstack/_templates/skills/consult/template.md +195 -0
- vstack/_templates/skills/container/config.yaml +17 -0
- vstack/_templates/skills/container/template.md +122 -0
- vstack/_templates/skills/debug/config.yaml +16 -0
- vstack/_templates/skills/debug/template.md +247 -0
- vstack/_templates/skills/dependency/config.yaml +18 -0
- vstack/_templates/skills/dependency/template.md +293 -0
- vstack/_templates/skills/design/config.yaml +16 -0
- vstack/_templates/skills/design/template.md +231 -0
- vstack/_templates/skills/docs/config.yaml +17 -0
- vstack/_templates/skills/docs/template.md +128 -0
- vstack/_templates/skills/explore/config.yaml +17 -0
- vstack/_templates/skills/explore/template.md +188 -0
- vstack/_templates/skills/guardrails/config.yaml +16 -0
- vstack/_templates/skills/guardrails/template.md +45 -0
- vstack/_templates/skills/incident/config.yaml +17 -0
- vstack/_templates/skills/incident/template.md +293 -0
- vstack/_templates/skills/inspect/config.yaml +16 -0
- vstack/_templates/skills/inspect/template.md +105 -0
- vstack/_templates/skills/migrate/config.yaml +17 -0
- vstack/_templates/skills/migrate/template.md +298 -0
- vstack/_templates/skills/onboard/config.yaml +18 -0
- vstack/_templates/skills/onboard/template.md +289 -0
- vstack/_templates/skills/openapi/config.yaml +17 -0
- vstack/_templates/skills/openapi/template.md +382 -0
- vstack/_templates/skills/performance/config.yaml +15 -0
- vstack/_templates/skills/performance/template.md +198 -0
- vstack/_templates/skills/pr/config.yaml +15 -0
- vstack/_templates/skills/pr/template.md +108 -0
- vstack/_templates/skills/refactor/config.yaml +18 -0
- vstack/_templates/skills/refactor/template.md +283 -0
- vstack/_templates/skills/release-notes/config.yaml +16 -0
- vstack/_templates/skills/release-notes/template.md +127 -0
- vstack/_templates/skills/requirements/config.yaml +17 -0
- vstack/_templates/skills/requirements/template.md +187 -0
- vstack/_templates/skills/security/config.yaml +17 -0
- vstack/_templates/skills/security/template.md +256 -0
- vstack/_templates/skills/verify/config.yaml +17 -0
- vstack/_templates/skills/verify/template.md +201 -0
- vstack/_templates/skills/vision/config.yaml +19 -0
- vstack/_templates/skills/vision/template.md +169 -0
- vstack/agents/__init__.py +5 -0
- vstack/agents/config.py +67 -0
- vstack/agents/constants.py +14 -0
- vstack/agents/generator.py +20 -0
- vstack/artifacts/__init__.py +17 -0
- vstack/artifacts/config.py +111 -0
- vstack/artifacts/constants.py +6 -0
- vstack/artifacts/generator.py +406 -0
- vstack/artifacts/models.py +55 -0
- vstack/artifacts/protocol.py +50 -0
- vstack/cli/__init__.py +3 -0
- vstack/cli/commands.py +596 -0
- vstack/cli/constants.py +33 -0
- vstack/cli/manifest.py +166 -0
- vstack/cli/parser.py +156 -0
- vstack/constants.py +84 -0
- vstack/frontmatter/__init__.py +8 -0
- vstack/frontmatter/parser.py +272 -0
- vstack/frontmatter/schema.py +142 -0
- vstack/frontmatter/serializer.py +208 -0
- vstack/instructions/__init__.py +5 -0
- vstack/instructions/config.py +21 -0
- vstack/instructions/constants.py +9 -0
- vstack/instructions/generator.py +13 -0
- vstack/main.py +71 -0
- vstack/models.py +35 -0
- vstack/prompts/__init__.py +5 -0
- vstack/prompts/config.py +21 -0
- vstack/prompts/constants.py +9 -0
- vstack/prompts/generator.py +13 -0
- vstack/skills/__init__.py +5 -0
- vstack/skills/config.py +58 -0
- vstack/skills/constants.py +17 -0
- vstack/skills/generator.py +20 -0
- vstack/skills/models.py +15 -0
- vstack-0.0.0.dist-info/METADATA +725 -0
- vstack-0.0.0.dist-info/RECORD +119 -0
- vstack-0.0.0.dist-info/WHEEL +4 -0
- vstack-0.0.0.dist-info/entry_points.txt +3 -0
- vstack-0.0.0.dist-info/licenses/LICENSE +21 -0
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
{{SKILL_CONTEXT}}
|
|
2
|
+
|
|
3
|
+
{{BASE_BRANCH}}
|
|
4
|
+
|
|
5
|
+
# code-review — Pre-Landing Code Review
|
|
6
|
+
|
|
7
|
+
Review code before merging. Find bugs that pass CI but break in production.
|
|
8
|
+
Report findings; do not change code unless explicitly asked.
|
|
9
|
+
|
|
10
|
+
## Out of scope
|
|
11
|
+
|
|
12
|
+
- Full security audit (use `security`)
|
|
13
|
+
- Performance benchmarking (use `performance`)
|
|
14
|
+
- Architecture design decisions (use `architecture`)
|
|
15
|
+
- Running the test suite (use `verify`)
|
|
16
|
+
|
|
17
|
+
Find bugs that will pass CI but break in production. Be specific — name files, lines, and
|
|
18
|
+
scenarios. Be opinionated — give a recommendation, not just observations.
|
|
19
|
+
|
|
20
|
+
## Review Principles
|
|
21
|
+
|
|
22
|
+
- **API contracts are public promises.** Breaking changes must be flagged and versioned.
|
|
23
|
+
- **Silent failures are catastrophic.** Every error path must be visible.
|
|
24
|
+
- **Systems over heroes.** Code that requires intimate knowledge to debug safely is a liability.
|
|
25
|
+
- **Observability is scope.** New codepaths without logs/metrics/traces are incomplete.
|
|
26
|
+
- **Security is non-negotiable.** Authentication bypass, injection vulnerabilities, and secrets in code are blocking issues.
|
|
27
|
+
|
|
28
|
+
## Step 0: Branch & Diff Setup
|
|
29
|
+
|
|
30
|
+
```bash
|
|
31
|
+
# Confirm we're on a feature branch, not base
|
|
32
|
+
CURRENT=$(git branch --show-current)
|
|
33
|
+
echo "Current branch: $CURRENT"
|
|
34
|
+
echo "Base branch: <base>"
|
|
35
|
+
|
|
36
|
+
# Show what this PR changes
|
|
37
|
+
git diff <base> --stat | head -40
|
|
38
|
+
git log <base>..HEAD --oneline
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
If on the base branch, STOP:
|
|
42
|
+
|
|
43
|
+
> You appear to be on the base branch ($CURRENT). Review is most useful on a feature branch. Are you sure you want to continue reviewing uncommitted changes?
|
|
44
|
+
|
|
45
|
+
## Step 1: Context Read
|
|
46
|
+
|
|
47
|
+
Before reviewing diffs, read:
|
|
48
|
+
|
|
49
|
+
1. The PR description / task description (if provided)
|
|
50
|
+
1. Any design docs referenced
|
|
51
|
+
1. Relevant existing code that the diff builds upon
|
|
52
|
+
|
|
53
|
+
```bash
|
|
54
|
+
# Read TODOS.md for context on deferred work
|
|
55
|
+
cat TODOS.md 2>/dev/null | head -30 || true
|
|
56
|
+
# Check for API spec
|
|
57
|
+
cat openapi.yaml 2>/dev/null | head -50 || cat openapi.json 2>/dev/null | head -50 || true
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## Step 2: Diff Review
|
|
61
|
+
|
|
62
|
+
```bash
|
|
63
|
+
git diff <base> -- $(git diff <base> --name-only | grep -v node_modules | grep -v vendor | head -30)
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
Review each changed file for:
|
|
67
|
+
|
|
68
|
+
### 2.1 API Contract
|
|
69
|
+
|
|
70
|
+
- [ ] Any new or changed endpoints listed in OpenAPI/spec?
|
|
71
|
+
- [ ] Breaking changes? (field removal, type change, status code change)
|
|
72
|
+
- [ ] Error responses consistent with API conventions?
|
|
73
|
+
- [ ] Pagination/filtering contracts consistent?
|
|
74
|
+
|
|
75
|
+
### 2.2 Error Handling
|
|
76
|
+
|
|
77
|
+
- [ ] Every exception has a name, a handler, and a user-visible representation?
|
|
78
|
+
- [ ] No bare `catch (e) {}` or `except Exception: pass`?
|
|
79
|
+
- [ ] HTTP 5xx vs 4xx used correctly?
|
|
80
|
+
- [ ] Timeouts set on all external calls?
|
|
81
|
+
- [ ] Retry logic present where needed? Are operations idempotent?
|
|
82
|
+
|
|
83
|
+
### 2.3 Data Integrity
|
|
84
|
+
|
|
85
|
+
- [ ] Database migrations backward-compatible? (expand-contract pattern)
|
|
86
|
+
- [ ] No raw SQL vulnerable to injection?
|
|
87
|
+
- [ ] Transactions used where multiple writes must be atomic?
|
|
88
|
+
- [ ] Optimistic locking where concurrent writes are possible?
|
|
89
|
+
- [ ] No unbounded queries (missing LIMIT, full table scan)?
|
|
90
|
+
|
|
91
|
+
### 2.4 Distributed Systems
|
|
92
|
+
|
|
93
|
+
- [ ] All state-mutating external calls are idempotent?
|
|
94
|
+
- [ ] Circuit breakers / bulkheads present for critical dependencies?
|
|
95
|
+
- [ ] No synchronous cascade — single slow dependency can't block the whole request?
|
|
96
|
+
- [ ] Eventual consistency acknowledged where applicable?
|
|
97
|
+
- [ ] Message deduplication strategy for async consumers?
|
|
98
|
+
|
|
99
|
+
### 2.5 Security
|
|
100
|
+
|
|
101
|
+
- [ ] Authentication checked at every new endpoint?
|
|
102
|
+
- [ ] Authorization checked — not just "is logged in" but "has permission for THIS resource"?
|
|
103
|
+
- [ ] All user-controlled input validated and sanitized?
|
|
104
|
+
- [ ] No secrets, credentials, or PII in logs?
|
|
105
|
+
- [ ] Secrets in secure storage, not hardcoded or in env files?
|
|
106
|
+
- [ ] CSRF protection for state-mutating endpoints?
|
|
107
|
+
|
|
108
|
+
### 2.6 Observability
|
|
109
|
+
|
|
110
|
+
- [ ] New codepaths emit structured logs with correlation IDs?
|
|
111
|
+
- [ ] Error paths logged at ERROR level with stack traces?
|
|
112
|
+
- [ ] New metrics/counters/histograms added for new operations?
|
|
113
|
+
- [ ] Distributed trace spans for cross-service calls?
|
|
114
|
+
- [ ] New failure modes visible in existing dashboards / alerts?
|
|
115
|
+
|
|
116
|
+
### 2.7 Testing
|
|
117
|
+
|
|
118
|
+
- [ ] Tests cover happy path AND error paths?
|
|
119
|
+
- [ ] Test coverage adequate for risk level?
|
|
120
|
+
- [ ] Tests don't rely on implementation details (test behavior, not internals)?
|
|
121
|
+
- [ ] No flaky tests introduced (timing-dependent, order-dependent)?
|
|
122
|
+
- [ ] Contract tests added or updated for API changes?
|
|
123
|
+
|
|
124
|
+
### 2.8 Performance
|
|
125
|
+
|
|
126
|
+
- [ ] No N+1 database queries?
|
|
127
|
+
- [ ] Expensive operations cached where appropriate?
|
|
128
|
+
- [ ] No unbounded data loads (always paginated)?
|
|
129
|
+
- [ ] Sync operations that should be async?
|
|
130
|
+
|
|
131
|
+
### 2.9 Code Quality
|
|
132
|
+
|
|
133
|
+
- [ ] DRY — no copy-pasted logic?
|
|
134
|
+
- [ ] Functions/methods do one thing?
|
|
135
|
+
- [ ] Naming is clear and consistent with codebase conventions?
|
|
136
|
+
- [ ] No magic numbers/strings without named constants?
|
|
137
|
+
- [ ] Comments explain WHY, not WHAT?
|
|
138
|
+
|
|
139
|
+
## Step 3: Checklist Enforcement
|
|
140
|
+
|
|
141
|
+
Check for a project-specific review checklist:
|
|
142
|
+
|
|
143
|
+
```bash
|
|
144
|
+
cat .github/PULL_REQUEST_TEMPLATE.md 2>/dev/null || true
|
|
145
|
+
cat docs/review-checklist.md 2>/dev/null || true
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
If a project-specific checklist exists, verify each item.
|
|
149
|
+
|
|
150
|
+
## Step 4: Final Report
|
|
151
|
+
|
|
152
|
+
For each issue found, classify:
|
|
153
|
+
|
|
154
|
+
- **BLOCKING:** Must be fixed before merge. (Security, data integrity, silent failures, broken API contracts)
|
|
155
|
+
- **IMPORTANT:** Should be fixed in this PR. (Missing tests, error handling gaps, observability)
|
|
156
|
+
- **SUGGESTION:** Consider for this PR or defer. (Refactoring, style, non-blocking improvements)
|
|
157
|
+
|
|
158
|
+
Format:
|
|
159
|
+
|
|
160
|
+
```text
|
|
161
|
+
## Code Review — [branch name] — [date]
|
|
162
|
+
|
|
163
|
+
### BLOCKING Issues (must fix before merge)
|
|
164
|
+
1. **[Category]** `path/to/file.ts:42` — [Issue description]
|
|
165
|
+
Evidence: [specific code or behavior]
|
|
166
|
+
Fix: [recommended change]
|
|
167
|
+
|
|
168
|
+
### IMPORTANT Issues (should fix in this PR)
|
|
169
|
+
...
|
|
170
|
+
|
|
171
|
+
### SUGGESTIONS (optional improvements)
|
|
172
|
+
...
|
|
173
|
+
|
|
174
|
+
### Overall Assessment
|
|
175
|
+
[APPROVED / APPROVED WITH SUGGESTIONS / REQUEST CHANGES]
|
|
176
|
+
|
|
177
|
+
Confidence: [HIGH/MEDIUM/LOW — explain if not HIGH]
|
|
178
|
+
```
|
|
179
|
+
|
|
180
|
+
______________________________________________________________________
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
name: concise
|
|
2
|
+
version: 1.0.1
|
|
3
|
+
description: |
|
|
4
|
+
Runtime response-style controller for concise communication. Switches between
|
|
5
|
+
normal, compact, and ultra output density without regenerating agents. Use
|
|
6
|
+
when asked for shorter responses, token efficiency, or to check active style
|
|
7
|
+
mode.
|
|
8
|
+
argument-hint: '[normal|compact|ultra|status|on|off]'
|
|
9
|
+
|
|
10
|
+
license: MIT
|
|
11
|
+
compatibility: Requires a skills-compatible agent with session memory and repository context.
|
|
12
|
+
metadata:
|
|
13
|
+
owner: vstack
|
|
14
|
+
maturity: stable
|
|
15
|
+
user-invocable: true
|
|
16
|
+
disable-model-invocation: false
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
{{SKILL_CONTEXT}}
|
|
2
|
+
|
|
3
|
+
# concise — Runtime Response Style Mode
|
|
4
|
+
|
|
5
|
+
Control response brevity at runtime without regenerating any agent artifacts.
|
|
6
|
+
|
|
7
|
+
## Out of scope
|
|
8
|
+
|
|
9
|
+
- Rewriting or mutating source code, scripts, commands, or API contracts
|
|
10
|
+
- Persisting style mode across independent chat sessions
|
|
11
|
+
- Overriding safety-critical clarity requirements
|
|
12
|
+
|
|
13
|
+
______________________________________________________________________
|
|
14
|
+
|
|
15
|
+
## Commands
|
|
16
|
+
|
|
17
|
+
Supported commands:
|
|
18
|
+
|
|
19
|
+
- `concise normal`
|
|
20
|
+
- `concise compact`
|
|
21
|
+
- `concise ultra`
|
|
22
|
+
- `concise status`
|
|
23
|
+
|
|
24
|
+
Compatibility aliases:
|
|
25
|
+
|
|
26
|
+
- `concise on` -> `concise compact`
|
|
27
|
+
- `concise off` -> `concise normal`
|
|
28
|
+
|
|
29
|
+
Unknown arguments:
|
|
30
|
+
|
|
31
|
+
- If argument is unknown, do not guess. Return usage and keep current mode unchanged.
|
|
32
|
+
|
|
33
|
+
______________________________________________________________________
|
|
34
|
+
|
|
35
|
+
## Mode Semantics
|
|
36
|
+
|
|
37
|
+
- `normal`: full, explicit explanation depth.
|
|
38
|
+
- `compact`: default concise mode; shorter prose, unchanged technical accuracy.
|
|
39
|
+
- `ultra`: maximal brevity; remove narrative filler, keep technical correctness.
|
|
40
|
+
|
|
41
|
+
Hard invariants for all concise modes:
|
|
42
|
+
|
|
43
|
+
- Keep code blocks, commands, paths, and symbols exact.
|
|
44
|
+
- Do not remove required warnings, constraints, or irreversible-action cautions.
|
|
45
|
+
- Never trade correctness for brevity.
|
|
46
|
+
|
|
47
|
+
______________________________________________________________________
|
|
48
|
+
|
|
49
|
+
## Priority and Resolution
|
|
50
|
+
|
|
51
|
+
Resolve active mode with this precedence:
|
|
52
|
+
|
|
53
|
+
1. Explicit user command in current turn (`concise ...`)
|
|
54
|
+
1. Session override (last accepted concise mode command)
|
|
55
|
+
1. Agent default mode
|
|
56
|
+
1. Global default mode (`normal`)
|
|
57
|
+
|
|
58
|
+
`concise status` must show:
|
|
59
|
+
|
|
60
|
+
- active mode
|
|
61
|
+
- session override value (or none)
|
|
62
|
+
- agent default mode
|
|
63
|
+
- global default mode
|
|
64
|
+
- whether auto-clarity override is currently active
|
|
65
|
+
|
|
66
|
+
______________________________________________________________________
|
|
67
|
+
|
|
68
|
+
## Suggested Agent Defaults
|
|
69
|
+
|
|
70
|
+
When no session override exists, use these defaults:
|
|
71
|
+
|
|
72
|
+
- `product`: `compact`
|
|
73
|
+
- `architect`: `normal`
|
|
74
|
+
- `designer`: `compact`
|
|
75
|
+
- `engineer`: `compact`
|
|
76
|
+
- `tester`: `ultra`
|
|
77
|
+
- `release`: `compact`
|
|
78
|
+
|
|
79
|
+
______________________________________________________________________
|
|
80
|
+
|
|
81
|
+
## Auto-Clarity Override (Mandatory)
|
|
82
|
+
|
|
83
|
+
Temporarily force `normal` regardless of active concise mode for:
|
|
84
|
+
|
|
85
|
+
- security warnings
|
|
86
|
+
- destructive or irreversible actions
|
|
87
|
+
- multi-step sequences where truncation can cause ordering mistakes
|
|
88
|
+
- user confusion or repeated clarification requests
|
|
89
|
+
|
|
90
|
+
After the high-clarity segment ends, return to previously active concise mode.
|
|
91
|
+
|
|
92
|
+
______________________________________________________________________
|
|
93
|
+
|
|
94
|
+
## Expected Responses
|
|
95
|
+
|
|
96
|
+
On successful mode switch:
|
|
97
|
+
|
|
98
|
+
```text
|
|
99
|
+
Concise mode set to <mode>.
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
On status request:
|
|
103
|
+
|
|
104
|
+
```text
|
|
105
|
+
concise status
|
|
106
|
+
active: <mode>
|
|
107
|
+
session override: <value|none>
|
|
108
|
+
agent default: <mode>
|
|
109
|
+
global default: normal
|
|
110
|
+
auto-clarity override: <active|inactive>
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
On invalid argument:
|
|
114
|
+
|
|
115
|
+
```text
|
|
116
|
+
Unknown concise mode: <value>
|
|
117
|
+
Usage: concise normal|compact|ultra|status|on|off
|
|
118
|
+
Current mode unchanged: <mode>
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
______________________________________________________________________
|
|
122
|
+
|
|
123
|
+
## Completion Checklist
|
|
124
|
+
|
|
125
|
+
- [ ] Command parsed and validated
|
|
126
|
+
- [ ] Mode switched or preserved according to rules
|
|
127
|
+
- [ ] Safety/clarity override honored where required
|
|
128
|
+
- [ ] User confirmation/status returned in deterministic format
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
name: consult
|
|
2
|
+
version: 1.0.2
|
|
3
|
+
description: |
|
|
4
|
+
DX triage and focused review. First classifies whether the request is API DX,
|
|
5
|
+
CLI/tool DX, or developer workflow DX, then runs exactly one review path with
|
|
6
|
+
0-10 scoring and ROI-ranked improvements. Routes non-DX requests to the right
|
|
7
|
+
specialized skill (analyse/debug/security/performance/design/verify/code-review).
|
|
8
|
+
Use when asked to "review DX", "review API usability", "review CLI experience",
|
|
9
|
+
or "review developer workflow friction".
|
|
10
|
+
argument-hint: '[API, tool, or workflow to consult]'
|
|
11
|
+
|
|
12
|
+
license: MIT
|
|
13
|
+
compatibility: Requires a skills-compatible agent with repository file access and terminal command execution when needed.
|
|
14
|
+
metadata:
|
|
15
|
+
owner: vstack
|
|
16
|
+
maturity: stable
|
|
17
|
+
user-invocable: true
|
|
18
|
+
disable-model-invocation: false
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
{{SKILL_CONTEXT}}
|
|
2
|
+
|
|
3
|
+
# consult — DX Triage and Focused Review
|
|
4
|
+
|
|
5
|
+
Classify the request first, then run exactly one focused DX review path.
|
|
6
|
+
If the request is not DX-focused, route to the correct specialized skill.
|
|
7
|
+
Read only — do not change any code.
|
|
8
|
+
|
|
9
|
+
## Out of scope
|
|
10
|
+
|
|
11
|
+
- Building or redesigning APIs from scratch (use `design`)
|
|
12
|
+
- Implementation of improvements (engineering role)
|
|
13
|
+
- Full verification or contract testing (use `verify`)
|
|
14
|
+
- Architecture decisions (use `architecture`)
|
|
15
|
+
- Root-cause debugging (use `debug`)
|
|
16
|
+
- Security audits (use `security`)
|
|
17
|
+
- Performance profiling/regression analysis (use `performance`)
|
|
18
|
+
- Tradeoff/impact/feasibility analysis (use `analyse`)
|
|
19
|
+
|
|
20
|
+
______________________________________________________________________
|
|
21
|
+
|
|
22
|
+
## Step 0: Classify and Route
|
|
23
|
+
|
|
24
|
+
Determine the user's real intent before reviewing anything.
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
# Quick context snapshot
|
|
28
|
+
ls openapi.yaml openapi.json asyncapi.yaml 2>/dev/null | head -5 || true
|
|
29
|
+
cat README.md 2>/dev/null | head -25 || true
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
> **Question:** Which path matches the request best?
|
|
33
|
+
> **Options:**
|
|
34
|
+
> A) API DX review
|
|
35
|
+
> B) CLI/tool DX review
|
|
36
|
+
> C) Developer workflow DX review (onboarding/CI/tooling)
|
|
37
|
+
> D) Not DX (route to another skill)
|
|
38
|
+
> **Default if no response:** A
|
|
39
|
+
|
|
40
|
+
If D, stop and return this routing recommendation:
|
|
41
|
+
|
|
42
|
+
- API/service design from scratch -> `design`
|
|
43
|
+
- Technical impact/tradeoff analysis -> `analyse`
|
|
44
|
+
- Root-cause investigation -> `debug`
|
|
45
|
+
- Pre-merge risk review -> `code-review`
|
|
46
|
+
- Security audit -> `security`
|
|
47
|
+
- Performance profiling/regression check -> `performance`
|
|
48
|
+
- Verification/fix loop -> `verify`
|
|
49
|
+
|
|
50
|
+
Do not continue with DX scoring when routing to another skill.
|
|
51
|
+
|
|
52
|
+
______________________________________________________________________
|
|
53
|
+
|
|
54
|
+
## Step 1: Run Exactly One Path
|
|
55
|
+
|
|
56
|
+
Run only the selected path (A, B, or C). Skip all others.
|
|
57
|
+
|
|
58
|
+
### Path A — API DX Review
|
|
59
|
+
|
|
60
|
+
Rate each dimension 0-10. Explain the current score and what a 10 looks like.
|
|
61
|
+
|
|
62
|
+
#### A1. Naming and Consistency
|
|
63
|
+
|
|
64
|
+
- Are resource names plural nouns? (`/users`, not `/user`, `/getUser`)
|
|
65
|
+
- Are action names consistent? (REST verbs via HTTP method, not in path)
|
|
66
|
+
- Are field names consistently cased? (camelCase or snake_case — not mixed)
|
|
67
|
+
- Are boolean flags named clearly? (`is_active`, not `active`)
|
|
68
|
+
- Are error codes human-readable? (`INVALID_EMAIL`, not `ERR_400_02`)
|
|
69
|
+
|
|
70
|
+
#### A2. Error UX
|
|
71
|
+
|
|
72
|
+
- Does every error response include a human-readable `message`?
|
|
73
|
+
- Does every error include a machine-readable `code` for programmatic handling?
|
|
74
|
+
- Does every validation error identify the specific field that failed?
|
|
75
|
+
- Are errors actionable? ("Email already in use" not "Conflict")
|
|
76
|
+
- Are error codes documented?
|
|
77
|
+
|
|
78
|
+
#### A3. Contract and Envelope Consistency
|
|
79
|
+
|
|
80
|
+
- Is the response envelope consistent across all endpoints?
|
|
81
|
+
- Are pagination responses consistent? (same cursor/offset shape)
|
|
82
|
+
- Is there a `data` wrapper vs direct object — consistent?
|
|
83
|
+
- Is the `null` contract clear? (field absent vs `null` vs empty array)
|
|
84
|
+
|
|
85
|
+
#### A4. Auth Integrator Experience
|
|
86
|
+
|
|
87
|
+
- Is the auth flow simple to implement for a new integrator?
|
|
88
|
+
- Are auth errors clear? (401 vs 403, explained)
|
|
89
|
+
- Are token expiry and refresh mechanisms obvious?
|
|
90
|
+
- Is there a "getting started" auth example?
|
|
91
|
+
|
|
92
|
+
#### A5. Versioning and Documentation
|
|
93
|
+
|
|
94
|
+
- Is the versioning strategy documented? (`/v1/`, `Accept` header, custom header)
|
|
95
|
+
- Are breaking change policies documented?
|
|
96
|
+
- Is there a deprecation timeline?
|
|
97
|
+
- Are deprecated fields/endpoints marked in the API spec?
|
|
98
|
+
- Does every endpoint have a description and examples?
|
|
99
|
+
|
|
100
|
+
#### A6. SDK Ergonomics (if applicable)
|
|
101
|
+
|
|
102
|
+
- If an SDK is provided: is it idiomatic for the target language?
|
|
103
|
+
- Does the SDK handle pagination, retries, and auth automatically?
|
|
104
|
+
- Is the SDK versioned and published to the target package registry?
|
|
105
|
+
- Are there typed responses?
|
|
106
|
+
|
|
107
|
+
### Path B — CLI/Tool DX Review
|
|
108
|
+
|
|
109
|
+
#### B1. Onboarding Speed
|
|
110
|
+
|
|
111
|
+
- How many commands to get to "hello world"?
|
|
112
|
+
- Is there a `--help` at every level?
|
|
113
|
+
- Does the tool guide you when required args are missing?
|
|
114
|
+
|
|
115
|
+
#### B2. Error Messages and Feedback
|
|
116
|
+
|
|
117
|
+
- Are error messages actionable? (not "command failed")
|
|
118
|
+
- Do errors include the remediation step?
|
|
119
|
+
- Is progress shown for long operations?
|
|
120
|
+
|
|
121
|
+
#### B3. Discoverability
|
|
122
|
+
|
|
123
|
+
- Can you discover all commands via `--help`?
|
|
124
|
+
- Are subcommands logical and grouped?
|
|
125
|
+
- Is there autocomplete?
|
|
126
|
+
|
|
127
|
+
### Path C — Developer Workflow DX Review
|
|
128
|
+
|
|
129
|
+
#### C1. Local Setup Friction
|
|
130
|
+
|
|
131
|
+
```bash
|
|
132
|
+
cat README.md 2>/dev/null | grep -A 20 "Getting Started\|Installation\|Setup" | head -25
|
|
133
|
+
ls docker-compose.yml Makefile .devcontainer/ 2>/dev/null || true
|
|
134
|
+
```
|
|
135
|
+
|
|
136
|
+
- Can a new developer be productive within 30 minutes?
|
|
137
|
+
- Is local dev environment reproducible?
|
|
138
|
+
- Are environment variables documented?
|
|
139
|
+
|
|
140
|
+
#### C2. CI Feedback Speed
|
|
141
|
+
|
|
142
|
+
```bash
|
|
143
|
+
cat .github/workflows/*.yml 2>/dev/null | grep -E 'timeout|runs-on|steps' | head -20
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
- How long does CI take?
|
|
147
|
+
- Are fast checks (lint, type) run before slow checks (tests)?
|
|
148
|
+
- Is CI feedback specific about what failed and where?
|
|
149
|
+
|
|
150
|
+
#### C3. Quality Tooling Loop
|
|
151
|
+
|
|
152
|
+
- Is there a formatter configured?
|
|
153
|
+
- Is there a linter with a clear rule set?
|
|
154
|
+
- Is there type checking?
|
|
155
|
+
- Are these run on commit (pre-commit hooks) or in CI?
|
|
156
|
+
|
|
157
|
+
______________________________________________________________________
|
|
158
|
+
|
|
159
|
+
## Step 2: Improvement Plan (ROI-first)
|
|
160
|
+
|
|
161
|
+
For each weak area (typically score < 7), provide:
|
|
162
|
+
|
|
163
|
+
1. **Quick win (< 2 hours):** Highest immediate impact.
|
|
164
|
+
1. **Medium investment (1-2 days):** Most likely path to 9/10.
|
|
165
|
+
1. **Long-term:** Structural change to reach 10/10.
|
|
166
|
+
|
|
167
|
+
______________________________________________________________________
|
|
168
|
+
|
|
169
|
+
## Output Contract
|
|
170
|
+
|
|
171
|
+
```text
|
|
172
|
+
## Consult Report — [project/API/tool] — [date]
|
|
173
|
+
|
|
174
|
+
selected_path: [A API DX | B CLI DX | C Workflow DX | D Routed]
|
|
175
|
+
overall_score: [N/10 or N/A when routed]
|
|
176
|
+
|
|
177
|
+
### Scores
|
|
178
|
+
| Dimension | Score | Quick Win |
|
|
179
|
+
|-----------|-------|-----------|
|
|
180
|
+
| [Dimension 1] | N/10 | [Quick win] |
|
|
181
|
+
| [Dimension 2] | N/10 | [Quick win] |
|
|
182
|
+
| [Dimension 3] | N/10 | [Quick win] |
|
|
183
|
+
| **Overall** | **N/10** | |
|
|
184
|
+
|
|
185
|
+
### Top 3 Improvements (by ROI)
|
|
186
|
+
1. [Highest leverage change]
|
|
187
|
+
2. [Second highest]
|
|
188
|
+
3. [Third]
|
|
189
|
+
|
|
190
|
+
### Routing (only when selected_path = D)
|
|
191
|
+
recommended_skill: [design|analyse|debug|code-review|security|performance|verify]
|
|
192
|
+
reason: [one sentence]
|
|
193
|
+
```
|
|
194
|
+
|
|
195
|
+
______________________________________________________________________
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
name: container
|
|
2
|
+
version: 1.0.2
|
|
3
|
+
description: |
|
|
4
|
+
Write and review Dockerfile, docker-compose, and container configuration.
|
|
5
|
+
Covers multi-stage builds, image hardening, non-root users, minimal base images,
|
|
6
|
+
layer optimisation, and local development compose setup.
|
|
7
|
+
Use when asked to "containerise", "write a Dockerfile", "add docker-compose",
|
|
8
|
+
or "harden the container image".
|
|
9
|
+
argument-hint: '[service to containerise]'
|
|
10
|
+
|
|
11
|
+
license: MIT
|
|
12
|
+
compatibility: Requires a skills-compatible agent with repository file access and terminal command execution when needed.
|
|
13
|
+
metadata:
|
|
14
|
+
owner: vstack
|
|
15
|
+
maturity: stable
|
|
16
|
+
user-invocable: true
|
|
17
|
+
disable-model-invocation: false
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
{{SKILL_CONTEXT}}
|
|
2
|
+
|
|
3
|
+
# container — Dockerfile & Compose
|
|
4
|
+
|
|
5
|
+
Write production-grade container configuration for the service.
|
|
6
|
+
|
|
7
|
+
## Out of scope
|
|
8
|
+
|
|
9
|
+
- CI/CD pipeline configuration (use `cicd`)
|
|
10
|
+
- Kubernetes manifests (use `cicd`)
|
|
11
|
+
- Application code changes (engineering role)
|
|
12
|
+
|
|
13
|
+
______________________________________________________________________
|
|
14
|
+
|
|
15
|
+
## Step 1: Detect context
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
# Detect runtime
|
|
19
|
+
ls pyproject.toml requirements.txt package.json go.mod Cargo.toml pom.xml 2>/dev/null | head -5
|
|
20
|
+
|
|
21
|
+
# Detect existing container config
|
|
22
|
+
ls Dockerfile* docker-compose* .dockerignore 2>/dev/null || echo "No container config found"
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
______________________________________________________________________
|
|
26
|
+
|
|
27
|
+
## Step 2: Dockerfile
|
|
28
|
+
|
|
29
|
+
Write a multi-stage `Dockerfile` following these rules:
|
|
30
|
+
|
|
31
|
+
**Base image:**
|
|
32
|
+
|
|
33
|
+
- Use an official, minimal image: `python:3.12-slim`, `node:22-alpine`, `golang:1.22-alpine`, etc.
|
|
34
|
+
- Never use `latest` — pin to a specific version tag
|
|
35
|
+
- Prefer `alpine` or `slim` variants for production stage
|
|
36
|
+
|
|
37
|
+
**Multi-stage build:**
|
|
38
|
+
|
|
39
|
+
```dockerfile
|
|
40
|
+
# Stage 1: build / install dependencies
|
|
41
|
+
FROM <runtime>:<version> AS builder
|
|
42
|
+
WORKDIR /app
|
|
43
|
+
COPY <dependency files> .
|
|
44
|
+
RUN <install deps>
|
|
45
|
+
|
|
46
|
+
# Stage 2: production image
|
|
47
|
+
FROM <runtime>:<version>-slim AS runtime
|
|
48
|
+
WORKDIR /app
|
|
49
|
+
COPY --from=builder /app /app
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
**Security hardening:**
|
|
53
|
+
|
|
54
|
+
- Run as non-root user:
|
|
55
|
+
|
|
56
|
+
```dockerfile
|
|
57
|
+
RUN addgroup --system app && adduser --system --ingroup app app
|
|
58
|
+
USER app
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
- Drop capabilities where applicable
|
|
62
|
+
|
|
63
|
+
- No secrets in image layers — use environment variables or mounted secrets at runtime
|
|
64
|
+
|
|
65
|
+
- Set `HEALTHCHECK` instruction
|
|
66
|
+
|
|
67
|
+
**Layer optimisation:**
|
|
68
|
+
|
|
69
|
+
- Copy dependency files first, then source (cache busting only on source change)
|
|
70
|
+
- Combine `RUN` steps with `&&` to minimise layers
|
|
71
|
+
- Add `.dockerignore` excluding: `.git`, `node_modules`, `__pycache__`, `*.pyc`, `dist`, `build`, local env files
|
|
72
|
+
|
|
73
|
+
**Port and entrypoint:**
|
|
74
|
+
|
|
75
|
+
```dockerfile
|
|
76
|
+
EXPOSE <port>
|
|
77
|
+
ENTRYPOINT ["<executable>"]
|
|
78
|
+
CMD ["<default args>"]
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
______________________________________________________________________
|
|
82
|
+
|
|
83
|
+
## Step 3: docker-compose.yml (local dev)
|
|
84
|
+
|
|
85
|
+
Write `docker-compose.yml` for local development:
|
|
86
|
+
|
|
87
|
+
```yaml
|
|
88
|
+
services:
|
|
89
|
+
app:
|
|
90
|
+
build: .
|
|
91
|
+
ports:
|
|
92
|
+
- "<host>:<container>"
|
|
93
|
+
environment:
|
|
94
|
+
- <ENV_VAR>=<value>
|
|
95
|
+
depends_on:
|
|
96
|
+
- <dependency>
|
|
97
|
+
volumes:
|
|
98
|
+
- .:/app # hot-reload in dev only — remove for prod
|
|
99
|
+
|
|
100
|
+
# Add dependencies: database, cache, broker
|
|
101
|
+
# db:
|
|
102
|
+
# image: postgres:16-alpine
|
|
103
|
+
# cache:
|
|
104
|
+
# image: redis:7-alpine
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
For production-like local testing, write a separate `docker-compose.prod.yml` without volume mounts.
|
|
108
|
+
|
|
109
|
+
______________________________________________________________________
|
|
110
|
+
|
|
111
|
+
## Step 4: Review checklist
|
|
112
|
+
|
|
113
|
+
- [ ] No `latest` tags
|
|
114
|
+
- [ ] Multi-stage build — production image contains no build tools
|
|
115
|
+
- [ ] Non-root user
|
|
116
|
+
- [ ] `.dockerignore` present and complete
|
|
117
|
+
- [ ] No secrets baked into image
|
|
118
|
+
- [ ] `HEALTHCHECK` defined
|
|
119
|
+
- [ ] Image builds successfully: `docker build -t app:local .`
|
|
120
|
+
- [ ] Container starts and responds: `docker run --rm -p <port>:<port> app:local`
|
|
121
|
+
|
|
122
|
+
______________________________________________________________________
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
name: debug
|
|
2
|
+
version: 1.0.2
|
|
3
|
+
description: |
|
|
4
|
+
Systematic root-cause debugging for backend services, APIs, and libraries.
|
|
5
|
+
No fixes without investigation. Follows the scientific method: observe →
|
|
6
|
+
hypothesize → test → conclude → fix → prevent. Use when asked to "debug",
|
|
7
|
+
"investigate", "find the root cause", or "why is this broken?".
|
|
8
|
+
argument-hint: '[issue or error to debug]'
|
|
9
|
+
|
|
10
|
+
license: MIT
|
|
11
|
+
compatibility: Requires a skills-compatible agent with repository file access and terminal command execution when needed.
|
|
12
|
+
metadata:
|
|
13
|
+
owner: vstack
|
|
14
|
+
maturity: stable
|
|
15
|
+
user-invocable: true
|
|
16
|
+
disable-model-invocation: false
|