bigpowers 2.76.3 → 2.77.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (93) hide show
  1. package/.pi/package.json +2 -2
  2. package/.pi/prompts/audit-code.md +1 -1
  3. package/.pi/prompts/build-epic.md +10 -0
  4. package/.pi/prompts/craft-skill.md +2 -2
  5. package/.pi/prompts/elaborate-spec.md +1 -1
  6. package/.pi/prompts/evolve-skill.md +1 -1
  7. package/.pi/prompts/generate-allure-report.md +284 -0
  8. package/.pi/prompts/grill-me.md +1 -1
  9. package/.pi/prompts/guard-git.md +1 -1
  10. package/.pi/prompts/harden-vps.md +287 -0
  11. package/.pi/prompts/investigate-bug.md +2 -2
  12. package/.pi/prompts/model-domain.md +3 -3
  13. package/.pi/prompts/plan-refactor.md +2 -2
  14. package/.pi/prompts/plan-release.md +5 -10
  15. package/.pi/prompts/plan-work.md +14 -1
  16. package/.pi/prompts/using-bigpowers.md +1 -1
  17. package/.pi/prompts/write-document.md +2 -2
  18. package/.pi/skills/audit-code/SKILL.md +1 -1
  19. package/.pi/skills/build-epic/SKILL.md +10 -0
  20. package/.pi/skills/change-request/SKILL.md +1 -1
  21. package/.pi/skills/commit-message/SKILL.md +3 -3
  22. package/.pi/skills/compose-workflow/SKILL.md +1 -1
  23. package/.pi/skills/craft-skill/SKILL.md +4 -4
  24. package/.pi/skills/deepen-architecture/SKILL.md +13 -13
  25. package/.pi/skills/deploy/SKILL.md +4 -4
  26. package/.pi/skills/develop-tdd/SKILL.md +5 -5
  27. package/.pi/skills/elaborate-spec/SKILL.md +1 -1
  28. package/.pi/skills/evolve-skill/SKILL.md +2 -2
  29. package/.pi/skills/extract-design/SKILL.md +1 -1
  30. package/.pi/skills/generate-allure-report/SKILL.md +285 -0
  31. package/.pi/skills/grill-me/SKILL.md +2 -2
  32. package/.pi/skills/grill-with-docs/SKILL.md +1 -1
  33. package/.pi/skills/guard-git/SKILL.md +5 -5
  34. package/.pi/skills/harden-vps/SKILL.md +288 -0
  35. package/.pi/skills/investigate-bug/SKILL.md +2 -2
  36. package/.pi/skills/migrate-spec/SKILL.md +13 -13
  37. package/.pi/skills/model-domain/SKILL.md +5 -5
  38. package/.pi/skills/orchestrate-project/SKILL.md +2 -2
  39. package/.pi/skills/organize-workspace/SKILL.md +1 -1
  40. package/.pi/skills/plan-refactor/SKILL.md +2 -2
  41. package/.pi/skills/plan-release/SKILL.md +5 -10
  42. package/.pi/skills/plan-work/SKILL.md +15 -2
  43. package/.pi/skills/publish-package/SKILL.md +8 -8
  44. package/.pi/skills/release-branch/SKILL.md +2 -2
  45. package/.pi/skills/research-first/SKILL.md +1 -1
  46. package/.pi/skills/run-evals/SKILL.md +1 -1
  47. package/.pi/skills/security-review/SKILL.md +3 -3
  48. package/.pi/skills/seed-conventions/SKILL.md +3 -3
  49. package/.pi/skills/smoke-test/SKILL.md +5 -5
  50. package/.pi/skills/stocktake-skills/SKILL.md +1 -1
  51. package/.pi/skills/using-bigpowers/SKILL.md +1 -1
  52. package/.pi/skills/validate-contracts/SKILL.md +6 -6
  53. package/.pi/skills/verify-work/SKILL.md +1 -1
  54. package/.pi/skills/wire-ci/SKILL.md +8 -8
  55. package/.pi/skills/write-document/SKILL.md +3 -3
  56. package/CHANGELOG.md +14 -0
  57. package/README.md +1 -1
  58. package/SKILL-INDEX.md +1 -1
  59. package/allure-results/categories.json +23 -0
  60. package/allure-results/executor.json +6 -0
  61. package/allure-results/junit-results.xml +2743 -0
  62. package/package.json +4 -3
  63. package/scripts/adapters/pi.sh +4 -1
  64. package/scripts/check-skill-links.py +78 -0
  65. package/scripts/generate-allure-report.sh +146 -0
  66. package/scripts/generate-reference-tables.sh +2 -1
  67. package/scripts/lib/__pycache__/link_utils.cpython-312.pyc +0 -0
  68. package/scripts/lib/link_utils.py +49 -0
  69. package/scripts/lib/srp-engine.py +86 -1
  70. package/scripts/record-cycle-time.sh +28 -0
  71. package/scripts/sync-status-from-epics.sh +247 -24
  72. package/scripts/validate-skill-catalog.sh +1 -1
  73. package/skills/audit-code/SKILL.md +1 -1
  74. package/skills/build-epic/SKILL.md +10 -0
  75. package/skills/craft-skill/SKILL.md +2 -2
  76. package/skills/elaborate-spec/SKILL.md +1 -1
  77. package/skills/evolve-skill/REFERENCE.md +1 -1
  78. package/skills/generate-allure-report/REFERENCE.md +243 -0
  79. package/skills/generate-allure-report/SKILL.md +40 -0
  80. package/skills/grill-me/REFERENCE.md +1 -1
  81. package/skills/guard-git/SKILL.md +1 -1
  82. package/skills/harden-vps/REFERENCE.md +179 -0
  83. package/skills/harden-vps/SKILL.md +107 -0
  84. package/skills/investigate-bug/SKILL.md +2 -2
  85. package/skills/model-domain/CONTEXT-FORMAT.md +3 -3
  86. package/skills/plan-refactor/SKILL.md +2 -2
  87. package/skills/plan-release/SKILL.md +5 -10
  88. package/skills/plan-work/REFERENCE.md +13 -0
  89. package/skills/plan-work/SKILL.md +1 -1
  90. package/skills/using-bigpowers/SKILL.md +1 -1
  91. package/skills/write-document/REFERENCE.md +2 -2
  92. package/skills-lock.json +20 -10
  93. package/tests/test_srp_engine.py +148 -0
@@ -22,7 +22,7 @@ Installs a shared hook that blocks destructive git operations and enforces workf
22
22
  ## Quick start
23
23
 
24
24
  1. **Scope**: ask project-only vs global (paths differ per product).
25
- 2. **Copy the hook bundle** from the root [hooks/](hooks/) directory to the client's hooks directory.
25
+ 2. **Write the hook bundle** from [REFERENCE.md](REFERENCE.md) into the client's hooks directory.
26
26
  3. **Run `chmod +x`** on `pre-tool-use.sh`.
27
27
  4. **Merge** the hook snippet from [REFERENCE.md](REFERENCE.md) into the right settings file — do not wipe unrelated keys.
28
28
  5. **Verify** with the tests in [REFERENCE.md](REFERENCE.md).
@@ -0,0 +1,179 @@
1
+ # Harden VPS — Reference
2
+
3
+ ## Health check script
4
+
5
+ Deploy to `/opt/bigbase/scripts/healthcheck.sh`:
6
+
7
+ ```bash
8
+ #!/bin/bash
9
+ LOG=/var/log/bigbase/health.log
10
+ mkdir -p /var/log/bigbase
11
+ DISK=$(df / | awk 'NR==2 {print $5}' | tr -d '%')
12
+ RAM=$(free | awk '/Mem:/ {printf "%.0f", $3/$2*100}')
13
+ NOW=$(date -Iseconds)
14
+ [ "$DISK" -gt 85 ] && echo "$NOW ALERT: Disk ${DISK}%" >> "$LOG"
15
+ [ "$RAM" -gt 90 ] && echo "$NOW ALERT: RAM ${RAM}%" >> "$LOG"
16
+ systemctl is-active --quiet bigbase || { echo "$NOW ALERT: BigBase DOWN" >> "$LOG"; systemctl restart bigbase; }
17
+ [ -f /var/run/reboot-required ] && echo "$NOW WARN: kernel reboot pending" >> "$LOG"
18
+ ```
19
+
20
+ Make executable: `chmod +x /opt/bigbase/scripts/healthcheck.sh`
21
+
22
+ ## BigBase systemd unit
23
+
24
+ Full hardened unit at `/etc/systemd/system/bigbase.service`:
25
+
26
+ ```ini
27
+ [Unit]
28
+ Description=BigBase BaaS Platform
29
+ Documentation=https://github.com/danielvm-git/bigbase
30
+ After=network.target caddy.service
31
+ Wants=caddy.service
32
+
33
+ [Service]
34
+ Type=simple
35
+ User=bigbase
36
+ Group=bigbase
37
+ WorkingDirectory=/opt/bigbase
38
+ ExecStart=/opt/bigbase/bin/bigbase serve \
39
+ --port 8080 \
40
+ --db /opt/bigbase/data/bigbase.db \
41
+ --sites-domain <your-domain.example.com>
42
+ EnvironmentFile=-/opt/bigbase/.env
43
+ Environment=BIGBASE_HOME=/opt/bigbase
44
+ Environment=HOME=/opt/bigbase
45
+ Environment=NPM_CONFIG_CACHE=/opt/bigbase/.npm
46
+ Environment=PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
47
+ Restart=always
48
+ RestartSec=5
49
+ StartLimitIntervalSec=60
50
+ StartLimitBurst=3
51
+ TimeoutStopSec=30
52
+ KillSignal=SIGTERM
53
+ NoNewPrivileges=yes
54
+ PrivateTmp=yes
55
+ ProtectSystem=full
56
+ ProtectHome=yes
57
+ ProtectKernelTunables=yes
58
+ ProtectKernelModules=yes
59
+ ProtectControlGroups=yes
60
+ RestrictAddressFamilies=AF_INET AF_INET6
61
+ RestrictRealtime=yes
62
+ ReadWritePaths=/opt/bigbase/data
63
+ ReadWritePaths=/opt/bigbase/backups
64
+ ReadWritePaths=/opt/bigbase/secrets
65
+ ReadWritePaths=/opt/bigbase/.npm
66
+ ReadWritePaths=/opt/bigbase/logs
67
+ LimitNOFILE=65536
68
+
69
+ [Install]
70
+ WantedBy=multi-user.target
71
+ ```
72
+
73
+ ## fail2ban jail.local
74
+
75
+ ```ini
76
+ [sshd]
77
+ enabled = true
78
+ port = ssh
79
+ filter = sshd
80
+ logpath = /var/log/auth.log
81
+ maxretry = 3
82
+ bantime = 3600
83
+ findtime = 600
84
+ ```
85
+
86
+ Note: BigBase auth jail deferred — BigBase logs to journald, not a file. To enable, use `backend = systemd` with a journald filter.
87
+
88
+ ## contabo-snapshot.sh
89
+
90
+ Deploy to `/opt/bigbase/scripts/contabo-snapshot.sh`. Reads credentials from `/opt/bigbase/.env` (same file used by BigBase systemd unit):
91
+
92
+ ```bash
93
+ #!/bin/bash
94
+ set -e
95
+ LOG=/var/log/bigbase/snapshot.log
96
+ ENVFILE=/opt/bigbase/.env
97
+ INSTANCE_ID=<your-contabo-instance-id>
98
+
99
+ [ -f "$ENVFILE" ] || { echo "$(date -Iseconds) ERROR: $ENVFILE missing" >> "$LOG"; exit 1; }
100
+ set -a; source "$ENVFILE"; set +a
101
+
102
+ [ -z "$CONTABO_CLIENT_ID" ] && { echo "$(date -Iseconds) ERROR: CONTABO_CLIENT_ID not set" >> "$LOG"; exit 1; }
103
+
104
+ TOKEN=$(curl -s -d "client_id=$CONTABO_CLIENT_ID" \
105
+ -d "client_secret=$CONTABO_CLIENT_SECRET" \
106
+ --data-urlencode "username=$CONTABO_API_USER" \
107
+ --data-urlencode "password=$CONTABO_API_PASSWORD" \
108
+ -d 'grant_type=password' \
109
+ 'https://auth.contabo.com/auth/realms/contabo/protocol/openid-connect/token' \
110
+ | jq -r '.access_token')
111
+
112
+ [ -z "$TOKEN" ] || [ "$TOKEN" = "null" ] && { echo "$(date -Iseconds) ERROR: auth failed" >> "$LOG"; exit 1; }
113
+
114
+ curl -s -X POST \
115
+ -H "Authorization: Bearer $TOKEN" \
116
+ -H "Content-Type: application/json" \
117
+ -H "x-request-id: $(uuidgen 2>/dev/null || echo $RANDOM)" \
118
+ "https://api.contabo.com/v1/compute/instances/${INSTANCE_ID}/snapshots" \
119
+ | tee -a "$LOG"
120
+
121
+ echo >> "$LOG"
122
+ echo "$(date -Iseconds) Snapshot requested for $INSTANCE_ID" >> "$LOG"
123
+ ```
124
+
125
+ ## Contabo credentials
126
+
127
+ Add to `/opt/bigbase/.env` (same file used by BigBase systemd unit, deployed by GitHub Actions):
128
+
129
+ ```
130
+ CONTABO_CLIENT_ID=
131
+ CONTABO_CLIENT_SECRET=
132
+ CONTABO_API_USER=
133
+ CONTABO_API_PASSWORD=
134
+ ```
135
+
136
+ Source: Contabo Customer Control Panel → API Details. ClientId and ClientSecret are generated there. API User is your email. API Password is set separately in the panel.
137
+
138
+ **Pipeline:** GitHub Secrets → deploy workflow → `/opt/bigbase/.env` on VPS. For local dev (`cntb get instances`), add to `.envrc`.
139
+
140
+ ## Contabo instance info template
141
+
142
+ Fill in your instance details from the Contabo Customer Control Panel:
143
+
144
+ ```
145
+ IP: <your-instance-ip>
146
+ IPv6: <your-instance-ipv6>
147
+ Region: <your-region>
148
+ OS: <your-os-version>
149
+ Disk: <your-disk-size>
150
+ Default user: root
151
+ Customer ID: <your-customer-id>
152
+ ```
153
+
154
+ ## BigBase monitoring alert SQL
155
+
156
+ ```sql
157
+ INSERT INTO monitoring_alerts (id, name, metric, threshold, operator, enabled, duration_seconds)
158
+ VALUES ('alert-001', 'VPS Disk above 80%', 'disk_used_percent', 80, 'gt', 1, 300);
159
+
160
+ INSERT INTO monitoring_alerts (id, name, metric, threshold, operator, enabled, duration_seconds)
161
+ VALUES ('alert-002', 'VPS CPU above 90%', 'cpu_percent', 90, 'gt', 1, 60);
162
+
163
+ INSERT INTO monitoring_alerts (id, name, metric, threshold, operator, enabled, duration_seconds)
164
+ VALUES ('alert-003', 'VPS RAM above 85%', 'mem_used_percent', 85, 'gt', 1, 120);
165
+ ```
166
+
167
+ Alerts are loaded at BigBase startup. Restart with `systemctl restart bigbase` after inserting.
168
+
169
+ ## Base64 encoding workaround
170
+
171
+ When sending scripts through Orca terminal `--text`, the local bash shell interprets `$`, `(`, and `%`. Encode locally and decode remotely:
172
+
173
+ ```bash
174
+ # Local
175
+ cat script.sh | base64
176
+
177
+ # Remote terminal
178
+ echo '<base64-output>' | base64 -d > script.sh
179
+ ```
@@ -0,0 +1,107 @@
1
+ ---
2
+ name: harden-vps
3
+ description: "Harden a production Linux VPS for BigBase across three layers — BigBase app (systemd hardening, monitoring alerts, backup automation), Ubuntu OS (UFW firewall, fail2ban SSH, unattended-upgrades, SSH hardening), and Contabo VPS (health checks, daily backups, monthly snapshots). Use when the user wants to secure a production server, harden a VPS, audit server security, or mentions production hardening, VPS security, or harden the server."
4
+ model: haiku
5
+ effort: standard
6
+ ---
7
+
8
+ # Harden VPS
9
+
10
+ Three-layer production hardening for BigBase on Contabo VPS. Each layer independently verifiable. Apply OS first (firewall blocks attacks immediately), then BigBase (alerts + backups), then Contabo (snapshots). See [REFERENCE.md](REFERENCE.md) for full script bodies, systemd unit template, and gotchas.
11
+
12
+ ## Quick start
13
+
14
+ SSH as root into the VPS. Find credentials in the Contabo Customer Control Panel.
15
+
16
+ > **HARD GATE** — Run `ufw status` first. No firewall = layer 1 takes priority over everything.
17
+
18
+ ## Layer 1 — Ubuntu OS
19
+
20
+ ```bash
21
+ # UFW
22
+ ufw default deny incoming && ufw default allow outgoing
23
+ ufw allow 22/tcp && ufw allow 80/tcp && ufw allow 443/tcp && ufw enable
24
+ # → verify: ufw status | grep -q active
25
+
26
+ # fail2ban
27
+ apt install -y fail2ban
28
+ # Configure /etc/fail2ban/jail.local: sshd, maxretry=3, bantime=3600, findtime=600
29
+ systemctl restart fail2ban
30
+ # → verify: fail2ban-client status sshd
31
+
32
+ # unattended-upgrades
33
+ apt install -y unattended-upgrades && dpkg-reconfigure -plow unattended-upgrades
34
+ # → verify: systemctl is-active unattended-upgrades | grep -q active
35
+
36
+ # SSH: PermitRootLogin no, PasswordAuthentication no, PubkeyAuthentication yes
37
+ # → verify: sshd -T | grep -E 'permitrootlogin no|passwordauthentication no'
38
+
39
+ # Deploy healthcheck.sh → /opt/bigbase/scripts/healthcheck.sh
40
+ # Crontab: */5 * * * * /opt/bigbase/scripts/healthcheck.sh
41
+ ```
42
+
43
+ ## Layer 2 — BigBase application
44
+
45
+ ```bash
46
+ # systemd: User=bigbase, NoNewPrivileges=yes, ProtectSystem=full,
47
+ # ProtectKernelTunables=yes, ProtectKernelModules=yes,
48
+ # ProtectControlGroups=yes, RestrictAddressFamilies=AF_INET AF_INET6,
49
+ # RestrictRealtime=yes, PrivateTmp=yes, LimitNOFILE=65536
50
+ # → verify: systemctl show bigbase -p NoNewPrivileges -p ProtectSystem -p User
51
+
52
+ # Alerts (BigBase requires auth; insert via SQLite)
53
+ sqlite3 /opt/bigbase/data/bigbase.db "
54
+ INSERT INTO monitoring_alerts (id,name,metric,threshold,operator,enabled,duration_seconds)
55
+ VALUES ('a1','Disk >80%','disk_used_percent',80,'gt',1,300);
56
+ INSERT INTO monitoring_alerts (id,name,metric,threshold,operator,enabled,duration_seconds)
57
+ VALUES ('a2','CPU >90%','cpu_percent',90,'gt',1,60);
58
+ INSERT INTO monitoring_alerts (id,name,metric,threshold,operator,enabled,duration_seconds)
59
+ VALUES ('a3','RAM >85%','mem_used_percent',85,'gt',1,120);
60
+ "
61
+ systemctl restart bigbase
62
+
63
+ # Backup crontab (root):
64
+ # 0 2 * * * cp /opt/bigbase/data/bigbase.db /backup/bigbase-$(date +\%Y\%m\%d).db
65
+ # 0 3 * * * find /backup/ -name "bigbase-*.db" -mtime +90 -delete
66
+ ```
67
+
68
+ ## Layer 3 — Contabo VPS
69
+
70
+ ```bash
71
+ # cntb CLI
72
+ curl -sL "$(curl -sL https://api.github.com/repos/contabo/cntb/releases/latest \
73
+ | grep browser_download_url.*linux_amd64.tar.gz | head -1 | cut -d'"' -f4)" \
74
+ | tar xz -C /usr/local/bin
75
+
76
+ # Snapshot script → /opt/bigbase/scripts/contabo-snapshot.sh (reads from /opt/bigbase/.env)
77
+ # Credentials as env vars in /opt/bigbase/.env (deployed by GitHub Actions):
78
+ # CONTABO_CLIENT_ID, CONTABO_CLIENT_SECRET, CONTABO_API_USER, CONTABO_API_PASSWORD
79
+ # Crontab: 0 4 1 * * /opt/bigbase/scripts/contabo-snapshot.sh
80
+
81
+ # > HARD GATE — Snapshot cron silently fails until env vars are set in .env.
82
+ # Credentials source: Contabo Customer Panel → API Details.
83
+ # Local dev: add to .envrc. Production: GitHub Secrets → deploy → /opt/bigbase/.env
84
+ ```
85
+
86
+ ## CRITICAL GOTCHAS
87
+
88
+ 1. **Shell escaping in Orca terminals:** `$VAR`, `$(…)`, and `%` get eaten by the local shell. Always use base64: `echo '<base64>' | base64 -d > script.sh`
89
+ 2. **Crontab `%`:** cron interprets `%` as newline. Escape as `\%` in `$(date +\%Y\%m\%d)`
90
+ 3. **fail2ban exit 255:** means a jail references a missing log file. Remove the broken jail, restart.
91
+ 4. **BigBase alerts need auth:** POST to `/api/monitoring/alerts` requires Bearer token. Workaround: insert directly into SQLite, then restart BigBase.
92
+
93
+ ## Verify all 8 gates
94
+
95
+ ```bash
96
+ ufw status|grep -q active||echo FAIL:ufw
97
+ fail2ban-client status sshd>/dev/null 2>&1||echo FAIL:fail2ban
98
+ systemctl is-active unattended-upgrades|grep -q active||echo FAIL:unattended
99
+ sshd -T|grep -q 'permitrootlogin no'||echo FAIL:sshd
100
+ systemctl show bigbase -p NoNewPrivileges|grep -q yes||echo FAIL:systemd
101
+ systemctl is-active bigbase|grep -q active||echo FAIL:bigbase
102
+ sqlite3 /opt/bigbase/data/bigbase.db "SELECT count(*) FROM monitoring_alerts"|grep -q 3||echo FAIL:alerts
103
+ crontab -l|grep -q healthcheck&&crontab -l|grep -q bigbase.db&&crontab -l|grep -q contabo-snapshot||echo FAIL:crontab
104
+ echo ALL 8 GATES PASSED
105
+ ```
106
+
107
+ → verify: run the 8-gate one-liner on the VPS.
@@ -124,6 +124,6 @@ After writing the bug file, print a one-line summary of the root cause and sugge
124
124
 
125
125
  <!-- story: e35s10 -->
126
126
 
127
- - [Feathers' Seams & Characterization Tests](../../docs/references/feathers.md) — seam types, characterization tests, and the legacy code change algorithm
128
- - [Fowler's Code Smells](../../docs/references/fowler.md) — identifying structural problems by smell before investigating
127
+ - [Feathers' Seams & Characterization Tests](https://github.com/danielvm-git/bigpowers/blob/main/docs/references/feathers.md) — seam types, characterization tests, and the legacy code change algorithm
128
+ - [Fowler's Code Smells](https://github.com/danielvm-git/bigpowers/blob/main/docs/references/fowler.md) — identifying structural problems by smell before investigating
129
129
 
@@ -57,9 +57,9 @@ _Avoid_: Client, buyer, account
57
57
 
58
58
  ## Contexts
59
59
 
60
- - [Ordering](./src/ordering/CONTEXT.md) — receives and tracks customer orders
61
- - [Billing](./src/billing/CONTEXT.md) — generates invoices and processes payments
62
- - [Fulfillment](./src/fulfillment/CONTEXT.md) — manages warehouse picking and shipping
60
+ - Ordering — `src/ordering/CONTEXT.md` — receives and tracks customer orders
61
+ - Billing — `src/billing/CONTEXT.md` — generates invoices and processes payments
62
+ - Fulfillment — `src/fulfillment/CONTEXT.md` — manages warehouse picking and shipping
63
63
 
64
64
  ## Relationships
65
65
 
@@ -82,8 +82,8 @@ After writing `specs/REFACTOR_LATEST.md`, suggest running `kickoff-branch` next
82
82
 
83
83
  <!-- story: e35s10 -->
84
84
 
85
- - [Fowler's Refactoring Catalog](../../docs/references/fowler.md) — canonical refactoring vocabulary and code-smell taxonomy
86
- - [Beck's Tidy First?](../../docs/references/kent-beck.md) — structural change before behavioral change
85
+ - [Fowler's Refactoring Catalog](https://github.com/danielvm-git/bigpowers/blob/main/docs/references/fowler.md) — canonical refactoring vocabulary and code-smell taxonomy
86
+ - [Beck's Tidy First?](https://github.com/danielvm-git/bigpowers/blob/main/docs/references/kent-beck.md) — structural change before behavioral change
87
87
 
88
88
  ## Verify
89
89
 
@@ -17,7 +17,7 @@ Synthesize the conversation context into `specs/release-plan.yaml` (index) and s
17
17
  |------|---------|
18
18
  | `specs/release-plan.yaml` | `release.version`, semver bump hint, WSJF-ordered epic list with `id`, `capsule_dir`, `wsjf`, `bcps` — **no story status** |
19
19
  | `specs/epics/eNN-<slug>/epic.yaml` | Epic manifest: `id`, `title`, `wsjf`, `total_bcps`, `status`, `stories[]` list |
20
- | `specs/epics/eNN-<slug>/eNNsYY-<slug>.md` | Story spec in [countable-story-format.md](file:///Users/danielvm/Developer/bigpowers/countable-story-format.md) with 20 sections and Gherkin acceptance criteria |
20
+ | `specs/epics/eNN-<slug>/eNNsYY-<slug>.md` | Story spec in [countable-story-format.md](https://github.com/danielvm-git/bigpowers/blob/main/docs/countable-story-format.md) with 20 sections and Gherkin acceptance criteria |
21
21
  | `specs/epics/eNN-<slug>/eNNsYY-tasks.yaml` | Decoupled task checklist with `verify:` commands per task |
22
22
  | `specs/execution-status.yaml` | Flat key-value store for story status (`eNNsYY: todo`) |
23
23
 
@@ -38,7 +38,6 @@ specs/epics/e01-auth-system/
38
38
  **Rationale:** Capsule dirs achieve change isolation (C9), enable archive pruning (C2/C6), and enforce SRP by decoupling spec `.md` from execution `-tasks.yaml` (C1).
39
39
 
40
40
  ## Process
41
-
42
41
  ### 1. Draft epics and stories
43
42
 
44
43
  From the conversation context, define:
@@ -48,15 +47,12 @@ From the conversation context, define:
48
47
  WSJF-sort epics: score = (Business Value + Time Criticality + Risk Reduction) / Job Size. Highest score first.
49
48
 
50
49
  > **Security risk boost:** If an epic's `specs/security/epics/<id>/THREAT_MODEL.md` identifies HIGH or CRITICAL risk, add +2 to the WSJF numerator (BV + TC + RR + 2) to reflect the urgency of addressing security concerns before they ship. Document the boost in the epic's note field in release-plan.yaml.
51
-
52
50
  ### 2. Write acceptance criteria (Gherkin)
53
51
 
54
52
  For each story, write at least one happy-path and one edge-case scenario (countable format §17 if maturity ≥ 3).
55
-
56
53
  ### 3. Write tasks with verify commands
57
54
 
58
55
  Every task must have a `verify:` command. No verify command = not a task.
59
-
60
56
  ### 4. Save specs/release-plan.yaml
61
57
 
62
58
  > **Do NOT hand-track the real version.** semantic-release decides it at merge. `version` here is a
@@ -80,7 +76,6 @@ epics:
80
76
  wsjf: 3.8
81
77
  capsule_dir: epics/e02-user-profile
82
78
  ```
83
-
84
79
  ### 5. Save epic manifest (`epic.yaml`)
85
80
 
86
81
  Each epic capsule directory contains an `epic.yaml` manifest:
@@ -105,11 +100,9 @@ stories:
105
100
  spec: e01s02-jwt.md
106
101
  tasks: e01s02-tasks.yaml
107
102
  ```
108
-
109
103
  ### 6. Save story specs (countable-story-format .md)
110
104
 
111
- Each story becomes a standalone `.md` file following [countable-story-format.md](file:///Users/danielvm/Developer/bigpowers/countable-story-format.md). Minimum: maturity 3 (Countable) with all 20 sections present. Acceptance criteria in §17 use Gherkin scenarios.
112
-
105
+ Each story becomes a standalone `.md` file following [countable-story-format.md](https://github.com/danielvm-git/bigpowers/blob/main/docs/countable-story-format.md). Minimum: maturity 3 (Countable) with all 20 sections present. Acceptance criteria in §17 use Gherkin scenarios.
113
106
  ### 7. Save decoupled task files (`-tasks.yaml`)
114
107
 
115
108
  Each story has a decoupled `-tasks.yaml` with implementation steps:
@@ -133,6 +126,9 @@ tasks:
133
126
  > **HARD GATE** — Every task MUST have a runnable `verify:` command. No `verify:` = not a task.
134
127
 
135
128
  → verify: `bash scripts/validate-specs-yaml.sh`
129
+ ### 7b. Generate bug registry summary
130
+
131
+ Read `specs/bugs/registry.yaml` and add a `bugs:` section to `release-plan.yaml` with totals by status (`fixed`, `deferred`, `wontfix`, `open`): `bugs: { total: N, fixed: N, deferred: N, wontfix: N, registry: specs/bugs/registry.yaml }`.
136
132
 
137
133
  ### 8. Sync execution status
138
134
 
@@ -142,7 +138,6 @@ bash scripts/sync-status-from-epics.sh
142
138
  ### 9. Snapshot on planning close (optional)
143
139
 
144
140
  Copy to `specs/product/snapshots/release-<version>/` when the user approves the plan.
145
-
146
141
  ### 10. Suggest next steps
147
142
 
148
143
  - Run `assess-impact` before `plan-work` for any story touching existing modules.
@@ -30,8 +30,21 @@ tasks:
30
30
  verify: "npm test -- login-form.test.tsx"
31
31
  risk: P1
32
32
  status: failing # flip to passing only after verify exits 0 (e45s06)
33
+ allure:
34
+ severity: high # P0→critical, P1→high, P2→normal, P3→minor
35
+ categories:
36
+ - "Auth"
37
+ - "Security Review"
33
38
  ```
34
39
 
40
+ **Allure severity mapping:**
41
+ - `P0` → `critical`
42
+ - `P1` → `high`
43
+ - `P2` → `normal`
44
+ - `P3` → `minor`
45
+
46
+ `categories` is a list of relevant tags — wave names, test categories (e.g. `"unit"`, `"integration"`), or thematic groupings (e.g. `"Security Review"`).
47
+
35
48
  Update `specs/epics/<capsule>/epic.yaml` manifest to list the story and its BCPs. Run `bash scripts/sync-status-from-epics.sh` after structural changes.
36
49
 
37
50
  ## Plan template
@@ -51,7 +51,7 @@ If this plan touches an existing module, run `assess-impact` first to understand
51
51
 
52
52
  2. **Draft steps** — Break implementation into the smallest possible steps where each step leaves the codebase working, has one observable outcome, and can be verified with a single command. Red-flag check: name any rationalization you caught before moving to step 3.
53
53
 
54
- 3. **Write capsule story spec + tasks** — Output two files inside the active epic capsule. See [REFERENCE.md](REFERENCE.md) for file formats and the plan-template. Each task MUST include a `risk:` field (`P0` | `P1` | `P2` | `P3`) based on BCP + story type heuristics (see REFERENCE.md). If a test plan artifact (`specs/tech-architecture/eNN-TEST_PLAN_LATEST.md`) exists, read it and inherit its P0/P1 risk classifications and scenario IDs (`SC-eNNsYY-P0-NN`). Each task optionally includes a `security:` field (`none` / `low` / `medium` / `high`) sourced from the epic's `specs/security/epics/<id>/THREAT_MODEL.md`. Tasks with `security: medium` or `security: high` MUST include "no new security findings in affected paths" in their verify steps.
54
+ 3. **Write capsule story spec + tasks** — Output two files inside the active epic capsule. See [REFERENCE.md](REFERENCE.md) for file formats and the plan-template. Each task MUST include a `risk:` field (`P0` | `P1` | `P2` | `P3`) based on BCP + story type heuristics (see REFERENCE.md). If a test plan artifact (`specs/tech-architecture/eNN-TEST_PLAN_LATEST.md`) exists, read it and inherit its P0/P1 risk classifications and scenario IDs (`SC-eNNsYY-P0-NN`). Each task optionally includes a `security:` field (`none` / `low` / `medium` / `high`) sourced from the epic's `specs/security/epics/<id>/THREAT_MODEL.md`. Tasks with `security: medium` or `security: high` MUST include "no new security findings in affected paths" in their verify steps. Each task should also include an `allure:` block to drive test reporting: `severity:` maps risk to Allure severity (`P0→critical`, `P1→high`, `P2→normal`, `P3→minor`), and `categories:` is a list of relevant tags like `"Security Review"`, wave names, or test categories (see REFERENCE.md for the full template).
55
55
 
56
56
  **Requirement delta tags (e45s29):** When a story modifies existing behavior, the story spec § Requirements MUST use OpenSpec-style delta tags with mandatory before/after content:
57
57
 
@@ -78,7 +78,7 @@ UTILITY terse-mode / craft-skill / edit-document (any phase)
78
78
 
79
79
  If you work alone and do not want PR ceremony every task:
80
80
 
81
- 1. Read [profiles/solo-git.md](../profiles/solo-git.md).
81
+ 1. Read [profiles/solo-git.md](../../profiles/solo-git.md).
82
82
  2. Register with `compose-workflow` → `specs/WORKFLOW-solo-git.md`.
83
83
  3. Ship with `release-branch` in **solo-local** mode (`land-branch.sh`), not `gh pr create`.
84
84
 
@@ -141,7 +141,7 @@ Auto-fill from CLAUDE.md `Test` and `Lint` commands.
141
141
  ```markdown
142
142
  ## Changelog
143
143
 
144
- See [CHANGELOG.md](CHANGELOG.md) or [Releases](https://github.com/user/repo/releases).
144
+ See [CHANGELOG.md](../../CHANGELOG.md) or [Releases](https://github.com/user/repo/releases).
145
145
  ```
146
146
 
147
147
  ### 13. Links
@@ -158,7 +158,7 @@ See [CHANGELOG.md](CHANGELOG.md) or [Releases](https://github.com/user/repo/rele
158
158
  ```markdown
159
159
  ## License
160
160
 
161
- MIT — see [LICENSE](LICENSE) for details.
161
+ MIT — see [LICENSE](../../LICENSE) for details.
162
162
  ```
163
163
 
164
164
  Detect from CLAUDE.md or project LICENSE file.
package/skills-lock.json CHANGED
@@ -13,7 +13,7 @@
13
13
  },
14
14
  "audit-code": {
15
15
  "description": "Self-review checklist for the coding agent to run before dispatching a reviewer. Checks CONVENTIONS.md compliance, Boy Scout Rule, test coverage, types, and SOLID. Produces a pass/fail checklist. Use before request-review, before committing, or when user asks for a code quality check.",
16
- "sha256": "bbb128254464f8f4",
16
+ "sha256": "0636f1d9d6c591a3",
17
17
  "path": "skills/audit-codeSKILL.md"
18
18
  },
19
19
  "audit-plan": {
@@ -23,7 +23,7 @@
23
23
  },
24
24
  "build-epic": {
25
25
  "description": "Eight-step epic build cycle — reads state.yaml, execution-status.yaml, and one epic capsule; updates status via bp-yaml-set or direct edit. Resume mode runs one step per invocation. Use instead of ad-hoc execute-plan for release work.",
26
- "sha256": "85275fd5f2f5664f",
26
+ "sha256": "11fe35d1dcdec25a",
27
27
  "path": "skills/build-epicSKILL.md"
28
28
  },
29
29
  "change-request": {
@@ -48,7 +48,7 @@
48
48
  },
49
49
  "craft-skill": {
50
50
  "description": "Create new bigpowers skills with proper structure, progressive disclosure, and bundled resources. Use when user wants to create, write, or build a new skill for the bigpowers lifecycle.",
51
- "sha256": "cbf8ab939cfbab87",
51
+ "sha256": "2caa9d8ae9298b4b",
52
52
  "path": "skills/craft-skillSKILL.md"
53
53
  },
54
54
  "deepen-architecture": {
@@ -108,7 +108,7 @@
108
108
  },
109
109
  "elaborate-spec": {
110
110
  "description": "Refine a rough idea into a clear, detailed specification through dialogue. Does not produce code. Use when user has a vague idea, wants to think through a feature before planning, or needs to turn \"I want X\" into a concrete spec.",
111
- "sha256": "62ebfca87e6d0162",
111
+ "sha256": "9307ab61c789a0a0",
112
112
  "path": "skills/elaborate-specSKILL.md"
113
113
  },
114
114
  "enforce-first": {
@@ -141,6 +141,11 @@
141
141
  "sha256": "ed37c315dcef6f87",
142
142
  "path": "skills/gate-traceSKILL.md"
143
143
  },
144
+ "generate-allure-report": {
145
+ "description": "\"Generate Allure-ready reports from bigpowers YAML metadata. Reads execution-status.yaml, release-plan.yaml, epic capsules, task YAMLs, cycle-times.yaml, and bug registry to produce allure-results/junit-results.xml, categories.json, and executor.json. Use when preparing progress dashboards, integrating with Allure TestOps, or generating CI reports.\"",
146
+ "sha256": "acaa43602dc56291",
147
+ "path": "skills/generate-allure-reportSKILL.md"
148
+ },
144
149
  "grill-me": {
145
150
  "description": "Interactive assumption-surfacing Q&A that stress-tests a plan through relentless questioning until every decision is resolved. Use when user wants to challenge a plan, validate decisions from conversation/context, or mentions \"grill me\". For doc-grounded variant, use grill-with-docs.",
146
151
  "sha256": "8ef90da0f127f2fd",
@@ -153,9 +158,14 @@
153
158
  },
154
159
  "guard-git": {
155
160
  "description": "Block dangerous git commands (push, force push, reset --hard, clean, branch -D, checkout/restore .) and enforce Conventional Commits & Branch Protection before an AI agent runs them. Installs hook scripts for Claude Code, Cursor, Cursor CLI, and Gemini CLI; documents Google Antigravity Terminal deny lists. Use when the user wants git safety hooks, to block git push or destructive git in agents, or to mirror the same policy across AI coding tools.",
156
- "sha256": "9ee881df89273b00",
161
+ "sha256": "e7083cba6d95a15f",
157
162
  "path": "skills/guard-gitSKILL.md"
158
163
  },
164
+ "harden-vps": {
165
+ "description": "\"Harden a production Linux VPS for BigBase across three layers — BigBase app (systemd hardening, monitoring alerts, backup automation), Ubuntu OS (UFW firewall, fail2ban SSH, unattended-upgrades, SSH hardening), and Contabo VPS (health checks, daily backups, monthly snapshots). Use when the user wants to secure a production server, harden a VPS, audit server security, or mentions production hardening, VPS security, or harden the server.\"",
166
+ "sha256": "6ea255a1777523d9",
167
+ "path": "skills/harden-vpsSKILL.md"
168
+ },
159
169
  "hook-commits": {
160
170
  "description": "Set up pre-commit hooks with lint-staged (Prettier), type checking, and tests in the current repo. Use when user wants to add pre-commit hooks, set up Husky, configure lint-staged, or add commit-time formatting/typechecking/testing.",
161
171
  "sha256": "ac5be2537ce599d7",
@@ -168,7 +178,7 @@
168
178
  },
169
179
  "investigate-bug": {
170
180
  "description": "Investigate a bug or issue by exploring the codebase to find root cause, then write a TDD-based fix plan to specs/bugs/BUG-*.md. Use when user reports a bug, wants to investigate a problem, mentions \"triage\", or wants to plan a fix.",
171
- "sha256": "b842fd329d1f7741",
181
+ "sha256": "54f8c5417be34ef0",
172
182
  "path": "skills/investigate-bugSKILL.md"
173
183
  },
174
184
  "kickoff-branch": {
@@ -208,12 +218,12 @@
208
218
  },
209
219
  "plan-refactor": {
210
220
  "description": "Create a detailed refactor plan with tiny commits via user interview, then save it as specs/REFACTOR_LATEST.md. Use when user wants to plan a refactor, create a refactoring RFC, or break a refactor into safe incremental steps.",
211
- "sha256": "c418c850806e2f16",
221
+ "sha256": "2d18809da7cc9de8",
212
222
  "path": "skills/plan-refactorSKILL.md"
213
223
  },
214
224
  "plan-release": {
215
225
  "description": "\"RELEASE-INDEX BUILDER — Sequence elaborated epics into specs/release-plan.yaml with WSJF ordering and BCP baselines. NOT a planning-spine substitute: it does not scope work (scope-work) or write story tasks (plan-work). Use after elaborate-spec when the user wants a versioned release index of epics.\"",
216
- "sha256": "62dc272a091c8d7f",
226
+ "sha256": "9334ff48e5b1fab3",
217
227
  "path": "skills/plan-releaseSKILL.md"
218
228
  },
219
229
  "plan-tests": {
@@ -223,7 +233,7 @@
223
233
  },
224
234
  "plan-work": {
225
235
  "description": "\"PLANNING SPINE STEP 3 of 3 — Plan the work: write detailed implementation tasks into the active epic capsule (specs/epics/eNN-slug/). Produces countable-story-format .md specs and runnable -tasks.yaml files. Use after slice-tasks (step 2). Not a substitute for scope-work (step 1) or slice-tasks (step 2).\"",
226
- "sha256": "aabc7f15b46525c2",
236
+ "sha256": "2cccc734ae9781ab",
227
237
  "path": "skills/plan-workSKILL.md"
228
238
  },
229
239
  "publish-package": {
@@ -348,7 +358,7 @@
348
358
  },
349
359
  "using-bigpowers": {
350
360
  "description": "One-time bootstrap that introduces the bigpowers skills system, the PMBOK lifecycle arc, and tells you which skill to call first for your situation. Use when starting with bigpowers for the first time, when user asks \"where do I start?\", or when the skills system needs to be explained.",
351
- "sha256": "332d6468868b759b",
361
+ "sha256": "bad9ebe9bf303b36",
352
362
  "path": "skills/using-bigpowersSKILL.md"
353
363
  },
354
364
  "validate-contracts": {