Appearance
AI-Assisted Workflows
Research-Plan-Implement (RPI) Framework
A structured approach to tackling complex development tasks through systematic research, detailed planning, and careful implementation.
Overview
The RPI framework breaks down complex work into three phases:
- Research: Thoroughly explore the codebase to understand context
- Plan: Create detailed, phased implementation plans
- Implement: Execute plans systematically with validation
Workflow Commands
/rpi:research_codebase
Deep codebase exploration using parallel AI agents to understand architecture, patterns, and existing implementations.
When to use:
- Starting work on unfamiliar parts of the codebase
- Need to understand how existing features work
- Looking for patterns to follow for new implementation
Output: Research findings saved to .ai/thoughts/shared/research/
/rpi:create_plan
Create detailed, phased implementation plans through interactive, iterative process.
When to use:
- Before implementing non-trivial features
- When multiple approaches are possible
- For changes affecting multiple files
Output: Implementation plan saved to .ai/thoughts/shared/plans/NNN_description.md
/rpi:validate_plan
Verify that implementation matches the plan specifications.
When to use:
- After completing implementation
- Before creating pull requests
- To ensure all plan phases are complete
Output: Validation report
/rpi:implement_plan
Execute an implementation plan systematically with progress tracking.
When to use:
- After plan is approved
- For step-by-step guided implementation
Output: Updates to plan file with progress checkmarks
/rpi:save_progress
Save current work session state for later resumption.
When to use:
- End of work session
- Before switching to different task
- To preserve context for team members
Output: Session summary in .ai/thoughts/shared/sessions/
/rpi:resume_work
Resume from a previously saved session.
When to use:
- Returning to saved work
- Picking up where someone else left off
Input: Session file from .ai/thoughts/shared/sessions/
/rpi:define_test_cases
Define comprehensive test cases for features or changes.
When to use:
- During planning phase
- Before implementation
- To ensure test coverage
Output: Test case definitions
/rpi:refresh_knowledge
Refresh understanding of codebase before starting work.
When to use:
- After long break from codebase
- Before starting new feature work
- When codebase has changed significantly
Output: Updated codebase knowledge summary
/rpi:qa
Post-implementation quality assurance review.
When to use:
- After implementing a feature or fix
- Before creating a pull request
- When changes touch shared libraries used by multiple apps
Output: QA report (console output)
Output Locations
- Research findings:
.ai/thoughts/shared/research/ - Implementation plans:
.ai/thoughts/shared/plans/ - Session summaries:
.ai/thoughts/shared/sessions/ - Cloud analyses:
.ai/thoughts/shared/cloud/
Best Practices
- Always research before planning for non-trivial features
- Get plan approval before implementation
- Save progress at end of each session
- Validate implementation against plan before PR
- Document deviations from plan in implementation