workspace-v1/orchestration/analisis/PLAN-REFINADO-ESTANDARIZACION-2026-01-10.md
rckrdmrd 3a8a459d91 [SIMCO-V38] feat: Implementar sistema SIMCO v3.8.0 completo
## Directivas SIMCO v3.7.0 - Estandarizacion de Documentacion (7)
- SIMCO-DOCUMENTACION-PROYECTO.md
- SIMCO-NOMENCLATURA.md
- SIMCO-ESTRUCTURA-DOCS.md
- SIMCO-INVENTARIOS.md
- SIMCO-TESTING.md
- SIMCO-MIGRACIONES-BD.md
- SIMCO-INTEGRACIONES-EXTERNAS.md

## Directivas SIMCO v3.8.0 - Mantenimiento de Documentacion (2)
- SIMCO-MANTENIMIENTO-DOCUMENTACION.md
- SIMCO-SINCRONIZACION-BD.md

## Templates (4)
- TEMPLATE-INVENTARIO-PROYECTO.md
- TEMPLATE-INTEGRACION-EXTERNA.md
- TEMPLATE-MODULO-ESTANDAR.md
- TEMPLATE-DEPRECACION.md

## Checklists (6)
- CHECKLIST-DOCUMENTACION-PROYECTO.md
- CHECKLIST-INVENTARIOS.md
- CHECKLIST-NOMENCLATURA.md
- CHECKLIST-MANTENIMIENTO-DOCS.md
- CHECKLIST-SINCRONIZACION-BD.md
- _MAP.md

## Perfil de Agente (1)
- PERFIL-DOCUMENTATION-MAINTAINER.md

## Indices
- INDICE-DIRECTIVAS-WORKSPACE.yml actualizado a v3.8.0

## Submodulos actualizados (14)
- gamilit, erp-core, michangarrito, template-saas
- erp-suite, erp-construccion, erp-clinicas
- erp-mecanicas-diesel, erp-retail, erp-vidrio-templado
- trading-platform, betting-analytics
- inmobiliaria-analytics, platform_marketing_content

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-10 08:55:15 -06:00

551 lines
15 KiB
Markdown

# PLAN REFINADO - ESTANDARIZACION DOCUMENTACION WORKSPACE
**Fecha:** 2026-01-10
**Fase:** 5 - Refinamiento del Plan
**Estado:** LISTO PARA EJECUCION
**Version:** 2.0.0
**Referencias:**
- ANALISIS-ESTANDARES-DOCUMENTACION-WORKSPACE-2026-01-10.md
- PLAN-ESTANDARIZACION-DOCUMENTACION-WORKSPACE-2026-01-10.md
- VALIDACION-PLAN-ESTANDARIZACION-2026-01-10.md
- DEPENDENCIAS-ESTANDARIZACION-2026-01-10.md
---
## 1. AJUSTES INCORPORADOS
### 1.1 De Validacion (Fase 3)
| Ajuste | Tipo | Accion |
|--------|------|--------|
| Agregar seccion API versioning | Contenido A1 | Incluir en SIMCO-DOCUMENTACION-PROYECTO |
| Agregar seccion monitoreo basico | Contenido A5 | Incluir en SIMCO-TESTING |
| Agregar funciones/triggers | Contenido B4 | Incluir en TEMPLATE-INVENTARIO |
| Agregar B6: TEMPLATE-REPORTE-SPRINT | Nuevo archivo | Sprint 3 |
### 1.2 De Dependencias (Fase 4)
| Hallazgo | Impacto | Accion |
|----------|---------|--------|
| michangarrito sin HERENCIA-SIMCO | Alto | Crear en Sprint 5 |
| template-saas HERENCIA minimo | Medio | Expandir en Sprint 5 |
| 19 instancias a propagar | Alto | Automatizar via script |
| 7 perfiles de agentes afectados | Medio | Actualizar post-directivas |
---
## 2. ORDEN DE EJECUCION REFINADO
### Sprint 1: Directivas Fundacionales
**Orden Obligatorio:**
```
LOTE 1.1 - PARALELO (sin dependencias):
├── A1: SIMCO-DOCUMENTACION-PROYECTO.md
├── A5: SIMCO-TESTING.md
└── A7: SIMCO-INTEGRACIONES-EXTERNAS.md
LOTE 1.2 - SECUENCIAL (depende de A1):
├── A2: SIMCO-NOMENCLATURA.md (despues de A1)
└── A4: SIMCO-INVENTARIOS.md (despues de A1)
LOTE 1.3 - SECUENCIAL (depende de SIMCO-DDL):
└── A6: SIMCO-MIGRACIONES-BD.md
LOTE 1.4 - SECUENCIAL (depende de A1, A2):
└── A3: SIMCO-ESTRUCTURA-DOCS.md
```
### Sprint 2: Templates Principales
**Orden Obligatorio:**
```
LOTE 2.1 - PARALELO (depende de Sprint 1):
├── B3: TEMPLATE-MAP-INDICE.md (depende A2)
├── B4: TEMPLATE-INVENTARIO-PROYECTO.md (depende A4)
└── B5: TEMPLATE-INTEGRACION-EXTERNA.md (depende A7)
LOTE 2.2 - SECUENCIAL (depende de A3):
├── B1: TEMPLATE-EPICA-ESTANDAR.md
└── B2: TEMPLATE-MODULO-ESTANDAR.md
```
### Sprint 3: Checklists y Template Adicional
**Orden Obligatorio:**
```
LOTE 3.1 - PARALELO (depende de Sprint 1):
├── C2: CHECKLIST-INVENTARIOS.md (depende A4)
└── C3: CHECKLIST-NOMENCLATURA.md (depende A2)
LOTE 3.2 - SECUENCIAL (depende de A1, A2, A3):
└── C1: CHECKLIST-DOCUMENTACION-PROYECTO.md
LOTE 3.3 - NUEVO (identificado en validacion):
└── B6: TEMPLATE-REPORTE-SPRINT.md
```
### Sprint 4: Indices y Registros
**Orden Obligatorio:**
```
LOTE 4.1 - SECUENCIAL:
├── D1: INDICE-DIRECTIVAS-WORKSPACE.yml
├── D2: orchestration/directivas/simco/_MAP.md
├── D3: orchestration/templates/_MAP.md
└── D4: orchestration/checklists/_MAP.md (CREAR)
LOTE 4.2 - DESPUES DE D1-D4:
├── orchestration/agents/ALIASES.yml
└── orchestration/README.md
```
### Sprint 5: Propagacion a Proyectos
**Orden Obligatorio:**
```
LOTE 5.1 - PROYECTOS CRITICOS:
├── E1: gamilit/HERENCIA-SIMCO.md
└── E2: erp-core/HERENCIA-SIMCO.md
LOTE 5.2 - PROYECTOS INCOMPLETOS:
├── E3: michangarrito/HERENCIA-SIMCO.md (CREAR)
└── E4: template-saas/HERENCIA-SIMCO.md (EXPANDIR)
LOTE 5.3 - DEMAS PROYECTOS (15 restantes):
└── Actualizar via script de propagacion
```
---
## 3. CONTENIDO DETALLADO POR ARCHIVO
### 3.1 DIRECTIVA A1: SIMCO-DOCUMENTACION-PROYECTO.md
**Ruta:** `/orchestration/directivas/simco/SIMCO-DOCUMENTACION-PROYECTO.md`
**Estructura:**
```markdown
# SIMCO-DOCUMENTACION-PROYECTO
**Version:** 1.0.0
**Tipo:** Directiva Operacional
**Prioridad:** P0
**Alias:** @DOC_PROYECTO
---
## 1. Proposito y Alcance
{Definir estandar base para documentacion de proyectos}
## 2. Principios Fundamentales
- Documentar antes de implementar (@DOC-PRIMERO)
- Una sola fuente de verdad (SSOT)
- Estructura predecible
- Trazabilidad completa
## 3. Estructura Obligatoria de /docs
```
docs/
├── _MAP.md (OBLIGATORIO)
├── README.md (OBLIGATORIO)
├── 00-vision-general/ (OBLIGATORIO)
├── 01-{fase-nombre}/ (POR FASE)
├── ...
├── 90-transversal/ (OPCIONAL)
├── 95-guias-desarrollo/ (OPCIONAL)
├── 96-quick-reference/ (OPCIONAL)
├── 97-adr/ (SI HAY ADRs)
└── 99-finiquito/ (OPCIONAL)
```
## 4. Estructura Obligatoria de /orchestration
```
orchestration/
├── 00-guidelines/
│ ├── CONTEXTO-PROYECTO.md (OBLIGATORIO)
│ └── HERENCIA-SIMCO.md (OBLIGATORIO)
├── inventarios/
│ └── MASTER_INVENTORY.yml (OBLIGATORIO)
├── CONTEXT-MAP.yml (OBLIGATORIO)
├── PROJECT-STATUS.md (OBLIGATORIO)
└── README.md (OBLIGATORIO)
```
## 5. Archivos Minimos Requeridos
{Tabla con archivos obligatorios por tipo de proyecto}
## 6. API Versioning (Agregado por validacion)
{Estandar de versionado de APIs: /v1/, /v2/, etc.}
## 7. Ciclo de Vida de Documentos
- Creacion → Revision → Aprobacion → Publicacion → Actualizacion → Deprecacion
## 8. Validaciones Requeridas
- Frontmatter valido
- Referencias funcionan
- IDs unicos
- Estados consistentes
## 9. Referencias
- SIMCO-NOMENCLATURA.md
- SIMCO-ESTRUCTURA-DOCS.md
- CHECKLIST-DOCUMENTACION-PROYECTO.md
---
**Creado:** 2026-01-10
**Hereda:** PRINCIPIO-DOC-PRIMERO.md
```
### 3.2 DIRECTIVA A2: SIMCO-NOMENCLATURA.md
**Ruta:** `/orchestration/directivas/simco/SIMCO-NOMENCLATURA.md`
**Secciones Principales:**
```
1. Principios de Nomenclatura
2. Patrones por Tipo de Archivo (15 patrones)
3. Patrones de Directorios (numeracion 00-99)
4. Prefijos por Proyecto (EAI, EXT, MCH, MGN, SAAS)
5. Formato de Fechas (YYYY-MM-DD)
6. Anti-patrones a Evitar
7. Validacion con CHECKLIST-NOMENCLATURA.md
```
### 3.3 DIRECTIVA A3: SIMCO-ESTRUCTURA-DOCS.md
**Ruta:** `/orchestration/directivas/simco/SIMCO-ESTRUCTURA-DOCS.md`
**Secciones Principales:**
```
1. Frontmatter YAML Obligatorio (11 campos)
2. Estructura por Tipo de Documento
- Requerimientos (RF-*)
- Especificaciones (ET-*)
- User Stories (US-*)
- Epicas/Modulos
- ADRs
- _MAP.md (indices)
3. Secciones Obligatorias vs Opcionales
4. Formato de Tablas Markdown
5. Diagramas ASCII
6. Referencias Cruzadas
7. Footer de Documentos
```
### 3.4 DIRECTIVA A4: SIMCO-INVENTARIOS.md
**Ruta:** `/orchestration/directivas/simco/SIMCO-INVENTARIOS.md`
**Secciones Principales:**
```
1. Proposito de Inventarios (SSOT)
2. Tipos de Inventarios
- MASTER_INVENTORY.yml
- DATABASE_INVENTORY.yml (+ funciones, triggers - agregado)
- BACKEND_INVENTORY.yml
- FRONTEND_INVENTORY.yml
3. Estructura YAML por Tipo
4. Campos Obligatorios
5. Actualizacion y Mantenimiento
6. Validacion con CHECKLIST-INVENTARIOS.md
```
### 3.5 DIRECTIVA A5: SIMCO-TESTING.md
**Ruta:** `/orchestration/directivas/simco/SIMCO-TESTING.md`
**Secciones Principales:**
```
1. Principios de Testing
2. Cobertura Minima por Tipo
- Backend: 70% unit, 50% integration
- Frontend: 60% components
- Database: 100% migrations
3. Tipos de Tests Requeridos
4. Nomenclatura de Archivos de Test
5. Estructura de Carpetas de Test
6. Comandos de Ejecucion
7. Monitoreo Basico (agregado por validacion)
8. Integracion con CI/CD
```
### 3.6 DIRECTIVA A6: SIMCO-MIGRACIONES-BD.md
**Ruta:** `/orchestration/directivas/simco/SIMCO-MIGRACIONES-BD.md`
**Secciones Principales:**
```
1. Principios de Migraciones
2. Nomenclatura: {TIMESTAMP}-{descripcion}.sql
3. Estructura de Migracion
4. Rollback Obligatorio
5. Testing de Migraciones
6. Documentacion Requerida
7. Flujo de Aprobacion
8. Integracion con SIMCO-DDL.md
```
### 3.7 DIRECTIVA A7: SIMCO-INTEGRACIONES-EXTERNAS.md
**Ruta:** `/orchestration/directivas/simco/SIMCO-INTEGRACIONES-EXTERNAS.md`
**Secciones Principales:**
```
1. Cuando Usar Esta Directiva
2. Estructura de Documentacion
- Proveedor y proposito
- Credenciales requeridas
- Endpoints utilizados
- Rate limits
- Manejo de errores
- Fallbacks
3. Multi-tenant Considerations
4. Variables de Entorno
5. Testing de Integraciones
6. Template: TEMPLATE-INTEGRACION-EXTERNA.md
```
---
## 4. COMANDOS DE EJECUCION
### 4.1 Sprint 1: Directivas
```bash
# Navegar a directorio
cd /home/isem/workspace-v1/orchestration/directivas/simco
# Crear directivas (paralelo donde aplique)
# A1, A5, A7 pueden crearse en paralelo
# A2, A4 despues de A1
# A6 despues de verificar SIMCO-DDL
# A3 al final
# Verificar creacion
ls -la SIMCO-DOCUMENTACION-PROYECTO.md
ls -la SIMCO-NOMENCLATURA.md
ls -la SIMCO-ESTRUCTURA-DOCS.md
ls -la SIMCO-INVENTARIOS.md
ls -la SIMCO-TESTING.md
ls -la SIMCO-MIGRACIONES-BD.md
ls -la SIMCO-INTEGRACIONES-EXTERNAS.md
```
### 4.2 Sprint 2-3: Templates y Checklists
```bash
# Templates
cd /home/isem/workspace-v1/orchestration/templates
# Crear templates B1-B6
ls -la TEMPLATE-EPICA-ESTANDAR.md
ls -la TEMPLATE-MODULO-ESTANDAR.md
ls -la TEMPLATE-MAP-INDICE.md
ls -la TEMPLATE-INVENTARIO-PROYECTO.md
ls -la TEMPLATE-INTEGRACION-EXTERNA.md
ls -la TEMPLATE-REPORTE-SPRINT.md
# Checklists
cd /home/isem/workspace-v1/orchestration/checklists
# Crear directorio si no existe
mkdir -p /home/isem/workspace-v1/orchestration/checklists
# Crear checklists C1-C3
ls -la CHECKLIST-DOCUMENTACION-PROYECTO.md
ls -la CHECKLIST-INVENTARIOS.md
ls -la CHECKLIST-NOMENCLATURA.md
```
### 4.3 Sprint 4: Indices
```bash
cd /home/isem/workspace-v1/orchestration
# Actualizar indice principal
vim INDICE-DIRECTIVAS-WORKSPACE.yml
# Actualizar _MAP de simco
vim directivas/simco/_MAP.md
# Actualizar _MAP de templates
vim templates/_MAP.md
# Crear _MAP de checklists
vim checklists/_MAP.md
# Actualizar aliases
vim agents/ALIASES.yml
# Actualizar README
vim README.md
```
### 4.4 Sprint 5: Propagacion
```bash
# Proyectos criticos
cd /home/isem/workspace-v1/projects/gamilit/orchestration/00-guidelines
vim HERENCIA-SIMCO.md
cd /home/isem/workspace-v1/projects/erp-core/orchestration/00-guidelines
vim HERENCIA-SIMCO.md
# Proyecto sin HERENCIA
cd /home/isem/workspace-v1/projects/michangarrito/orchestration
mkdir -p 00-guidelines
vim 00-guidelines/HERENCIA-SIMCO.md
# Proyecto con HERENCIA minimo
cd /home/isem/workspace-v1/projects/template-saas/orchestration/00-guidelines
vim HERENCIA-SIMCO.md
```
---
## 5. CHECKLIST DE EJECUCION
### Sprint 1
- [ ] A1: SIMCO-DOCUMENTACION-PROYECTO.md creado
- [ ] A2: SIMCO-NOMENCLATURA.md creado
- [ ] A3: SIMCO-ESTRUCTURA-DOCS.md creado
- [ ] A4: SIMCO-INVENTARIOS.md creado
- [ ] A5: SIMCO-TESTING.md creado
- [ ] A6: SIMCO-MIGRACIONES-BD.md creado
- [ ] A7: SIMCO-INTEGRACIONES-EXTERNAS.md creado
- [ ] Todas las directivas tienen frontmatter correcto
- [ ] Referencias cruzadas funcionan
### Sprint 2
- [ ] B1: TEMPLATE-EPICA-ESTANDAR.md creado
- [ ] B2: TEMPLATE-MODULO-ESTANDAR.md creado
- [ ] B3: TEMPLATE-MAP-INDICE.md creado
- [ ] B4: TEMPLATE-INVENTARIO-PROYECTO.md creado
- [ ] B5: TEMPLATE-INTEGRACION-EXTERNA.md creado
- [ ] Todos los templates tienen estructura correcta
### Sprint 3
- [ ] C1: CHECKLIST-DOCUMENTACION-PROYECTO.md creado
- [ ] C2: CHECKLIST-INVENTARIOS.md creado
- [ ] C3: CHECKLIST-NOMENCLATURA.md creado
- [ ] B6: TEMPLATE-REPORTE-SPRINT.md creado
- [ ] Todos los checklists son ejecutables
### Sprint 4
- [ ] D1: INDICE-DIRECTIVAS-WORKSPACE.yml actualizado
- [ ] D2: directivas/simco/_MAP.md actualizado
- [ ] D3: templates/_MAP.md actualizado
- [ ] D4: checklists/_MAP.md creado
- [ ] ALIASES.yml tiene 7 nuevos aliases
- [ ] README.md actualizado
- [ ] Version incrementada
### Sprint 5
- [ ] E1: gamilit HERENCIA-SIMCO.md actualizado
- [ ] E2: erp-core HERENCIA-SIMCO.md actualizado
- [ ] E3: michangarrito HERENCIA-SIMCO.md creado
- [ ] E4: template-saas HERENCIA-SIMCO.md expandido
- [ ] Demas proyectos actualizados (15)
---
## 6. CRITERIOS DE EXITO
| Criterio | Meta | Verificacion |
|----------|------|--------------|
| Directivas creadas | 7/7 | `ls orchestration/directivas/simco/SIMCO-* | wc -l` |
| Templates creados | 6/6 | `ls orchestration/templates/TEMPLATE-* | wc -l` |
| Checklists creados | 3/3 | `ls orchestration/checklists/CHECKLIST-* | wc -l` |
| Indices actualizados | 5/5 | Verificacion manual |
| Aliases registrados | 7/7 | `grep -c "@" agents/ALIASES.yml` |
| Proyectos con HERENCIA | 19/19 | Script de validacion |
| Frontmatter valido | 100% | Validador YAML |
| Referencias funcionales | 100% | Link checker |
---
## 7. ROLLBACK SI ES NECESARIO
### Si falla en Directivas (Sprint 1)
```bash
# Revertir cambios
cd /home/isem/workspace-v1/orchestration/directivas/simco
git checkout -- SIMCO-*.md
# O eliminar solo los nuevos
rm -f SIMCO-DOCUMENTACION-PROYECTO.md
rm -f SIMCO-NOMENCLATURA.md
rm -f SIMCO-ESTRUCTURA-DOCS.md
rm -f SIMCO-INVENTARIOS.md
rm -f SIMCO-TESTING.md
rm -f SIMCO-MIGRACIONES-BD.md
rm -f SIMCO-INTEGRACIONES-EXTERNAS.md
```
### Si falla en Indices (Sprint 4)
```bash
# Revertir indice
cd /home/isem/workspace-v1/orchestration
git checkout -- INDICE-DIRECTIVAS-WORKSPACE.yml
git checkout -- agents/ALIASES.yml
```
---
## 8. ARCHIVOS FINALES A CREAR/MODIFICAR
### Crear (21 archivos)
| ID | Archivo | Ubicacion |
|----|---------|-----------|
| A1 | SIMCO-DOCUMENTACION-PROYECTO.md | directivas/simco/ |
| A2 | SIMCO-NOMENCLATURA.md | directivas/simco/ |
| A3 | SIMCO-ESTRUCTURA-DOCS.md | directivas/simco/ |
| A4 | SIMCO-INVENTARIOS.md | directivas/simco/ |
| A5 | SIMCO-TESTING.md | directivas/simco/ |
| A6 | SIMCO-MIGRACIONES-BD.md | directivas/simco/ |
| A7 | SIMCO-INTEGRACIONES-EXTERNAS.md | directivas/simco/ |
| B1 | TEMPLATE-EPICA-ESTANDAR.md | templates/ |
| B2 | TEMPLATE-MODULO-ESTANDAR.md | templates/ |
| B3 | TEMPLATE-MAP-INDICE.md | templates/ |
| B4 | TEMPLATE-INVENTARIO-PROYECTO.md | templates/ |
| B5 | TEMPLATE-INTEGRACION-EXTERNA.md | templates/ |
| B6 | TEMPLATE-REPORTE-SPRINT.md | templates/ |
| C1 | CHECKLIST-DOCUMENTACION-PROYECTO.md | checklists/ |
| C2 | CHECKLIST-INVENTARIOS.md | checklists/ |
| C3 | CHECKLIST-NOMENCLATURA.md | checklists/ |
| D4 | _MAP.md | checklists/ |
| E3 | HERENCIA-SIMCO.md | michangarrito/orchestration/00-guidelines/ |
### Modificar (10+ archivos)
| Archivo | Ubicacion | Tipo Cambio |
|---------|-----------|-------------|
| INDICE-DIRECTIVAS-WORKSPACE.yml | orchestration/ | Agregar 13 entradas |
| _MAP.md | directivas/simco/ | Agregar 7 entradas |
| _MAP.md | templates/ | Agregar 6 entradas |
| ALIASES.yml | agents/ | Agregar 7 aliases |
| README.md | orchestration/ | Actualizar overview |
| HERENCIA-SIMCO.md | templates/ | Agregar referencias |
| HERENCIA-SIMCO.md | gamilit/orchestration/ | Actualizar |
| HERENCIA-SIMCO.md | erp-core/orchestration/ | Actualizar |
| HERENCIA-SIMCO.md | template-saas/orchestration/ | Expandir |
**Total: 31+ archivos**
---
**Plan refinado y listo para ejecucion**
**Siguiente fase:** EJECUCION