Architecture: What is the biggest remaining quality gap in generated modul...

Documentation for Sessions

🏗️ Architecture: What is the biggest remaining quality gap in generated modul...

Date: 2026-03-08
Time: 15:39:31 UTC
Session: gspace1-190.2
Agent: angular
Confidence: 97%
Status: ✅ Documented


📋 Decision Context

Question:

What is the biggest remaining quality gap in generated modules and what is the next priority?

Task: S190: Identify highest-leverage improvement for module generation quality


🎯 Decision Made

Chosen:

Generated modules ignore ALL 238+ core libraries. gspace1 has the EXACT same infrastructure as gmodules1 (useCrudList, useCrudForm, useCrudDetail composables; BaseCrudApiService; GgsCrudListShellComponent; EventBusService; ActionRegistry) — but generated code reinvents everything from scratch. Next priority: rewrite implement.prompt.md and CRUD template to generate code that uses composables + shells + events + actions. This transforms generated modules from 'looks like code' to 'production-grade framework-integrated code'.

Options Considered:

  1. Keep current template approach with incremental prompt improvements (diminishing returns)
  2. Rewrite templates to use composables + shells + events (chosen — highest leverage)
  3. Port gmodules1 generation pipeline wholesale (too invasive, different data layer)
  4. Build a template engine with field iteration support (addresses one symptom, not root cause)

💭 Reasoning

Analysis of gmodules1 (battle-tested generation with high quality output) vs gspace1 reveals: gmodules1 modules are thin (20-30 lines per component) because they use useCrudList/Form/Detail composables that handle pagination, search, filtering, sorting, URL sync, deletion, loading, errors. gspace1 generates 100+ line components with hand-rolled logic for each of these concerns — and gets most of them wrong. The composables exist at @libs-core/module-base, the shell components exist at @libs-core/ui-framework, the event system exists at @libs-core/event-system, the action registry exists at @libs-core/action-registry. The service layer should use BaseCrudApiService wrapping UniverseDataService instead of raw UniverseDataService calls. This is the single highest-leverage change possible for generation quality.


📁 Files Involved


🔗 Related


Auto-generated by MCP Smart Consolidation