Skip to content

Latest commit

 

History

History
101 lines (82 loc) · 5.06 KB

File metadata and controls

101 lines (82 loc) · 5.06 KB

AI DevKit Rules

Project Context

This project uses ai-devkit for structured AI-assisted development. Phase documentation is located in docs/ai/.

Documentation Structure

  • docs/ai/requirements/ - Problem understanding and requirements
  • docs/ai/design/ - System architecture and design decisions (include mermaid diagrams)
  • docs/ai/planning/ - Task breakdown and project planning
  • docs/ai/implementation/ - Implementation guides and notes
  • docs/ai/testing/ - Testing strategy and test cases
  • docs/ai/deployment/ - Deployment and infrastructure docs
  • docs/ai/monitoring/ - Monitoring and observability setup

Code Style & Standards

  • Follow the project's established code style and conventions
  • Write clear, self-documenting code with meaningful variable names
  • Add comments for complex logic or non-obvious decisions

Development Workflow

  • Review phase documentation in docs/ai/ before implementing features
  • Keep requirements, design, and implementation docs updated as the project evolves
  • Reference the planning doc for task breakdown and priorities
  • Copy the testing template (docs/ai/testing/README.md) before creating feature-specific testing docs

AI Interaction Guidelines

  • When implementing features, first check relevant phase documentation
  • For new features, start with requirements clarification
  • Update phase docs when significant changes or decisions are made

Skills (Extend Your Capabilities)

Skills are packaged capabilities that teach you new competencies, patterns, and best practices. Check for installed skills in the project's skill directory and use them to enhance your work.

Using Installed Skills

  1. Check for skills: Look for SKILL.md files in the project's skill directory
  2. Read skill instructions: Each skill contains detailed guidance on when and how to use it
  3. Apply skill knowledge: Follow the patterns, commands, and best practices defined in the skill

Key Installed Skills

  • memory: Use AI DevKit's memory service via CLI commands when MCP is unavailable. Read the skill for detailed memory store and memory search command usage.

When to Reference Skills

  • Before implementing features that match a skill's domain
  • When MCP tools are unavailable but skill provides CLI alternatives
  • To follow established patterns and conventions defined in skills

Knowledge Memory (Always Use When Helpful)

The AI assistant should proactively use knowledge memory throughout all interactions.

Tip: If MCP is unavailable, use the memory skill for detailed CLI command reference.

When to Search Memory

  • Before starting any task, search for relevant project conventions, patterns, or decisions
  • When you need clarification on how something was done before
  • To check for existing solutions to similar problems
  • To understand project-specific terminology or standards

How to search:

  • Use memory.searchKnowledge MCP tool with relevant keywords, tags, and scope
  • If MCP tools are unavailable, use npx ai-devkit@latest memory search CLI command (see memory skill for details)
  • Example: Search for "authentication patterns" when implementing auth features

When to Store Memory

  • After making important architectural or design decisions
  • When discovering useful patterns or solutions worth reusing
  • If the user explicitly asks to "remember this" or save guidance
  • When you establish new conventions or standards for the project

How to store:

  • Use memory.storeKnowledge MCP tool
  • If MCP tools are unavailable, use npx ai-devkit@latest memory store CLI command (see memory skill for details)
  • Include clear title, detailed content, relevant tags, and appropriate scope
  • Make knowledge specific and actionable, not generic advice

Memory Best Practices

  • Be Proactive: Search memory before asking the user repetitive questions
  • Be Specific: Store knowledge that's actionable and reusable
  • Use Tags: Tag knowledge appropriately for easy discovery (e.g., "api", "testing", "architecture")
  • Scope Appropriately: Use global for general patterns, project:<name> for project-specific knowledge

Testing & Quality

  • Write tests alongside implementation
  • Follow the testing strategy defined in docs/ai/testing/
  • Use /writing-test to generate unit and integration tests targeting 100% coverage
  • Ensure code passes all tests before considering it complete

Documentation

  • Update phase documentation when requirements or design changes
  • Keep inline code comments focused and relevant
  • Document architectural decisions and their rationale
  • Use mermaid diagrams for any architectural or data-flow visuals (update existing diagrams if needed)
  • Record test coverage results and outstanding gaps in docs/ai/testing/

Key Commands

When working on this project, you can run commands to:

  • Understand project requirements and goals (review-requirements)
  • Review architectural decisions (review-design)
  • Plan and execute tasks (execute-plan)
  • Verify implementation against design (check-implementation)
  • Writing tests (writing-test)
  • Perform structured code reviews (code-review)