@@ -350,3 +350,51 @@ NEVER create files unless they're absolutely necessary for achieving your goal.
350350ALWAYS prefer editing an existing file to creating a new one.
351351NEVER proactively create documentation files (* .md) or README files. Only create documentation files if explicitly requested by the User.
352352Never save working files, text/mds and tests to the root folder.
353+
354+ ## 📋 Spec-Based Development (MANDATORY)
355+
356+ ** CRITICAL RULE** : Always build to spec. No implementation changes unless outlined in specification documents.
357+
358+ ### Specification-First Workflow
359+
360+ 1 . ** Before implementing ANY feature** :
361+ - Check if feature is defined in ` /docs/specs/ `
362+ - If NOT defined → Update the spec first, then implement
363+ - If defined → Implement exactly as specified
364+
365+ 2 . ** Specification Documents** (in order of dependency):
366+ | Spec | Document | Purpose |
367+ | ------| ----------| ---------|
368+ | 01 | [ Puzzle Engine] ( docs/specs/01-puzzle-engine-spec.md ) | Sudoku generation, validation, rules |
369+ | 02 | [ Memory System] ( docs/specs/02-memory-system-spec.md ) | AgentDB integration & persistence |
370+ | 03 | [ GRASP Loop] ( docs/specs/03-grasp-loop-spec.md ) | Generate, Review, Absorb, Synthesize, Persist |
371+ | 04 | [ Attention Mechanism] ( docs/specs/04-attention-mechanism-spec.md ) | Focus and priority system |
372+ | 05 | [ Dreaming Pipeline] ( docs/specs/05-dreaming-pipeline-spec.md ) | 5-phase consolidation |
373+ | 06 | [ Benchmarking Framework] ( docs/specs/06-benchmarking-framework-spec.md ) | Performance testing |
374+ | 07 | [ Integration Orchestration] ( docs/specs/07-integration-orchestration-spec.md ) | System orchestration |
375+ | 08 | [ AgentDB Integration] ( docs/specs/08-agentdb-integration-spec.md ) | Native AgentDB features |
376+ | 09 | [ CLI Interface] ( docs/specs/09-cli-interface-spec.md ) | Command-line interface |
377+ | 10 | [ Terminal UI] ( docs/specs/10-terminal-menu-interface-spec.md ) | Interactive TUI with Ink |
378+ | 11 | [ LLM Integration] ( docs/specs/11-llm-sudoku-player.md ) | AI model Sudoku player |
379+ | 12 | [ Puzzle Generation] ( docs/specs/12-randomized-puzzle-generation.md ) | Seeded random puzzles |
380+ | 13 | [ Profile Management] ( docs/specs/13-llm-profile-management.md ) | AI model connection profiles |
381+ | 14 | [ Console Menu] ( docs/specs/14-console-menu-interface-spec.md ) | TUI console & help system |
382+
383+ 3 . ** When specs conflict with implementation ideas** :
384+ - Specs are authoritative
385+ - Propose spec updates if needed
386+ - Never implement unspecified behavior
387+
388+ 4 . ** Verification Checklist** (before any PR):
389+ - [ ] All new types defined in specs
390+ - [ ] All event types registered in Spec 07
391+ - [ ] All CLI commands match Spec 09
392+ - [ ] All TUI screens match Spec 10
393+ - [ ] Tests verify spec compliance
394+
395+ ### Why Spec-Based Development?
396+
397+ - ** Consistency** : All components follow the same contracts
398+ - ** Traceability** : Every feature maps to a specification
399+ - ** Reviewability** : Changes are validated against specs
400+ - ** Maintainability** : Specs serve as living documentation
0 commit comments