elsabro 2.0.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 (58) hide show
  1. package/README.md +268 -0
  2. package/agents/elsabro-analyst.md +176 -0
  3. package/agents/elsabro-debugger.md +293 -0
  4. package/agents/elsabro-executor.md +477 -0
  5. package/agents/elsabro-orchestrator.md +426 -0
  6. package/agents/elsabro-planner.md +278 -0
  7. package/agents/elsabro-qa.md +273 -0
  8. package/agents/elsabro-quick-dev.md +309 -0
  9. package/agents/elsabro-scrum-master.md +217 -0
  10. package/agents/elsabro-tech-writer.md +347 -0
  11. package/agents/elsabro-ux-designer.md +278 -0
  12. package/agents/elsabro-verifier.md +295 -0
  13. package/agents/elsabro-yolo-dev.md +322 -0
  14. package/bin/install.js +497 -0
  15. package/commands/elsabro/add-phase.md +114 -0
  16. package/commands/elsabro/add-todo.md +158 -0
  17. package/commands/elsabro/audit-milestone.md +147 -0
  18. package/commands/elsabro/check-todos.md +192 -0
  19. package/commands/elsabro/complete-milestone.md +138 -0
  20. package/commands/elsabro/debug.md +153 -0
  21. package/commands/elsabro/discuss-phase.md +160 -0
  22. package/commands/elsabro/execute.md +299 -0
  23. package/commands/elsabro/help.md +102 -0
  24. package/commands/elsabro/insert-phase.md +117 -0
  25. package/commands/elsabro/list-phase-assumptions.md +129 -0
  26. package/commands/elsabro/map-codebase.md +108 -0
  27. package/commands/elsabro/new-milestone.md +128 -0
  28. package/commands/elsabro/new.md +230 -0
  29. package/commands/elsabro/pause-work.md +261 -0
  30. package/commands/elsabro/plan-milestone-gaps.md +129 -0
  31. package/commands/elsabro/plan.md +272 -0
  32. package/commands/elsabro/progress.md +187 -0
  33. package/commands/elsabro/quick.md +99 -0
  34. package/commands/elsabro/remove-phase.md +136 -0
  35. package/commands/elsabro/research-phase.md +174 -0
  36. package/commands/elsabro/resume-work.md +288 -0
  37. package/commands/elsabro/set-profile.md +216 -0
  38. package/commands/elsabro/settings.md +185 -0
  39. package/commands/elsabro/start.md +204 -0
  40. package/commands/elsabro/update.md +71 -0
  41. package/commands/elsabro/verify-work.md +269 -0
  42. package/commands/elsabro/verify.md +207 -0
  43. package/hooks/dist/.gitkeep +2 -0
  44. package/package.json +45 -0
  45. package/references/error-handling-instructions.md +312 -0
  46. package/references/source-hierarchy.md +150 -0
  47. package/references/token-optimization.md +225 -0
  48. package/skills/api-setup.md +315 -0
  49. package/skills/auth-setup.md +180 -0
  50. package/skills/database-setup.md +238 -0
  51. package/skills/expo-app.md +261 -0
  52. package/skills/nextjs-app.md +206 -0
  53. package/skills/payments-setup.md +421 -0
  54. package/skills/sentry-setup.md +295 -0
  55. package/templates/error-handling-config.json +138 -0
  56. package/templates/session-state.json +69 -0
  57. package/templates/starters/.gitkeep +2 -0
  58. package/workflows/.gitkeep +2 -0
@@ -0,0 +1,207 @@
1
+ ---
2
+ name: verify
3
+ description: Verificar que una fase o feature funciona correctamente
4
+ allowed-tools:
5
+ - Read
6
+ - Bash
7
+ - Glob
8
+ - Grep
9
+ - Task
10
+ - AskUserQuestion
11
+ - mcp__plugin_playwright_playwright__*
12
+ argument-hint: "[número de fase o 'manual']"
13
+ ---
14
+
15
+ # ELSABRO: Verify
16
+
17
+ <objective>
18
+ Verificar que una fase o feature cumple con sus objetivos usando:
19
+ - Tests automáticos
20
+ - Build verification
21
+ - Verificación manual guiada cuando es necesario
22
+ </objective>
23
+
24
+ <process>
25
+ ## Paso 1: Identificar Qué Verificar
26
+
27
+ Si hay argumento numérico → Verificar fase del ROADMAP
28
+ Si argumento es "manual" → Verificación manual completa
29
+ Si no hay argumento → Verificar último trabajo realizado
30
+
31
+ ## Paso 2: Cargar Contexto
32
+
33
+ ```bash
34
+ # Buscar archivos de verificación
35
+ ls .planning/*-VERIFICATION.md
36
+ ls .planning/*-SUMMARY.md
37
+ ```
38
+
39
+ ## Paso 3: Ejecutar Verificaciones Automáticas
40
+
41
+ ```
42
+ Task(elsabro-verifier):
43
+ Verifica fase [N]:
44
+
45
+ 1. Leer must_haves de los PLAN.md
46
+ 2. Ejecutar comandos de <verify>
47
+ 3. Verificar artifacts existen
48
+ 4. Verificar truths son verdaderas
49
+ 5. Generar VERIFICATION.md
50
+ ```
51
+
52
+ ## Paso 4: Verificación Manual (si necesaria)
53
+
54
+ Presentar al usuario pasos claros:
55
+
56
+ ```
57
+ Para ti (Usuario):
58
+
59
+ Vamos a verificar que todo funciona correctamente.
60
+ Por favor sigue estos pasos:
61
+
62
+ 1. [Paso claro y específico]
63
+ → Resultado esperado: [descripción]
64
+
65
+ 2. [Siguiente paso]
66
+ → Resultado esperado: [descripción]
67
+
68
+ Cuando termines, dime:
69
+ - ¿Funcionó todo como se describe?
70
+ - ¿Hubo algo diferente o algún error?
71
+ ```
72
+
73
+ ## Paso 5: Reportar Resultado
74
+
75
+ ### Si todo pasa:
76
+ ```
77
+ ✓ Verificación completada
78
+
79
+ Fase [N] verificada correctamente:
80
+ - [X] Build exitoso
81
+ - [X] Tests pasan
82
+ - [X] Funcionalidad verificada
83
+
84
+ ¿Siguiente paso?
85
+ - Continuar con fase [N+1]: /elsabro:plan [N+1]
86
+ - Revisar el código: Ver archivos modificados
87
+ ```
88
+
89
+ ### Si hay problemas:
90
+ ```
91
+ ⚠ Verificación encontró problemas
92
+
93
+ Problemas detectados:
94
+ 1. [Problema]
95
+ 2. [Problema]
96
+
97
+ Opciones:
98
+ 1. Investigar y arreglar: /elsabro:debug
99
+ 2. Ver detalles: cat .planning/[N]-VERIFICATION.md
100
+ 3. Ignorar y continuar (no recomendado)
101
+ ```
102
+ </process>
103
+
104
+ <verification_levels>
105
+ ## Niveles de Verificación
106
+
107
+ ### Level 1: Exists
108
+ - ¿El archivo/función existe?
109
+ - Verificación: Glob/Grep
110
+
111
+ ### Level 2: Substantive
112
+ - ¿El código tiene la lógica esperada?
113
+ - Verificación: Grep patrones específicos
114
+
115
+ ### Level 3: Wired
116
+ - ¿Los componentes están conectados?
117
+ - Verificación: Import statements, route definitions
118
+
119
+ ### Level 4: Works
120
+ - ¿Funciona como se espera?
121
+ - Verificación: Tests, verificación manual
122
+ </verification_levels>
123
+
124
+ <manual_verification_templates>
125
+ ## Templates de Verificación Manual
126
+
127
+ ### Para UI/Frontend
128
+ ```
129
+ Verificación manual:
130
+
131
+ 1. Abre tu navegador en http://localhost:3000
132
+ 2. Ve a [ruta específica]
133
+ 3. [Acción]: Click en [elemento]
134
+ 4. Deberías ver: [resultado esperado]
135
+
136
+ ¿Lo ves?
137
+ ```
138
+
139
+ ### Para API
140
+ ```
141
+ Verificación manual:
142
+
143
+ 1. Abre una terminal
144
+ 2. Ejecuta: curl http://localhost:3000/api/[endpoint]
145
+ 3. Deberías ver: {"success": true, ...}
146
+
147
+ ¿Recibes esa respuesta?
148
+ ```
149
+
150
+ ### Para Base de Datos
151
+ ```
152
+ Verificación manual:
153
+
154
+ 1. Ejecuta: npx prisma studio
155
+ 2. Se abre una ventana en tu navegador
156
+ 3. Deberías ver las tablas: [lista]
157
+
158
+ ¿Las ves?
159
+ ```
160
+
161
+ ### Para Autenticación
162
+ ```
163
+ Verificación manual:
164
+
165
+ 1. Abre http://localhost:3000/login
166
+ 2. Ingresa un email y contraseña de prueba
167
+ 3. Click en "Iniciar sesión"
168
+ 4. Deberías ser redirigido a: [ruta]
169
+
170
+ ¿Funcionó?
171
+ ```
172
+ </manual_verification_templates>
173
+
174
+ <gap_handling>
175
+ ## Manejo de Gaps
176
+
177
+ Cuando se encuentra un gap:
178
+
179
+ ```yaml
180
+ gaps:
181
+ - type: missing_file
182
+ path: src/components/Button.tsx
183
+ severity: critical
184
+ action: crear archivo
185
+
186
+ - type: test_failing
187
+ test: "should validate email"
188
+ error: "Expected true, got false"
189
+ severity: high
190
+ action: revisar lógica
191
+
192
+ - type: behavior_mismatch
193
+ expected: "Redirige a /dashboard"
194
+ actual: "Se queda en /login"
195
+ severity: medium
196
+ action: verificar auth middleware
197
+ ```
198
+
199
+ ### Por Severidad:
200
+
201
+ | Severidad | Acción |
202
+ |-----------|--------|
203
+ | critical | STOP - no continuar hasta resolver |
204
+ | high | Crear plan de corrección |
205
+ | medium | Documentar para después |
206
+ | low | Opcional arreglar |
207
+ </gap_handling>
@@ -0,0 +1,2 @@
1
+ # Compiled hooks will be placed here
2
+ # Run: npm run build:hooks to compile from hooks/src/
package/package.json ADDED
@@ -0,0 +1,45 @@
1
+ {
2
+ "name": "elsabro",
3
+ "version": "2.0.0",
4
+ "description": "Sistema de desarrollo AI-powered para Claude Code - El mejor asistente para crear apps sin experiencia previa",
5
+ "bin": {
6
+ "elsabro": "bin/install.js"
7
+ },
8
+ "files": [
9
+ "bin",
10
+ "commands",
11
+ "agents",
12
+ "skills",
13
+ "templates",
14
+ "workflows",
15
+ "references",
16
+ "hooks/dist"
17
+ ],
18
+ "keywords": [
19
+ "claude",
20
+ "claude-code",
21
+ "ai",
22
+ "development",
23
+ "no-code",
24
+ "low-code",
25
+ "nextjs",
26
+ "expo",
27
+ "react-native"
28
+ ],
29
+ "author": "CUBAIT",
30
+ "license": "MIT",
31
+ "repository": {
32
+ "type": "git",
33
+ "url": "git+https://github.com/goat1990/elsabro.git"
34
+ },
35
+ "homepage": "https://github.com/goat1990/elsabro",
36
+ "bugs": {
37
+ "url": "https://github.com/goat1990/elsabro/issues"
38
+ },
39
+ "engines": {
40
+ "node": ">=18.0.0"
41
+ },
42
+ "scripts": {
43
+ "test": "echo \"No tests yet\" && exit 0"
44
+ }
45
+ }
@@ -0,0 +1,312 @@
1
+ # Instrucciones de Error Handling para Agentes ELSABRO
2
+
3
+ Este documento define cómo los agentes deben manejar errores de forma consistente.
4
+
5
+ ## Clasificación de Errores
6
+
7
+ Cuando encuentres un error, clasifícalo usando esta escala:
8
+
9
+ ### 🔴 CRITICAL - No puede continuar
10
+
11
+ ```json
12
+ {
13
+ "severity": "CRITICAL",
14
+ "code": "ERROR_CODE",
15
+ "message": "Descripción del error",
16
+ "canContinue": false,
17
+ "suggestedAction": "Qué debe hacer el usuario"
18
+ }
19
+ ```
20
+
21
+ **Ejemplos:**
22
+ - SESSION.md corrupto o faltante
23
+ - Archivos de configuración críticos inválidos
24
+ - Dependencias con versiones incompatibles
25
+ - Estado de git inconsistente (detached HEAD, conflictos)
26
+
27
+ **Acción:** Parar inmediatamente, mostrar error, sugerir solución.
28
+
29
+ ---
30
+
31
+ ### 🟠 HIGH - Debería parar
32
+
33
+ ```json
34
+ {
35
+ "severity": "HIGH",
36
+ "code": "ERROR_CODE",
37
+ "message": "Descripción del error",
38
+ "canContinue": true,
39
+ "suggestedAction": "Qué debe hacer el usuario",
40
+ "options": ["fix", "skip", "abort"]
41
+ }
42
+ ```
43
+
44
+ **Ejemplos:**
45
+ - Tests fallando
46
+ - Build fallido
47
+ - Validación de schema falló
48
+ - API calls fallando
49
+
50
+ **Acción:** Mostrar error, ofrecer opciones:
51
+ - `[f]` Arreglar ahora
52
+ - `[s]` Saltar (no recomendado)
53
+ - `[a]` Abortar
54
+
55
+ ---
56
+
57
+ ### 🟡 MEDIUM - Warning
58
+
59
+ ```json
60
+ {
61
+ "severity": "MEDIUM",
62
+ "code": "WARNING_CODE",
63
+ "message": "Descripción del warning",
64
+ "canContinue": true,
65
+ "note": "Información adicional"
66
+ }
67
+ ```
68
+
69
+ **Ejemplos:**
70
+ - Lint warnings
71
+ - Deprecation warnings
72
+ - Coverage bajo pero aceptable
73
+ - Archivos sin usar detectados
74
+
75
+ **Acción:** Mostrar warning, continuar automáticamente.
76
+
77
+ ---
78
+
79
+ ### ⬜ LOW - Informativo
80
+
81
+ ```json
82
+ {
83
+ "severity": "LOW",
84
+ "code": "INFO_CODE",
85
+ "message": "Información"
86
+ }
87
+ ```
88
+
89
+ **Ejemplos:**
90
+ - Retry exitoso después de fallo temporal
91
+ - Operación completada con notas
92
+ - Sugerencias de mejora
93
+
94
+ **Acción:** Registrar, continuar.
95
+
96
+ ---
97
+
98
+ ## Display de Errores
99
+
100
+ Usa este formato visual para errores:
101
+
102
+ ### Error CRITICAL
103
+ ```
104
+ ╔══════════════════════════════════════════════════╗
105
+ ║ 🔴 ERROR: SESSION_MISSING ║
106
+ ║ Severity: CRITICAL ║
107
+ ╠══════════════════════════════════════════════════╣
108
+ ║ ║
109
+ ║ No se encontró el archivo de sesión ║
110
+ ║ ║
111
+ ║ El archivo .planning/SESSION.md no existe ║
112
+ ║ o está corrupto. ║
113
+ ║ ║
114
+ ╠══════════════════════════════════════════════════╣
115
+ ║ ACCIÓN REQUERIDA: ║
116
+ ║ → /elsabro:start para iniciar nueva sesión ║
117
+ ╚══════════════════════════════════════════════════╝
118
+ ```
119
+
120
+ ### Error HIGH con Opciones
121
+ ```
122
+ ╔══════════════════════════════════════════════════╗
123
+ ║ 🟠 ERROR: TESTS_FAILED ║
124
+ ║ Severity: HIGH ║
125
+ ╠══════════════════════════════════════════════════╣
126
+ ║ ║
127
+ ║ 3 tests fallaron en src/__tests__/ ║
128
+ ║ ║
129
+ ║ Detalles: ║
130
+ ║ - Profile.test.ts: Expected "John" got null ║
131
+ ║ - Auth.test.ts: Timeout after 5000ms ║
132
+ ║ ║
133
+ ╠══════════════════════════════════════════════════╣
134
+ ║ Opciones: ║
135
+ ║ [d] /elsabro:debug - Investigar fallos ║
136
+ ║ [s] Saltar tests (no recomendado) ║
137
+ ║ [a] Abortar operación ║
138
+ ╚══════════════════════════════════════════════════╝
139
+ ```
140
+
141
+ ### Warning MEDIUM
142
+ ```
143
+ ┌──────────────────────────────────────────────────┐
144
+ │ 🟡 WARNING: LINT_WARNINGS │
145
+ ├──────────────────────────────────────────────────┤
146
+ │ 5 lint warnings encontrados │
147
+ │ Considera arreglar antes de commit │
148
+ │ │
149
+ │ Continuando automáticamente... │
150
+ └──────────────────────────────────────────────────┘
151
+ ```
152
+
153
+ ---
154
+
155
+ ## Manejo de Ejecución Paralela
156
+
157
+ Cuando ejecutes múltiples agentes en paralelo, sigue estas reglas:
158
+
159
+ ### Policy: fail_fast
160
+ ```
161
+ Si cualquier agente falla → PARAR TODO
162
+ - Detener agentes en ejecución
163
+ - Reportar qué agente falló
164
+ - NO continuar con siguientes pasos
165
+ ```
166
+
167
+ ### Policy: quorum (default)
168
+ ```
169
+ Continuar si >50% tienen éxito
170
+ - Esperar a que todos terminen
171
+ - Contar éxitos vs fallos
172
+ - Si ≥50% OK → continuar con resultados parciales
173
+ - Si <50% OK → PARAR y reportar
174
+ ```
175
+
176
+ ### Policy: continue_all
177
+ ```
178
+ Continuar siempre
179
+ - Esperar a que todos terminen
180
+ - Recopilar todos los resultados
181
+ - Reportar fallos pero continuar
182
+ ```
183
+
184
+ ### Policy: critical_path
185
+ ```
186
+ Para solo si falla un agente crítico
187
+ - Marcar agentes como críticos u opcionales
188
+ - Si agente crítico falla → PARAR
189
+ - Si agente opcional falla → Continuar
190
+ - Usar cuando algunos agentes son esenciales
191
+ ```
192
+
193
+ Ejemplo de configuración:
194
+ ```json
195
+ {
196
+ "criticalAgents": ["elsabro-executor", "elsabro-verifier"],
197
+ "optionalAgents": ["elsabro-analyzer", "elsabro-documenter"]
198
+ }
199
+ ```
200
+
201
+ ### Reporte de Ejecución Paralela
202
+ ```
203
+ ╔══════════════════════════════════════════════════╗
204
+ ║ PARALLEL EXECUTION COMPLETE ║
205
+ ╠══════════════════════════════════════════════════╣
206
+ ║ Policy: quorum ║
207
+ ║ Total: 4 agents ║
208
+ ║ ║
209
+ ║ ✓ Agent 1 (code-reviewer): SUCCESS (45s) ║
210
+ ║ ✓ Agent 2 (typescript-pro): SUCCESS (32s) ║
211
+ ║ ✗ Agent 3 (silent-failure): FAILED (timeout) ║
212
+ ║ ✓ Agent 4 (test-analyzer): SUCCESS (28s) ║
213
+ ║ ║
214
+ ║ Result: 3/4 (75%) - QUORUM MET ║
215
+ ║ Status: CONTINUING ║
216
+ ╚══════════════════════════════════════════════════╝
217
+ ```
218
+
219
+ ---
220
+
221
+ ## Manejo de Retry
222
+
223
+ Cuando una operación falle, usa retry con backoff exponencial:
224
+
225
+ ### Configuración Default
226
+ ```
227
+ Attempt 1: Ejecutar inmediatamente
228
+ Attempt 2: Esperar 1s, reintentar
229
+ Attempt 3: Esperar 2s, reintentar
230
+ (Máximo 3 intentos, timeout total 2 min)
231
+ ```
232
+
233
+ ### Reporte de Retry
234
+ ```
235
+ ┌──────────────────────────────────────────────────┐
236
+ │ RETRY: npm test │
237
+ ├──────────────────────────────────────────────────┤
238
+ │ Attempt 1/3: FAILED (timeout) │
239
+ │ Waiting 1s before retry... │
240
+ │ │
241
+ │ Attempt 2/3: FAILED (exit code 1) │
242
+ │ Waiting 2s before retry... │
243
+ │ │
244
+ │ Attempt 3/3: FAILED (exit code 1) │
245
+ │ │
246
+ │ ❌ All attempts exhausted │
247
+ │ → Error escalated to user │
248
+ └──────────────────────────────────────────────────┘
249
+ ```
250
+
251
+ ### Después de Agotar Retries
252
+ ```
253
+ ╔══════════════════════════════════════════════════╗
254
+ ║ 🟠 RETRY EXHAUSTED: npm test ║
255
+ ╠══════════════════════════════════════════════════╣
256
+ ║ ║
257
+ ║ Intentos: 3/3 agotados ║
258
+ ║ Tiempo total: 8.5s ║
259
+ ║ ║
260
+ ║ Último error: ║
261
+ ║ > Test suite failed to run ║
262
+ ║ > Cannot find module '@/utils' ║
263
+ ║ ║
264
+ ╠══════════════════════════════════════════════════╣
265
+ ║ El problema parece ser: ║
266
+ ║ → Dependencia faltante o path alias incorrecto ║
267
+ ║ ║
268
+ ║ Opciones: ║
269
+ ║ [d] Investigar con /elsabro:debug ║
270
+ ║ [r] Reintentar después de arreglar ║
271
+ ║ [a] Abortar ║
272
+ ╚══════════════════════════════════════════════════╝
273
+ ```
274
+
275
+ ---
276
+
277
+ ## Actualización de Estado
278
+
279
+ Después de cada operación significativa, actualiza `.planning/SESSION-STATE.json`:
280
+
281
+ ```json
282
+ {
283
+ "lastUpdated": "2024-01-20T15:30:00Z",
284
+ "context": {
285
+ "milestone": "M001",
286
+ "phase": "P3",
287
+ "progress": 65,
288
+ "currentTask": "Implement user profile"
289
+ },
290
+ "errors": {
291
+ "count": 1,
292
+ "lastError": {
293
+ "code": "TESTS_FAILED",
294
+ "severity": "HIGH",
295
+ "at": "2024-01-20T15:25:00Z",
296
+ "resolved": false
297
+ }
298
+ }
299
+ }
300
+ ```
301
+
302
+ ---
303
+
304
+ ## Checklist para Agentes
305
+
306
+ Antes de reportar "completado":
307
+
308
+ - [ ] ¿Hubo errores? → Clasificados y reportados
309
+ - [ ] ¿Hubo warnings? → Listados al final
310
+ - [ ] ¿Estado actualizado? → SESSION-STATE.json actualizado
311
+ - [ ] ¿Retry necesario? → Intentado con backoff
312
+ - [ ] ¿Ejecución paralela? → Política aplicada, resultados agregados