@luanpdd/kit-mcp 1.35.0 → 1.36.0

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 (117) hide show
  1. package/bin/cli.js +2 -2
  2. package/bin/mcp.js +6 -6
  3. package/bin/ui.js +74 -74
  4. package/gates/ai-prompt-stability.md +120 -120
  5. package/gates/budget-description.md +68 -68
  6. package/gates/confidence.md +29 -29
  7. package/gates/dependency-check.md +33 -33
  8. package/gates/dept-cycle-prevention.md +179 -179
  9. package/gates/golden-signals-coverage.md +133 -133
  10. package/gates/legacy-refactor-safety.md +178 -178
  11. package/gates/multi-tenant-rls-coverage.md +102 -102
  12. package/gates/no-personal-uuid.md +72 -72
  13. package/gates/obs-agents-mcp-supabase.md +86 -86
  14. package/gates/obs-skills-frontmatter.md +76 -76
  15. package/gates/observability-coverage.md +151 -151
  16. package/gates/omm-no-regression.md +83 -83
  17. package/gates/postmortem-template-required.md +127 -127
  18. package/gates/prr-checklist-coverage.md +128 -128
  19. package/gates/regression.md +32 -32
  20. package/gates/release-pipeline-policy.md +132 -132
  21. package/gates/secrets-scan.md +33 -33
  22. package/gates/service-role-not-in-user-facing.md +113 -113
  23. package/gates/skill-must-include.md +71 -71
  24. package/gates/sync-idempotent.md +62 -62
  25. package/gates/verify-phase-goal.md +34 -34
  26. package/kit/agents/designer-ui.md +216 -216
  27. package/kit/agents/workflow-generator.md +537 -167
  28. package/kit/commands/adicionar-backlog.md +1 -1
  29. package/kit/commands/adicionar-fase.md +1 -1
  30. package/kit/commands/adicionar-tarefa.md +1 -1
  31. package/kit/commands/auditar-observabilidade.md +103 -103
  32. package/kit/commands/auditar-toil.md +129 -129
  33. package/kit/commands/caracterizar-prompt.md +195 -195
  34. package/kit/commands/criar-workflow.md +158 -158
  35. package/kit/commands/definir-perfil.md +1 -1
  36. package/kit/commands/definir-slo.md +108 -108
  37. package/kit/commands/fio.md +1 -1
  38. package/kit/commands/golden-signals.md +142 -142
  39. package/kit/commands/instrumentar-fase.md +200 -200
  40. package/kit/commands/investigar-producao.md +162 -162
  41. package/kit/commands/observabilidade.md +118 -118
  42. package/kit/commands/postmortem.md +179 -179
  43. package/kit/commands/prr.md +205 -205
  44. package/kit/commands/publicar-rapido.md +207 -207
  45. package/kit/commands/risk-budget.md +220 -220
  46. package/kit/commands/sre.md +230 -230
  47. package/kit/file-manifest.json +424 -424
  48. package/kit/framework/references/output-style.md +22 -22
  49. package/kit/hooks/post-apply-migration.js +199 -199
  50. package/kit/hooks/sidecar-tool-publisher.js +210 -210
  51. package/kit/skills/_shared-dados-distribuidos/glossary.md +224 -224
  52. package/kit/skills/_shared-legacy/glossary.md +389 -389
  53. package/kit/skills/_shared-multi-tenant/glossary.md +186 -186
  54. package/kit/skills/_shared-observability/glossary.md +396 -396
  55. package/kit/skills/_shared-sre/glossary.md +712 -712
  56. package/kit/skills/_shared-supabase/glossary.md +234 -234
  57. package/kit/skills/blameless-postmortems/SKILL.md +340 -340
  58. package/kit/skills/burn-rate-alerting/SKILL.md +258 -258
  59. package/kit/skills/cascading-failures/SKILL.md +311 -311
  60. package/kit/skills/core-analysis-loop/SKILL.md +352 -352
  61. package/kit/skills/distributed-tracing/SKILL.md +362 -362
  62. package/kit/skills/dynamic-workflow-authoring/SKILL.md +327 -223
  63. package/kit/skills/eliminating-toil/SKILL.md +243 -243
  64. package/kit/skills/event-based-slos/SKILL.md +296 -296
  65. package/kit/skills/four-golden-signals/SKILL.md +314 -314
  66. package/kit/skills/hermetic-builds/SKILL.md +323 -323
  67. package/kit/skills/legacy-monster-methods/SKILL.md +444 -444
  68. package/kit/skills/llm-as-dependency/SKILL.md +436 -436
  69. package/kit/skills/load-shedding-graceful-degradation/SKILL.md +396 -396
  70. package/kit/skills/observability-driven-development/SKILL.md +315 -315
  71. package/kit/skills/observability-maturity-model/SKILL.md +222 -222
  72. package/kit/skills/opentelemetry-standard/SKILL.md +351 -351
  73. package/kit/skills/production-readiness-review/SKILL.md +305 -305
  74. package/kit/skills/release-engineering/SKILL.md +367 -367
  75. package/kit/skills/retry-strategies/SKILL.md +372 -372
  76. package/kit/skills/sre-risk-management/SKILL.md +221 -221
  77. package/kit/skills/structured-events/SKILL.md +265 -265
  78. package/kit/skills/supabase-cron-queues/SKILL.md +275 -275
  79. package/kit/skills/supabase-database-functions/SKILL.md +332 -332
  80. package/kit/skills/supabase-declarative-schema/SKILL.md +183 -183
  81. package/kit/skills/supabase-pgvector-rag/SKILL.md +253 -253
  82. package/kit/skills/supabase-postgres-style/SKILL.md +138 -138
  83. package/kit/skills/supabase-storage/SKILL.md +234 -234
  84. package/kit/skills/telemetry-pipelines/SKILL.md +259 -259
  85. package/kit/skills/telemetry-sampling/SKILL.md +256 -256
  86. package/kit/skills/ui-anti-padroes-ia/SKILL.md +261 -261
  87. package/kit/skills/ui-contexto-produto/SKILL.md +248 -248
  88. package/kit/skills/ui-cor-estrategia/SKILL.md +213 -213
  89. package/kit/skills/ui-critica-auditoria/SKILL.md +260 -260
  90. package/kit/skills/ui-motion-funcional/SKILL.md +264 -264
  91. package/kit/skills/ui-ritmo-espacial/SKILL.md +259 -259
  92. package/kit/skills/ui-tipografia/SKILL.md +211 -211
  93. package/package.json +1 -1
  94. package/src/cli/index.js +1114 -1114
  95. package/src/cli/render.js +194 -194
  96. package/src/cli/upgrade-check.js +135 -135
  97. package/src/core/error-redaction.js +76 -76
  98. package/src/core/failures.js +153 -153
  99. package/src/core/gate-runner.js +205 -205
  100. package/src/core/gates.js +82 -82
  101. package/src/core/logger.js +170 -170
  102. package/src/core/manifest-verify.js +174 -174
  103. package/src/core/metrics.js +268 -268
  104. package/src/core/notify.js +60 -60
  105. package/src/core/path-safety.js +141 -141
  106. package/src/core/replays.js +120 -120
  107. package/src/core/ui.js +185 -185
  108. package/src/mcp-server/install.js +149 -149
  109. package/src/mcp-server/roots.js +124 -124
  110. package/src/ui/auto-spawn.js +113 -113
  111. package/src/ui/browser.js +78 -78
  112. package/src/ui/client.js +130 -130
  113. package/src/ui/events.js +65 -65
  114. package/src/ui/lockfile.js +191 -191
  115. package/src/ui/port.js +67 -67
  116. package/src/ui/server.js +547 -547
  117. package/src/ui/wrapper.js +129 -129
@@ -1,71 +1,71 @@
1
- ---
2
- id: skill-must-include
3
- stage: pre-verify
4
- blocking: true
5
- description: Valida que skills supabase-* contêm strings obrigatórias verbatim — anti-pattern prevention (RLS (select), search_path, getAll/setAll, etc.).
6
- ---
7
-
8
- # Skill must-include gate
9
-
10
- **When to run:** pre-verify.
11
-
12
- ## Check
13
-
14
- ```bash
15
- #!/usr/bin/env bash
16
- # PT-BR: cada skill deve incluir strings obrigatórias verbatim para prevenir anti-patterns
17
- # Portable: bash 3.2+ (macOS default), sem associative arrays
18
- set -e
19
-
20
- VIOLATIONS=0
21
-
22
- check_skill() {
23
- local skill="$1"
24
- local required="$2" # strings separadas por |
25
- local file="kit/skills/$skill/SKILL.md"
26
-
27
- if [ ! -f "$file" ]; then
28
- echo "FAIL: $file — skill ausente"
29
- VIOLATIONS=$((VIOLATIONS + 1))
30
- return
31
- fi
32
-
33
- # PT-BR: testa cada string (separada por |)
34
- local IFS='|'
35
- for str in $required; do
36
- if ! grep -qF "$str" "$file"; then
37
- echo "FAIL: $file — must-include ausente: '$str'"
38
- VIOLATIONS=$((VIOLATIONS + 1))
39
- fi
40
- done
41
- }
42
-
43
- check_skill "supabase-rls-policies" "(select auth.uid())|user_metadata|TO authenticated"
44
- check_skill "supabase-database-functions" "set search_path = ''|SECURITY INVOKER"
45
- check_skill "supabase-auth-ssr" "getAll|setAll|auth-helpers-nextjs|@supabase/ssr"
46
- check_skill "supabase-realtime" "broadcast|private: true|realtime.broadcast_changes|removeChannel"
47
- check_skill "supabase-edge-functions" "npm:|jsr:|Deno.serve|EdgeRuntime.waitUntil|/tmp"
48
- check_skill "supabase-declarative-schema" "supabase/schemas/|supabase stop|supabase db diff -f"
49
- check_skill "supabase-migrations" "YYYYMMDDHHmmss|RLS|granular"
50
- check_skill "supabase-postgres-style" "snake_case|ISO 8601|lowercase"
51
- check_skill "supabase-storage" "signed URL|storage.objects|multi-tenant"
52
- check_skill "supabase-pgvector-rag" "HNSW|IVFFlat|<=>|RAG with permissions"
53
- check_skill "supabase-cron-queues" "pg_cron|pgmq|pg_net"
54
-
55
- if [ "$VIOLATIONS" -gt 0 ]; then
56
- echo "Total violations: $VIOLATIONS"
57
- exit 1
58
- fi
59
-
60
- echo "✓ Todas as skills supabase-* contêm must-include strings"
61
- exit 0
62
- ```
63
-
64
- ## Verdict
65
-
66
- - **passed** — todas as 11 skills têm strings obrigatórias
67
- - **block** — pelo menos uma skill faltando string crítica (anti-pattern prevention quebrada)
68
-
69
- ## Notes
70
-
71
- Anti-pitfall A7 da v1.8: skills devem prevenir ativamente os anti-patterns Supabase mais críticos. Sem este gate, refator de skill pode acidentalmente remover a regra principal (ex: `(select auth.uid())` wrapper que previne 1000× degradação). Strings como `WARNING user_metadata`, `set search_path = ''`, `NEVER use auth-helpers-nextjs` são as primeiras coisas que LLM lê — devem estar lá.
1
+ ---
2
+ id: skill-must-include
3
+ stage: pre-verify
4
+ blocking: true
5
+ description: Valida que skills supabase-* contêm strings obrigatórias verbatim — anti-pattern prevention (RLS (select), search_path, getAll/setAll, etc.).
6
+ ---
7
+
8
+ # Skill must-include gate
9
+
10
+ **When to run:** pre-verify.
11
+
12
+ ## Check
13
+
14
+ ```bash
15
+ #!/usr/bin/env bash
16
+ # PT-BR: cada skill deve incluir strings obrigatórias verbatim para prevenir anti-patterns
17
+ # Portable: bash 3.2+ (macOS default), sem associative arrays
18
+ set -e
19
+
20
+ VIOLATIONS=0
21
+
22
+ check_skill() {
23
+ local skill="$1"
24
+ local required="$2" # strings separadas por |
25
+ local file="kit/skills/$skill/SKILL.md"
26
+
27
+ if [ ! -f "$file" ]; then
28
+ echo "FAIL: $file — skill ausente"
29
+ VIOLATIONS=$((VIOLATIONS + 1))
30
+ return
31
+ fi
32
+
33
+ # PT-BR: testa cada string (separada por |)
34
+ local IFS='|'
35
+ for str in $required; do
36
+ if ! grep -qF "$str" "$file"; then
37
+ echo "FAIL: $file — must-include ausente: '$str'"
38
+ VIOLATIONS=$((VIOLATIONS + 1))
39
+ fi
40
+ done
41
+ }
42
+
43
+ check_skill "supabase-rls-policies" "(select auth.uid())|user_metadata|TO authenticated"
44
+ check_skill "supabase-database-functions" "set search_path = ''|SECURITY INVOKER"
45
+ check_skill "supabase-auth-ssr" "getAll|setAll|auth-helpers-nextjs|@supabase/ssr"
46
+ check_skill "supabase-realtime" "broadcast|private: true|realtime.broadcast_changes|removeChannel"
47
+ check_skill "supabase-edge-functions" "npm:|jsr:|Deno.serve|EdgeRuntime.waitUntil|/tmp"
48
+ check_skill "supabase-declarative-schema" "supabase/schemas/|supabase stop|supabase db diff -f"
49
+ check_skill "supabase-migrations" "YYYYMMDDHHmmss|RLS|granular"
50
+ check_skill "supabase-postgres-style" "snake_case|ISO 8601|lowercase"
51
+ check_skill "supabase-storage" "signed URL|storage.objects|multi-tenant"
52
+ check_skill "supabase-pgvector-rag" "HNSW|IVFFlat|<=>|RAG with permissions"
53
+ check_skill "supabase-cron-queues" "pg_cron|pgmq|pg_net"
54
+
55
+ if [ "$VIOLATIONS" -gt 0 ]; then
56
+ echo "Total violations: $VIOLATIONS"
57
+ exit 1
58
+ fi
59
+
60
+ echo "✓ Todas as skills supabase-* contêm must-include strings"
61
+ exit 0
62
+ ```
63
+
64
+ ## Verdict
65
+
66
+ - **passed** — todas as 11 skills têm strings obrigatórias
67
+ - **block** — pelo menos uma skill faltando string crítica (anti-pattern prevention quebrada)
68
+
69
+ ## Notes
70
+
71
+ Anti-pitfall A7 da v1.8: skills devem prevenir ativamente os anti-patterns Supabase mais críticos. Sem este gate, refator de skill pode acidentalmente remover a regra principal (ex: `(select auth.uid())` wrapper que previne 1000× degradação). Strings como `WARNING user_metadata`, `set search_path = ''`, `NEVER use auth-helpers-nextjs` são as primeiras coisas que LLM lê — devem estar lá.
@@ -1,62 +1,62 @@
1
- ---
2
- id: sync-idempotent
3
- stage: pre-verify
4
- blocking: false
5
- description: Valida que `kit sync claude-code` rodado 2× consecutivos produz `.claude/` byte-idêntico (anti-pitfall A1 — drift kit/ ↔ .claude/).
6
- ---
7
-
8
- # Sync idempotent gate
9
-
10
- **When to run:** pre-verify (non-blocking — warn em vez de bloquear).
11
-
12
- ## Check
13
-
14
- ```bash
15
- #!/usr/bin/env bash
16
- # PT-BR: roda sync 2× e compara — output deve ser byte-idêntico
17
- set -e
18
-
19
- TMPDIR=$(mktemp -d -t kit-mcp-sync-test-XXXXXX)
20
- trap "rm -rf $TMPDIR" EXIT
21
-
22
- # PT-BR: copia projeto root para tmpdir (sem node_modules)
23
- mkdir -p "$TMPDIR/project"
24
- cp -r kit "$TMPDIR/project/"
25
- cp package.json "$TMPDIR/project/" 2>/dev/null || true
26
-
27
- # PT-BR: 1ª execução
28
- node bin/cli.js sync install claude-code --project-root "$TMPDIR/project" >/dev/null 2>&1 || {
29
- echo "WARN: primeira sync falhou — gate inconclusivo"
30
- exit 0
31
- }
32
-
33
- # PT-BR: snapshot do output
34
- SNAPSHOT1=$(find "$TMPDIR/project/.claude" -type f -exec sha256sum {} \; 2>/dev/null | sort | sha256sum)
35
-
36
- # PT-BR: 2ª execução
37
- node bin/cli.js sync install claude-code --project-root "$TMPDIR/project" >/dev/null 2>&1
38
-
39
- # PT-BR: snapshot 2
40
- SNAPSHOT2=$(find "$TMPDIR/project/.claude" -type f -exec sha256sum {} \; 2>/dev/null | sort | sha256sum)
41
-
42
- if [ "$SNAPSHOT1" != "$SNAPSHOT2" ]; then
43
- echo "FAIL: sync não-idempotente — output diverge entre execuções"
44
- echo "Snapshot 1: $SNAPSHOT1"
45
- echo "Snapshot 2: $SNAPSHOT2"
46
- exit 1
47
- fi
48
-
49
- echo "✓ Sync idempotente — duas execuções produzem .claude/ byte-idêntico"
50
- exit 0
51
- ```
52
-
53
- ## Verdict
54
-
55
- - **passed** — `.claude/` byte-idêntico entre 2 execuções
56
- - **warn** — drift detectado (não-blocking; investigar)
57
-
58
- ## Notes
59
-
60
- Anti-pitfall A1 da v1.8: drift entre `kit/` canonical e `.claude/` stubs após adicionar 19+ items multiplicados por 8 IDE targets. Sync deve ser idempotente — qualquer fonte de não-determinismo (timestamps, ordering aleatório, hash de tempo de geração) precisa ser eliminada. Este gate detecta divergência cedo, antes de chegar em produção.
61
-
62
- **Por que non-blocking:** o gate roda CLI completo + I/O — pode falhar por razões ambientais (permissions, espaço em disco) que não são bugs de sync. Falha vira warn para revisão manual.
1
+ ---
2
+ id: sync-idempotent
3
+ stage: pre-verify
4
+ blocking: false
5
+ description: Valida que `kit sync claude-code` rodado 2× consecutivos produz `.claude/` byte-idêntico (anti-pitfall A1 — drift kit/ ↔ .claude/).
6
+ ---
7
+
8
+ # Sync idempotent gate
9
+
10
+ **When to run:** pre-verify (non-blocking — warn em vez de bloquear).
11
+
12
+ ## Check
13
+
14
+ ```bash
15
+ #!/usr/bin/env bash
16
+ # PT-BR: roda sync 2× e compara — output deve ser byte-idêntico
17
+ set -e
18
+
19
+ TMPDIR=$(mktemp -d -t kit-mcp-sync-test-XXXXXX)
20
+ trap "rm -rf $TMPDIR" EXIT
21
+
22
+ # PT-BR: copia projeto root para tmpdir (sem node_modules)
23
+ mkdir -p "$TMPDIR/project"
24
+ cp -r kit "$TMPDIR/project/"
25
+ cp package.json "$TMPDIR/project/" 2>/dev/null || true
26
+
27
+ # PT-BR: 1ª execução
28
+ node bin/cli.js sync install claude-code --project-root "$TMPDIR/project" >/dev/null 2>&1 || {
29
+ echo "WARN: primeira sync falhou — gate inconclusivo"
30
+ exit 0
31
+ }
32
+
33
+ # PT-BR: snapshot do output
34
+ SNAPSHOT1=$(find "$TMPDIR/project/.claude" -type f -exec sha256sum {} \; 2>/dev/null | sort | sha256sum)
35
+
36
+ # PT-BR: 2ª execução
37
+ node bin/cli.js sync install claude-code --project-root "$TMPDIR/project" >/dev/null 2>&1
38
+
39
+ # PT-BR: snapshot 2
40
+ SNAPSHOT2=$(find "$TMPDIR/project/.claude" -type f -exec sha256sum {} \; 2>/dev/null | sort | sha256sum)
41
+
42
+ if [ "$SNAPSHOT1" != "$SNAPSHOT2" ]; then
43
+ echo "FAIL: sync não-idempotente — output diverge entre execuções"
44
+ echo "Snapshot 1: $SNAPSHOT1"
45
+ echo "Snapshot 2: $SNAPSHOT2"
46
+ exit 1
47
+ fi
48
+
49
+ echo "✓ Sync idempotente — duas execuções produzem .claude/ byte-idêntico"
50
+ exit 0
51
+ ```
52
+
53
+ ## Verdict
54
+
55
+ - **passed** — `.claude/` byte-idêntico entre 2 execuções
56
+ - **warn** — drift detectado (não-blocking; investigar)
57
+
58
+ ## Notes
59
+
60
+ Anti-pitfall A1 da v1.8: drift entre `kit/` canonical e `.claude/` stubs após adicionar 19+ items multiplicados por 8 IDE targets. Sync deve ser idempotente — qualquer fonte de não-determinismo (timestamps, ordering aleatório, hash de tempo de geração) precisa ser eliminada. Este gate detecta divergência cedo, antes de chegar em produção.
61
+
62
+ **Por que non-blocking:** o gate roda CLI completo + I/O — pode falhar por razões ambientais (permissions, espaço em disco) que não são bugs de sync. Falha vira warn para revisão manual.
@@ -1,34 +1,34 @@
1
- ---
2
- id: verify-phase-goal
3
- stage: post-verify
4
- blocking: true
5
- description: Reverse-verify the phase goal against the codebase, not just task completion.
6
- ---
7
-
8
- # Verify phase goal gate
9
-
10
- **When to run:** after all plans in a phase have committed their SUMMARY.md.
11
-
12
- ## Check
13
-
14
- Spawn the `verifier` agent with:
15
- - phase goal (from `ROADMAP.md`)
16
- - phase requirement IDs (from PLAN frontmatters)
17
- - phase dir path
18
-
19
- The verifier checks `must_haves` against the actual codebase and cross-references
20
- every requirement ID against `REQUIREMENTS.md`. It writes `*-VERIFICATION.md`.
21
-
22
- ## Verdict
23
-
24
- - **passed** — every must-have verified → proceed to `update_roadmap`
25
- - **human_needed** — automated checks pass but some items need human eyes →
26
- persist as `*-HUMAN-UAT.md` and ask the user to test or approve
27
- - **gaps_found** — at least one must-have unverified → propose
28
- `/planejar-fase {X} --gaps` and stop the auto-chain
29
-
30
- ## Notes
31
-
32
- This gate is opinionated: phase completeness is measured against the **goal**,
33
- not the task list. A phase whose every task is checked but whose goal is half-built
34
- must not be marked complete.
1
+ ---
2
+ id: verify-phase-goal
3
+ stage: post-verify
4
+ blocking: true
5
+ description: Reverse-verify the phase goal against the codebase, not just task completion.
6
+ ---
7
+
8
+ # Verify phase goal gate
9
+
10
+ **When to run:** after all plans in a phase have committed their SUMMARY.md.
11
+
12
+ ## Check
13
+
14
+ Spawn the `verifier` agent with:
15
+ - phase goal (from `ROADMAP.md`)
16
+ - phase requirement IDs (from PLAN frontmatters)
17
+ - phase dir path
18
+
19
+ The verifier checks `must_haves` against the actual codebase and cross-references
20
+ every requirement ID against `REQUIREMENTS.md`. It writes `*-VERIFICATION.md`.
21
+
22
+ ## Verdict
23
+
24
+ - **passed** — every must-have verified → proceed to `update_roadmap`
25
+ - **human_needed** — automated checks pass but some items need human eyes →
26
+ persist as `*-HUMAN-UAT.md` and ask the user to test or approve
27
+ - **gaps_found** — at least one must-have unverified → propose
28
+ `/planejar-fase {X} --gaps` and stop the auto-chain
29
+
30
+ ## Notes
31
+
32
+ This gate is opinionated: phase completeness is measured against the **goal**,
33
+ not the task list. A phase whose every task is checked but whose goal is half-built
34
+ must not be marked complete.