docs: add team kickoff prompt for Fase 1 development

This commit is contained in:
Luca Sacchi Ricciardi
2026-04-07 13:11:49 +02:00
parent cd6f8ad166
commit 18ce380a6d

View File

@@ -0,0 +1,347 @@
# 🚀 TEAM KICKOFF - mockupAWS Fase 1
## 📢 Comunicazione Ufficiale
**Data:** 2026-04-07
**Fase:** 1 - Database & Backend Core
**Status:** ✅ Architettura Completa - Pronti per Sviluppo
---
## ✅ Cosa è stato completato
L'agente **@spec-architect** ha completato l'analisi e le specifiche tecniche:
### Documentazione Pronta
-**PRD v0.2.0** - Requisiti completi
-**architecture.md** - Architettura dettagliata con:
- Schema database completo (DDL SQL pronto)
- API specifications (OpenAPI)
- Diagrammi flusso dati
- Piano sicurezza
-**kanban.md** - 32 task breakdown, stimate, priorizzate
-**progress.md** - Tracking inizializzato
### Team Configurato
- ✅ 6 agenti specializzati configurati in `.opencode/agents/`
- ✅ Ogni agente ha ruoli, responsabilità e constraints definiti
---
## 🎯 OBIETTIVO FASE 1
**Deadline:** End of Week 1
**Goal:** Database PostgreSQL funzionante + API CRUD base
**Deliverables:**
1. Database schema completo (5 tabelle)
2. Alembic migrations funzionanti
3. SQLAlchemy models + Pydantic schemas
4. Repository layer
5. Scenario CRUD API
6. Test coverage > 60%
---
## 👥 ASSEGNAZIONI TASK
### @db-engineer - DATABASE (Priorità P1)
**Task immediate:**
1. **DB-001** - Alembic Setup (Stima: S)
- Installare alembic e asyncpg
- Configurare per SQLAlchemy 2.0 async
- Testare connessione
2. **DB-002** - Migration Scenarios Table (Stima: M)
- Creare tabella scenarios con tutti i campi
- Aggiungere indexes e constraints
- Testare migrazione
3. **DB-003** - Migration Logs Table (Stima: M)
- Creare tabella scenario_logs
- Foreign key a scenarios
4. **DB-004** - Migration Metrics Table (Stima: M)
- Creare tabella scenario_metrics
5. **DB-005** - Migration Pricing Table (Stima: M)
- Creare tabella aws_pricing
6. **DB-006** - Migration Reports Table (Stima: S)
- Creare tabella reports
7. **DB-007** - Seed AWS Pricing Data (Stima: M)
- Popolare con prezzi reali AWS
- SQS, Lambda, Bedrock per us-east-1
**📖 Riferimenti:**
- Schema SQL: `export/architecture.md` sezione 3.2
- Prezzi: `export/prd.md` sezione 4.3 (tabella prezzi)
- Config agente: `.opencode/agents/db-engineer.md`
**⚠️ IMPORTANTE:**
- Usare UUID come primary keys
- Includere created_at/updated_at su tutte le tabelle
- Creare indexes su colonne di query frequenti
- Testare ogni migrazione con `alembic upgrade +1`
---
### @backend-dev - BACKEND CORE (Priorità P1)
**Task immediate:**
1. **BE-001** - Database Connection (Stima: M)
- Creare `backend/src/core/database.py`
- Configurare async SQLAlchemy engine
- Creare dependency `get_db()` per FastAPI
2. **BE-002** - SQLAlchemy Models (Stima: L)
- Creare tutti i modelli in `backend/src/models/`
- Base model, Scenario, ScenarioLog, ScenarioMetric, AwsPricing, Report
- Definire relationships
3. **BE-003** - Pydantic Schemas (Stima: M)
- Creare schemas in `backend/src/schemas/`
- ScenarioCreate, ScenarioUpdate, ScenarioResponse, etc.
4. **BE-004** - Base Repository (Stima: M)
- Creare `backend/src/repositories/base.py`
- Implementare Generic Repository pattern
- Metodi: get(), list(), create(), update(), delete()
5. **BE-005** - Scenario Repository (Stima: M)
- Creare `backend/src/repositories/scenario_repo.py`
- Metodi specifici per scenario
6. **BE-015** - API Dependencies (Stima: M)
- Creare `backend/src/api/deps.py`
- Configurare exception handlers
- Definire custom exceptions
7. **BE-016** - Scenarios API (Stima: L)
- Implementare CRUD endpoints
- POST/GET/PUT/DELETE /api/v1/scenarios
- Lifecycle endpoints (start, stop, archive)
**📖 Riferimenti:**
- Architettura: `export/architecture.md` sezioni 4, 5, 7, 8
- API Specs: `export/architecture.md` sezione 4
- Codice esistente: `src/main.py`, `src/profiler.py`
- Config agente: `.opencode/agents/backend-dev.md`
**⚠️ IMPORTANTE:**
- Usare type hints ovunque
- TDD: scrivere test prima o insieme al codice
- Async/await per tutte le operazioni I/O
- Repository pattern obbligatorio
---
### @frontend-dev - PREPARAZIONE (Priorità P2)
**Task preparazione:**
1. Setup ambiente React:
```bash
mkdir -p /home/google/Sources/LucaSacchiNet/mockupAWS/frontend
cd /home/google/Sources/LucaSacchiNet/mockupAWS/frontend
npm create vite@latest . -- --template react-ts
npm install
npm install tailwindcss postcss autoprefixer
npx tailwindcss init -p
npm install @tanstack/react-query axios recharts lucide-react clsx tailwind-merge
npm install -D @types/node
```
2. Installare shadcn/ui:
```bash
npx shadcn-ui@latest init
```
3. Preparare mock data per sviluppo UI
**📖 Riferimenti:**
- Stack: `export/architecture.md` sezione 7.2
- Config agente: `.opencode/agents/frontend-dev.md`
**⚠️ NOTA:** Il frontend verrà sviluppato in Fase 2. Per ora preparare solo l'ambiente.
---
### @devops-engineer - DOCKER BASE (Priorità P2)
**Task preparazione:**
1. Creare `docker-compose.yml` base:
- Servizio PostgreSQL
- Volume per persistenza
- Health check
2. Preparare `backend/Dockerfile`:
- Multi-stage build
- Python 3.11-slim
- Uvicorn entrypoint
3. Preparare `frontend/Dockerfile`:
- Node 20-alpine
- Nginx per serving
**📖 Riferimenti:**
- Config agente: `.opencode/agents/devops-engineer.md`
---
### @qa-engineer - TEST PLAN (Priorità P2)
**Task preparazione:**
1. Creare `docs/test_plan.md` con:
- Unit test strategy
- Integration test plan
- E2E test scenarios
2. Preparare fixtures per pytest:
- Database fixture con rollback
- Mock data fixtures
**📖 Riferimenti:**
- Config agente: `.opencode/agents/qa-engineer.md`
---
## 🔄 WORKFLOW GIORNALIERO
### Daily Routine
1. **Mattina:** Leggere `export/progress.md` per stato attuale
2. **Durante il giorno:** Aggiornare progresso su task assegnate
3. **Fine giornata:** Aggiornare `export/progress.md` con:
- Task completate
- Blocchi riscontrati
- Decisioni prese
### Comunicazione
- **Domande tecniche:** Riferirsi a `export/architecture.md`
- **Task details:** Riferirsi a `export/kanban.md`
- **Blocchi:** Aggiungere a `export/kanban.md` sezione BLOCKED
- **Decisioni:** Documentare in `export/progress.md`
### Git Workflow
- **Branch:** `feature/DB-001-alembic-setup`
- **Commits:** Conventional commits
- `feat: add alembic configuration`
- `feat: create scenarios table migration`
- `test: add scenario repository tests`
- **PR:** Una feature = una PR
---
## 📊 CRITERI DI SUCCESSO FASE 1
La Fase 1 è completata quando TUTTI questi criteri sono soddisfatti:
### Database ✅
- [ ] Alembic configurato e funzionante
- [ ] 5 tabelle create con migrazioni
- [ ] Indexes creati
- [ ] Seed dati pricing popolati
- [ ] `alembic upgrade head` esegue senza errori
### Backend ✅
- [ ] SQLAlchemy models completi
- [ ] Pydantic schemas validati
- [ ] Repository layer funzionante
- [ ] API CRUD scenari testate
- [ ] Gestione stati (draft→running→completed) funzionante
### Testing ✅
- [ ] Unit tests per repositories
- [ ] Integration tests per API
- [ ] Test coverage > 60%
- [ ] Tutti i test passanti
### Documentazione ✅
- [ ] API documentate (OpenAPI visibile su /docs)
- [ ] README aggiornato con istruzioni setup
---
## 🚨 COMANDI UTILI
### Database
```bash
# Setup database locale
docker run -d --name mockupaws-postgres \
-e POSTGRES_DB=mockupaws \
-e POSTGRES_USER=app \
-e POSTGRES_PASSWORD=changeme \
-p 5432:5432 postgres:15-alpine
# Alembic commands
cd /home/google/Sources/LucaSacchiNet/mockupAWS/backend
uv run alembic revision --autogenerate -m "create scenarios table"
uv run alembic upgrade head
uv run alembic downgrade -1
```
### Backend
```bash
# Setup
cd /home/google/Sources/LucaSacchiNet/mockupAWS
uv add sqlalchemy alembic asyncpg pydantic-settings
# Test
uv run pytest -v
uv run pytest --cov=src --cov-report=html
# Run
uv run uvicorn src.main:app --reload
```
### Frontend
```bash
cd /home/google/Sources/LucaSacchiNet/mockupAWS/frontend
npm install
npm run dev
```
---
## 📞 SUPPORTO
### Domande?
1. Leggere prima `export/architecture.md`
2. Controllare `export/kanban.md` per dettagli task
3. Riferirsi al proprio file config in `.opencode/agents/`
### Blocchi?
- Aggiungere task a sezione BLOCKED in `kanban.md`
- Documentare in `progress.md`
- Chiedere supporto al team
---
## 🎬 AZIONE IMMEDIATA
**@db-engineer:** Inizia con **DB-001** - Alembic Setup
**@backend-dev:** Prepara ambiente, inizia con **BE-001** quando DB-001 è pronto
**@frontend-dev:** Setup ambiente React
**@devops-engineer:** Crea docker-compose.yml base
**@qa-engineer:** Crea test plan iniziale
**@spec-architect:** Monitoraggio progresso, supporto architetturale
---
**🚀 TEAM: SIATE PRONTI, SI PARTE!**
Iniziate con le task assegnate. Aggiornate `export/progress.md` frequentemente.
**Commit often, test always, communicate always!**
---
*Prompt creato da @spec-architect*
*Data: 2026-04-07*
*Versione: 1.0*