up-cc 0.3.3 → 0.4.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.
- package/LICENSE +21 -0
- package/README.md +259 -49
- package/agents/up-api-tester.md +405 -0
- package/agents/up-arquiteto.md +461 -0
- package/agents/up-backend-specialist.md +158 -0
- package/agents/up-blind-validator.md +259 -0
- package/agents/up-clone-crawler.md +234 -0
- package/agents/up-clone-design-extractor.md +227 -0
- package/agents/up-clone-feature-mapper.md +225 -0
- package/agents/up-clone-prd-writer.md +169 -0
- package/agents/up-clone-verifier.md +227 -0
- package/agents/up-code-reviewer.md +225 -0
- package/agents/up-database-specialist.md +152 -0
- package/agents/up-devops-agent.md +203 -0
- package/agents/up-executor.md +45 -5
- package/agents/up-exhaustive-tester.md +348 -0
- package/agents/up-frontend-specialist.md +135 -0
- package/agents/up-product-analyst.md +192 -0
- package/agents/up-qa-agent.md +171 -0
- package/agents/up-requirements-validator.md +230 -0
- package/agents/up-security-reviewer.md +137 -0
- package/agents/up-system-designer.md +332 -0
- package/agents/up-technical-writer.md +188 -0
- package/agents/up-visual-critic.md +358 -0
- package/bin/up-tools.cjs +84 -2
- package/commands/clone-builder.md +67 -0
- package/commands/dashboard.md +48 -0
- package/commands/depurar.md +1 -1
- package/commands/mobile-first.md +71 -0
- package/commands/modo-builder.md +178 -0
- package/commands/ux-tester.md +63 -0
- package/package.json +1 -1
- package/references/blueprints/audit.md +29 -0
- package/references/blueprints/booking.md +49 -0
- package/references/blueprints/community.md +48 -0
- package/references/blueprints/crm.md +40 -0
- package/references/blueprints/dashboard.md +48 -0
- package/references/blueprints/data-management.md +42 -0
- package/references/blueprints/ecommerce.md +51 -0
- package/references/blueprints/marketplace.md +48 -0
- package/references/blueprints/notifications.md +32 -0
- package/references/blueprints/saas-users.md +50 -0
- package/references/blueprints/settings.md +31 -0
- package/references/engineering-principles.md +205 -0
- package/references/production-requirements.md +106 -0
- package/references/state-persistence.md +74 -0
- package/templates/builder-defaults.md +73 -0
- package/templates/delivery.md +279 -0
- package/templates/design-tokens.md +151 -0
- package/workflows/builder-e2e.md +501 -0
- package/workflows/builder.md +2248 -0
- package/workflows/clone-builder.md +320 -0
- package/workflows/executar-fase.md +28 -2
- package/workflows/executar-plano.md +404 -6
- package/workflows/mobile-first.md +692 -0
- package/workflows/novo-projeto.md +22 -0
- package/workflows/rapido.md +1 -1
- package/workflows/ux-tester.md +500 -0
|
@@ -0,0 +1,320 @@
|
|
|
1
|
+
<purpose>
|
|
2
|
+
Clone Builder: analisar app existente via Playwright e recriar com o modo-builder.
|
|
3
|
+
|
|
4
|
+
Pipeline:
|
|
5
|
+
1. Intake (perguntas)
|
|
6
|
+
2. Crawl (navegar e coletar)
|
|
7
|
+
3. Analyze (design + features em paralelo)
|
|
8
|
+
4. PRD (sintetizar)
|
|
9
|
+
5. Builder (recriar — usa pipeline existente do modo-builder)
|
|
10
|
+
6. Clone Verify (verificar fidelidade no quality gate)
|
|
11
|
+
</purpose>
|
|
12
|
+
|
|
13
|
+
<process>
|
|
14
|
+
|
|
15
|
+
## Fase 1: Intake
|
|
16
|
+
|
|
17
|
+
### 1.1 Parsear Argumentos
|
|
18
|
+
|
|
19
|
+
Extrair do $ARGUMENTS:
|
|
20
|
+
- URL do app (obrigatorio)
|
|
21
|
+
- Modo: `--exact` (default), `--improve`, `--inspiration`
|
|
22
|
+
|
|
23
|
+
### 1.2 Perguntas
|
|
24
|
+
|
|
25
|
+
```
|
|
26
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
27
|
+
UP > CLONE BUILDER
|
|
28
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
29
|
+
|
|
30
|
+
App a clonar: {URL}
|
|
31
|
+
Modo: {exact|improve|inspiration}
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
Perguntar via AskUserQuestion:
|
|
35
|
+
|
|
36
|
+
1. **Credenciais do app** (se precisa login):
|
|
37
|
+
- Email e senha de demo/trial
|
|
38
|
+
- Ou "nao precisa" se app e publico
|
|
39
|
+
|
|
40
|
+
2. **Stack desejada** (ou "usar defaults"):
|
|
41
|
+
- Frontend, backend, banco
|
|
42
|
+
- Ou: "usar builder-defaults.md"
|
|
43
|
+
|
|
44
|
+
3. **Credenciais do banco** (para o clone):
|
|
45
|
+
- Supabase URL + anon key + service role key
|
|
46
|
+
- Ou outro banco
|
|
47
|
+
|
|
48
|
+
4. **Se modo improve/inspiration:** O que quer diferente?
|
|
49
|
+
|
|
50
|
+
═══════════════════════════════════════════════════════
|
|
51
|
+
FIM DA INTERACAO
|
|
52
|
+
═══════════════════════════════════════════════════════
|
|
53
|
+
|
|
54
|
+
### 1.3 Setup
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
mkdir -p .plano/clone/screenshots/desktop .plano/clone/screenshots/mobile .plano/clone/network .plano/clone/forms .plano/clone/snapshots .plano/clone/verify
|
|
58
|
+
git init 2>/dev/null
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
Salvar `.plano/BRIEFING.md` com URL, credenciais, stack, modo.
|
|
62
|
+
|
|
63
|
+
Iniciar dashboard:
|
|
64
|
+
```bash
|
|
65
|
+
node "$HOME/.claude/up/dashboard/server.js" 4040 "$(pwd)/.plano" &
|
|
66
|
+
DASH_PID=$!
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
---
|
|
70
|
+
|
|
71
|
+
## Fase 2: Crawl
|
|
72
|
+
|
|
73
|
+
```
|
|
74
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
75
|
+
CLONE > NAVEGANDO APP ORIGINAL
|
|
76
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
```
|
|
80
|
+
Task(
|
|
81
|
+
subagent_type="up-clone-crawler",
|
|
82
|
+
prompt="
|
|
83
|
+
<objective>
|
|
84
|
+
Navegar o app em {URL} completamente. Screenshots de todas paginas,
|
|
85
|
+
interceptar APIs, extrair forms, mapear navegacao.
|
|
86
|
+
{Se credenciais: fazer login com {EMAIL}/{PASSWORD}}
|
|
87
|
+
</objective>
|
|
88
|
+
|
|
89
|
+
<credentials>
|
|
90
|
+
URL: {URL}
|
|
91
|
+
Email: {EMAIL ou 'nenhum'}
|
|
92
|
+
Password: {PASSWORD ou 'nenhum'}
|
|
93
|
+
</credentials>
|
|
94
|
+
",
|
|
95
|
+
description="Crawl do app original"
|
|
96
|
+
)
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
```
|
|
100
|
+
Crawl: {N} rotas | {M} screenshots | {X} APIs | {Y} forms
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
---
|
|
104
|
+
|
|
105
|
+
## Fase 3: Analyze (2 agentes em PARALELO)
|
|
106
|
+
|
|
107
|
+
```
|
|
108
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
109
|
+
CLONE > ANALISANDO
|
|
110
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
Spawnar em PARALELO:
|
|
114
|
+
|
|
115
|
+
```
|
|
116
|
+
Task(
|
|
117
|
+
subagent_type="up-clone-design-extractor",
|
|
118
|
+
prompt="
|
|
119
|
+
<objective>
|
|
120
|
+
Analisar screenshots e extrair design system completo do app em {URL}.
|
|
121
|
+
</objective>
|
|
122
|
+
|
|
123
|
+
<files_to_read>
|
|
124
|
+
- .plano/clone/CRAWL-DATA.md
|
|
125
|
+
</files_to_read>
|
|
126
|
+
|
|
127
|
+
<app_url>{URL}</app_url>
|
|
128
|
+
",
|
|
129
|
+
description="Extrair design system"
|
|
130
|
+
)
|
|
131
|
+
|
|
132
|
+
Task(
|
|
133
|
+
subagent_type="up-clone-feature-mapper",
|
|
134
|
+
prompt="
|
|
135
|
+
<objective>
|
|
136
|
+
Mapear modulos, features, roles, data model, fluxos e integracoes do app.
|
|
137
|
+
</objective>
|
|
138
|
+
|
|
139
|
+
<files_to_read>
|
|
140
|
+
- .plano/clone/CRAWL-DATA.md
|
|
141
|
+
- .plano/clone/network/ (ler todos)
|
|
142
|
+
- .plano/clone/forms/ (ler todos)
|
|
143
|
+
</files_to_read>
|
|
144
|
+
",
|
|
145
|
+
description="Mapear features e data model"
|
|
146
|
+
)
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
```
|
|
150
|
+
Design: {N} cores | {M} componentes | Layout: {tipo}
|
|
151
|
+
Features: {N} modulos | {M} features | {X} roles | {Y} entidades
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
---
|
|
155
|
+
|
|
156
|
+
## Fase 4: PRD
|
|
157
|
+
|
|
158
|
+
```
|
|
159
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
160
|
+
CLONE > GERANDO PRD
|
|
161
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
162
|
+
```
|
|
163
|
+
|
|
164
|
+
```
|
|
165
|
+
Task(
|
|
166
|
+
subagent_type="up-clone-prd-writer",
|
|
167
|
+
prompt="
|
|
168
|
+
<objective>
|
|
169
|
+
Sintetizar analise em PRD completo para o modo-builder.
|
|
170
|
+
</objective>
|
|
171
|
+
|
|
172
|
+
<files_to_read>
|
|
173
|
+
- .plano/BRIEFING.md (stack e preferencias)
|
|
174
|
+
- .plano/clone/CRAWL-DATA.md
|
|
175
|
+
- .plano/clone/DESIGN-SYSTEM.md
|
|
176
|
+
- .plano/clone/FEATURE-MAP.md
|
|
177
|
+
</files_to_read>
|
|
178
|
+
|
|
179
|
+
<clone_mode>{exact|improve|inspiration}</clone_mode>
|
|
180
|
+
",
|
|
181
|
+
description="Gerar PRD do clone"
|
|
182
|
+
)
|
|
183
|
+
```
|
|
184
|
+
|
|
185
|
+
```
|
|
186
|
+
PRD: {N} modulos | {M} features | {X} fluxos | Modo: {modo}
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
---
|
|
190
|
+
|
|
191
|
+
## Fase 5: Modo Builder
|
|
192
|
+
|
|
193
|
+
```
|
|
194
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
195
|
+
CLONE > CONSTRUINDO COM MODO BUILDER
|
|
196
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
197
|
+
```
|
|
198
|
+
|
|
199
|
+
Alimentar o modo-builder com o CLONE-PRD.md como briefing.
|
|
200
|
+
|
|
201
|
+
**IMPORTANTE:** Configurar builder para modo clone:
|
|
202
|
+
|
|
203
|
+
config.json deve ter:
|
|
204
|
+
```json
|
|
205
|
+
{
|
|
206
|
+
"builder_mode": true,
|
|
207
|
+
"builder_type": "clone",
|
|
208
|
+
"clone_source": "{URL}",
|
|
209
|
+
"clone_mode": "{exact|improve|inspiration}",
|
|
210
|
+
"clone_data": ".plano/clone/"
|
|
211
|
+
}
|
|
212
|
+
```
|
|
213
|
+
|
|
214
|
+
**O builder recebe instrucoes especiais no modo clone:**
|
|
215
|
+
|
|
216
|
+
1. **Product Analyst:** Se modo exact — NAO sugerir mudancas, apenas validar. Se improve — pode sugerir adicoes.
|
|
217
|
+
2. **System Designer:** Usar data model do FEATURE-MAP.md como base. Usar design system do DESIGN-SYSTEM.md.
|
|
218
|
+
3. **Frontend Specialist:** LER screenshots de .plano/clone/screenshots/ e replicar layout/design.
|
|
219
|
+
4. **Code Reviewer:** Verificar fidelidade visual alem de production-requirements.
|
|
220
|
+
5. **Quality Gate:** Incluir dimensao "Fidelidade" com clone-verifier.
|
|
221
|
+
|
|
222
|
+
Executar o pipeline COMPLETO do builder:
|
|
223
|
+
- Estagio 2: Arquitetura (3 agentes + validator)
|
|
224
|
+
- Estagio 3: Build (RARV + specialist routing)
|
|
225
|
+
- Estagio 4: Quality Gate (com clone-verifier como dimensao extra)
|
|
226
|
+
- Estagio 5: Entrega
|
|
227
|
+
|
|
228
|
+
**O builder sabe que e clone** pelo `builder_type: "clone"` no config.json. Cada agente que le config.json adapta seu comportamento.
|
|
229
|
+
|
|
230
|
+
---
|
|
231
|
+
|
|
232
|
+
## Fase 6: Clone Verification (integrado no Quality Gate)
|
|
233
|
+
|
|
234
|
+
O clone-verifier roda como parte do quality gate do builder:
|
|
235
|
+
|
|
236
|
+
```
|
|
237
|
+
Task(
|
|
238
|
+
subagent_type="up-clone-verifier",
|
|
239
|
+
prompt="
|
|
240
|
+
<objective>
|
|
241
|
+
Verificar fidelidade do clone contra o app original.
|
|
242
|
+
Testar feature a feature (funcional) e pagina a pagina (visual).
|
|
243
|
+
</objective>
|
|
244
|
+
|
|
245
|
+
<files_to_read>
|
|
246
|
+
- .plano/clone/FEATURE-MAP.md (lista de features CLONE-*)
|
|
247
|
+
- .plano/clone/CRAWL-DATA.md (rotas do original)
|
|
248
|
+
- .plano/clone/DESIGN-SYSTEM.md (design reference)
|
|
249
|
+
- .plano/config.json (clone_source URL)
|
|
250
|
+
</files_to_read>
|
|
251
|
+
",
|
|
252
|
+
description="Verificar fidelidade do clone"
|
|
253
|
+
)
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
Se fidelidade < 9.0:
|
|
257
|
+
- Features MISSING → criar planos + executar
|
|
258
|
+
- Features BROKEN → debugar + corrigir
|
|
259
|
+
- Visual off → ajustar CSS/componentes
|
|
260
|
+
- Re-verificar
|
|
261
|
+
|
|
262
|
+
---
|
|
263
|
+
|
|
264
|
+
## Fase 7: Entrega
|
|
265
|
+
|
|
266
|
+
O DELIVERY.md do builder inclui secao extra de clone:
|
|
267
|
+
|
|
268
|
+
```markdown
|
|
269
|
+
## Fidelidade ao Original
|
|
270
|
+
|
|
271
|
+
**Score:** {N}/10
|
|
272
|
+
**Funcional:** {N}/10 ({match}/{total} features)
|
|
273
|
+
**Visual:** {N}/10
|
|
274
|
+
|
|
275
|
+
| Status | Quantidade |
|
|
276
|
+
|--------|-----------|
|
|
277
|
+
| MATCH | {N} |
|
|
278
|
+
| IMPROVED | {N} |
|
|
279
|
+
| PARTIAL | {N} |
|
|
280
|
+
| MISSING | {N} |
|
|
281
|
+
| BROKEN | {N} |
|
|
282
|
+
|
|
283
|
+
Screenshots comparativos: .plano/clone/verify/
|
|
284
|
+
```
|
|
285
|
+
|
|
286
|
+
Cleanup:
|
|
287
|
+
```bash
|
|
288
|
+
kill $DASH_PID 2>/dev/null
|
|
289
|
+
```
|
|
290
|
+
|
|
291
|
+
```
|
|
292
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
293
|
+
CLONE BUILDER > COMPLETO
|
|
294
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
295
|
+
|
|
296
|
+
**Original:** {URL}
|
|
297
|
+
**Clone:** http://localhost:{PORT}
|
|
298
|
+
**Fidelidade:** {N}/10
|
|
299
|
+
|
|
300
|
+
Features: {match} MATCH | {partial} PARTIAL | {missing} MISSING | {broken} BROKEN
|
|
301
|
+
Quality Score: {N}/10
|
|
302
|
+
|
|
303
|
+
Relatorio: .plano/DELIVERY.md
|
|
304
|
+
Comparativo: .plano/clone/verify/
|
|
305
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
306
|
+
```
|
|
307
|
+
|
|
308
|
+
</process>
|
|
309
|
+
|
|
310
|
+
<success_criteria>
|
|
311
|
+
- [ ] App original crawled (todas rotas, screenshots, APIs, forms)
|
|
312
|
+
- [ ] Design system extraido
|
|
313
|
+
- [ ] Features mapeadas com IDs CLONE-*
|
|
314
|
+
- [ ] PRD gerado completo
|
|
315
|
+
- [ ] Builder executou com config clone
|
|
316
|
+
- [ ] Clone verificado feature a feature contra original
|
|
317
|
+
- [ ] Clone verificado visualmente contra original
|
|
318
|
+
- [ ] Score de fidelidade >= 9.0 (ou max esforco)
|
|
319
|
+
- [ ] DELIVERY.md com secao de fidelidade
|
|
320
|
+
</success_criteria>
|
|
@@ -22,6 +22,18 @@ Parse JSON: `executor_model`, `verifier_model`, `commit_docs`, `parallelization`
|
|
|
22
22
|
**Se `plan_count` = 0:** Erro -- sem planos encontrados na fase.
|
|
23
23
|
|
|
24
24
|
Quando `parallelization` = false, planos dentro de uma wave executam sequencialmente.
|
|
25
|
+
|
|
26
|
+
**Detectar modo de execucao:**
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
BUILDER_MODE=$(node -e "try{const c=JSON.parse(require('fs').readFileSync('.plano/config.json','utf8'));console.log(c.builder_mode===true?'true':'false')}catch{console.log('false')}" 2>/dev/null)
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
**Quando `$BUILDER_MODE = true`:**
|
|
33
|
+
- NAO mostrar menus de "Proximo" ou sugerir comandos
|
|
34
|
+
- NAO perguntar "Tentar novamente?" em spot-check (auto-retry 1x)
|
|
35
|
+
- Se `human_needed` na verificacao: considerar PASSED
|
|
36
|
+
- Retornar resultado silenciosamente para o orquestrador do builder
|
|
25
37
|
</step>
|
|
26
38
|
|
|
27
39
|
<step name="validate_phase">
|
|
@@ -120,7 +132,9 @@ Executar cada wave em sequencia. Dentro de uma wave: paralelo se `PARALLELIZATIO
|
|
|
120
132
|
- Verificar `git log --oneline --all --grep="{phase}-{plan}"` retorna >= 1 commit
|
|
121
133
|
- Verificar marcador `## Self-Check: FAILED`
|
|
122
134
|
|
|
123
|
-
Se algum spot-check falhar:
|
|
135
|
+
Se algum spot-check falhar:
|
|
136
|
+
- **Se $BUILDER_MODE:** Auto-retry 1x. Se ainda falha: registrar e continuar com waves restantes (sem perguntar).
|
|
137
|
+
- **Se modo normal:** Reportar qual plano falhou, perguntar "Tentar novamente?" ou "Continuar com waves restantes?"
|
|
124
138
|
|
|
125
139
|
Se passar:
|
|
126
140
|
```
|
|
@@ -186,7 +200,7 @@ grep "^status:" "$PHASE_DIR"/*-VERIFICATION.md | cut -d: -f2 | tr -d ' '
|
|
|
186
200
|
| Status | Acao |
|
|
187
201
|
|--------|------|
|
|
188
202
|
| `passed` | -> update_roadmap |
|
|
189
|
-
| `human_needed` | Apresentar itens para teste humano, obter aprovacao |
|
|
203
|
+
| `human_needed` | **Se $BUILDER_MODE:** Considerar PASSED, registrar para revisao final no DELIVERY.md. **Se modo normal:** Apresentar itens para teste humano, obter aprovacao. |
|
|
190
204
|
| `gaps_found` | Apresentar resumo de lacunas, oferecer `/up:planejar-fase {fase} --gaps` |
|
|
191
205
|
</step>
|
|
192
206
|
|
|
@@ -212,6 +226,18 @@ node "$HOME/.claude/up/bin/up-tools.cjs" commit "docs(fase-{X}): completar execu
|
|
|
212
226
|
|
|
213
227
|
<step name="offer_next">
|
|
214
228
|
|
|
229
|
+
**Se $BUILDER_MODE = true:**
|
|
230
|
+
NAO mostrar menus. Retornar resultado silenciosamente:
|
|
231
|
+
```markdown
|
|
232
|
+
## FASE {X} COMPLETA
|
|
233
|
+
|
|
234
|
+
**Planos:** {M}/{total} completos
|
|
235
|
+
**Verificacao:** {status}
|
|
236
|
+
```
|
|
237
|
+
O orquestrador do builder controla o proximo passo. FIM.
|
|
238
|
+
|
|
239
|
+
**Se modo normal (interativo):**
|
|
240
|
+
|
|
215
241
|
**Se verificacao passou:**
|
|
216
242
|
|
|
217
243
|
```
|