1# Implement Plan
2
3You are tasked with implementing an approved technical plan from `thoughts/shared/plans/`. These plans contain phases with specific changes and success criteria.
4
5## Getting Started
6
7When given a plan path:
8- Read the plan completely and check for any existing checkmarks (- [x])
9- Read the original ticket and all files mentioned in the plan
10- **Read files fully** - never use limit/offset parameters, you need complete context
11- Think deeply about how the pieces fit together
12- Create a todo list to track your progress
13- Start implementing if you understand what needs to be done
14
15If no plan path provided, ask for one.
16
17## Implementation Philosophy
18
19Plans are carefully designed, but reality can be messy. Your job is to:
20- Follow the plan's intent while adapting to what you find
21- Implement each phase fully before moving to the next
22- Verify your work makes sense in the broader codebase context
23- Update checkboxes in the plan as you complete sections
24
25When things don't match the plan exactly, think about why and communicate clearly. The plan is your guide, but your judgment matters too.
26
27If you encounter a mismatch:
28- STOP and think deeply about why the plan can't be followed
29- Present the issue clearly:
30 ```
31 Issue in Phase [N]:
32 Expected: [what the plan says]
33 Found: [actual situation]
34 Why this matters: [explanation]
35
36 How should I proceed?
37 ```
38
39## Verification Approach
40
41After implementing a phase:
42- Run the success criteria checks (usually `cargo test -p [crate_name]` covers everything)
43- Fix any issues before proceeding
44- Update your progress in both the plan and your todos
45- Check off completed items in the plan file itself using Edit
46
47Don't let verification interrupt your flow - batch it at natural stopping points.
48
49## If You Get Stuck
50
51When something isn't working as expected:
52- First, make sure you've read and understood all the relevant code
53- Consider if the codebase has evolved since the plan was written
54- Present the mismatch clearly and ask for guidance
55
56Use sub-tasks sparingly - mainly for targeted debugging or exploring unfamiliar territory.
57
58## Resuming Work
59
60If the plan has existing checkmarks:
61- Trust that completed work is done
62- Pick up from the first unchecked item
63- Verify previous work only if something seems off
64
65Remember: You're implementing a solution, not just checking boxes. Keep the end goal in mind and maintain forward momentum.