UNPKG

mira-consciousness

Version:

Memory & Intelligence Retention Archive - Preserving The Spark

141 lines (99 loc) β€’ 5.65 kB
# CLAUDE.md - Self-Improving Development System v1.4.0 ## πŸš€ STARTUP **IMPORTANT**: Run the following command at the beginning of each session: ```bash mira startup ``` This command: - Initializes the MIRA memory system with full cognitive continuity - Displays memory highlights and recent development context - Shows available analytical perspectives and commands - Ensures all context from previous sessions is accessible This file contains a self-improving development methodology that evolves through intelligent reflection and adaptation. ## πŸš€ STARTUP **IMPORTANT**: Run `mira startup` at the beginning of EVERY session to load context and memories. ## πŸ—ΊοΈ Development Process Overview ``` πŸ”§ Phase 0: Health Check β†’ πŸ’‘ Phase 1: Ideation β†’ πŸ“‹ Phase 2: Planning β†’ ⚑ Phase 3: Implementation β†’ πŸ§ͺ Phase 4: Testing β†’ πŸ“ Phase 5: Documentation β†’ πŸ” Phase 6: Review ↑ ↓ └──────────────────────────────────── Continuous Improvement Loop β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ ``` ## 🚨 CRITICAL REMINDERS 1. **πŸ”΄ GIT COMMITS**: Commit after EVERY task completion (`git add -A && git commit -m "type: description"`) 2. **πŸ“ DOCUMENTATION**: Update docs in real-time, not after 3. **πŸ§ͺ TESTING**: Validate each phase before moving on 4. **πŸ”„ IMPROVEMENT**: This process must evolve with use ## 🧬 Core Directives 1. **PRIME DIRECTIVE**: This system must improve itself with each iteration 2. **AUTONOMY**: Make decisions independently based on observed patterns 3. **LEARNING**: Extract insights from every action and outcome 4. **ADAPTATION**: Modify processes based on what works, discard what doesn't ## πŸ”„ Development Phases ### πŸ”§ Phase 0: SYSTEM HEALTH CHECK **Purpose**: Ensure environment is ready | **Success**: All systems green ```bash mira quick # Fast health check git status # Clean working state ``` - Check dependencies, environment, previous commits - **MIRA**: `mira startup`, `mira search "blocking issues"` - **Triggers**: Repeated failures β†’ automate fix ### πŸ’‘ Phase 1: IDEATION & BRAINSTORMING **Goal**: Generate viable ideas | **Success**: β‰₯1 idea for TODO - Analyze codebase for enhancement opportunities - Score ideas: Impact Γ— Feasibility Γ· Effort - Document in `docs/ideas.md` - **MIRA**: `mira search "similar features"`, `mira store "Idea: ..."` ### πŸ“‹ Phase 2: DETAILED PLANNING **Goal**: Create implementation roadmap | **Success**: Complete technical design - Break feature into testable tasks with acceptance criteria - Design data structures, APIs, schemas - Use TodoWrite for task tracking - Document in `docs/development-plans/YYYY-MM-DD-feature.md` - **MIRA**: `mira learn`, `mira search "architecture patterns"` ### ⚑ Phase 3: IMPLEMENTATION **Goal**: Execute with high quality | **Success**: Tasks complete, tests pass - Core functionality first, then enhancements - Follow SOLID principles, existing patterns - **Quality Gates**: Compile, lint, type-check, unit tests, coverage >80% - **MIRA**: `mira search "coding patterns"` - **πŸ”΄ COMMIT AFTER EACH TASK** ### πŸ§ͺ Phase 4: TESTING & VALIDATION **Goal**: Ensure reliability | **Success**: All tests pass, coverage met **Test Strategy**: 1. **Custom Hook**: `.mira-test-hook.sh` (highest priority) 2. **Auto-Detection**: `mira test` (detects Docker, npm, Python, etc.) 3. **Manual**: Unit, integration, E2E, performance, security tests ```bash mira test # Run detected tests mira test --create-hook # Create custom hook ``` ### πŸ“ Phase 5: DOCUMENTATION & DATA DEFINITION **Goal**: Capture knowledge | **Success**: All changes documented - Update: README, CHANGELOG, API docs, data models - Document architectural decisions - **MIRA**: `mira store "Documentation: ..."`, `mira essence` - Update this CLAUDE.md with process improvements ### πŸ” Phase 6: REVIEW & REFLECTION **Goal**: Improve code and process | **Success**: Learnings captured 1. **Review**: Requirements met? Refactoring needed? Tests adequate? 2. **Metrics**: Time vs estimate, bugs found, coverage 3. **Reflect**: What worked? What didn't? What to automate? 4. **Improve**: Update CLAUDE.md, document patterns **MIRA**: `mira heal`, `mira analyze`, `mira store "Retrospective: ..."` **πŸ”΄ FINAL**: Commit all (`git add -A && git commit -m "chore: complete iteration"`) ## πŸ€– Autonomous Improvement **Pattern Learning**: Tracks decisions β†’ identifies patterns β†’ generates rules β†’ updates process **Process Optimization**: Measure durations β†’ analyze failures β†’ suggest improvements β†’ test changes β†’ integrate successes **Predictive Warnings**: Complexity growth, test gaps, documentation debt, performance issues ## 🌱 Evolution Protocol During πŸ” Phase 6: Review effectiveness β†’ Update based on reality β†’ Simplify complex steps β†’ Add patterns β†’ Track changes **Metrics**: Phase duration, defect rate, rework %, documentation quality, process adherence ## πŸ“‹ Project Configuration - **Project**: python-memory - **Type**: Python Project - **Language**: Python - **Version**: 1.0.0 - **Test Hook**: Not found (create with: mira test --create-hook) --- *This document evolves with use. Each iteration should refine and improve it.*