upvote
Yes, I do things like this too. Planning works great, but the same is true for making write-ups after completing a task. In this case you'd ask the agent to write up a document with all the rules for your refactoring based on the current thread (where you have discovered the rules with the agent as you go). Let it include examples and let it pause and report back to you if it comes across a situation that isn't fully covered by the current rules yet so you can review it ,update the rules, and then let it continue
reply
Solid approach. Don’t be shy about writing long prompts. We call that context engineering. The more you populate that context window with applicable knowledge and what exactly you want, the better the results. Also, having the model code and you talk to the model is helpful because it has the side effect of context engineering. In other words you’re building up relevant context with that conversation history. And be acutely aware of how much context window you’ve used and how much is remaining and when a compaction will happen. Clear context as early as you can per run. Even if it’s 90% remaining.
reply