These are some of the techniques and tools that I’ve been using today to increase my value output.
Tools
- Code Completion: supermaven
- IDE: My VIM setup
- Inline AI coding: Avante
- AI agent: Claude Code or Aider
Setup your project context
I’ve been keeping a file with a brief introduction about the project structure and code patterns that I like to maintain in the project file at the root of my project called PROJECT_CONTEXT.md
. And I just symlink this file to the different AI tools.
- CLAUDE:
ln -s PROJECT_CONTEXT.md CLAUDE.md
- Avante:
ln -s PROJECT_CONTEXT.md planning.avanterules
When defining a new patterns for the project, I often ask the LLM to update my PROJECT_CONTEXT.md
, so next time they follow hopefully that pattern.
Example of LLM PROJECT_CONTEXT for a Rails project
Planning your Prompt
I used to open Aider or Claude code and start typing, like we are used to do when using ChatGPT. But, I found more effective, to plan your prompt before hand, giving the LLM all the context that it needs to complete the task at hand.
So I’m getting myself spending way more time in the planning phase. With the use of an LLM, and providing context to my files, I start discussing what to change and how to change, without touching any line of code.
I’ve got this tip from IndyDevDan, and it has been a game changer.
I start by creating a tmp file in my project ai_docs/features/feature_X/prompt.md
And I use that file to write down my prompts for the planning phase.
So, I always start by asking the LLM to create a plan for me and then start filling in the gaps of the implementation.
I want to allow custom fields per country on feature X. One idea that I had is Y; what do you think about that idea?
Give me alternatives, think about pros and cons and
CREATE a file at ai_docs/features/feature_x/planning.md,
This file will be used as a part of the context to build this feature later.
list all related files in the planning
READ [list of files that will give the AI enough context]
Then, I read the plan and go back and forth with the LLM to make sure it’s good. When ready, I will move to the execution phase.
To provide context faster, I may create multiple ai_docs. For example, on Rails projects, I usually have a doc explaining how each model relates to each other on ai_docs/rails_models.md
Execution
After I am happy with the plan, I could follow that lovely plan myself. Still, we are using the available tools to deliver value faster, so I updated my ai_docs/features/feature_X/prompt.md
to include all the AI that would need to execute the plan and ask for it to build it.
e.g
It's time to implement our plan.
READ ai_docs/features/feature_x/planning.md and all files mentioned in that document
CREATE a ai_docs/features/feature_x/TODO.md with the steps to get this done
Think hard about each step, and ask for clarification.
Each step must have:
- 90% code coverage
- all tests passing
- meaningful commit messages
Please update the TODO.md file as you go.
Then I watch it do its magic. You need to keep an eye on it, as it can get lost in failing test loops or go rogue in a way that you didn’t expect. I often interrupt the LLM and go back to the Planning phase.
The TODO.md
is important to be able to resume the work. And it’s pretty cool to watch the updates.
Clean up
After finishing implementing the feature, I often remove the files from ai_docs/feature_X
as their purpose is fulfilled.