aider icon indicating copy to clipboard operation
aider copied to clipboard

Feature Request: Implement /brainstorm to discuss code before it edits files

Open SerialIterator opened this issue 1 year ago • 1 comments

Request

Sometimes I try telling it "Discuss with me and do not code anything..." So I can see what solution it comes up with. I may not fully like it's solution and use the next request to make corrections or go a different route. I would love to have a feature that lets you brainstorm with the LLM before implement the changes and committing the code.

Maybe it could be as simple as /brainstorm followed by the request which would enable the LLM to work on files it stores temporarily so they are in memory. This may use more tokens but saves time trying to revert to previous commits searching for one that wasn't broken in a chain of LLM auto coding.

Version and model info

No response

SerialIterator avatar Jul 09 '24 20:07 SerialIterator

i have used aider a lot, for pet ideas, pet projects, semi-serious (but hobby stuff). it is a big limitation that it wants to jump to coding immediately, and apologizes when ones ask first to think or go thru brainstorm, etc. I agree that whatever the solution may be, we need to be able to enter 'modes'. testing/debugging is another problematic thing, because it jumps to coding solutions, and the context history gets filled with a lot of stale content from prior tests that failed.

fferreres avatar Jul 11 '24 01:07 fferreres

Thanks for trying aider and filing this issue.

This looks like a duplicate of #795, so I'm going to close it so discussion can happen there. Please let me know if you think it's actually a distinct issue.

paul-gauthier avatar Jul 12 '24 08:07 paul-gauthier

@paul-gauthier I believe this would be a distinct feature from the original issue raised in #795.

From the description of Aider: "Aider lets you pair program with LLMs, to edit code in your local git repository" This feature would focus on "pair programming" where Aider can feel like a contractor that jumps the gun and runs away with the code for a while. I feel like Aider is meant to be a coworker that helps you plan and implement YOUR ideas but needs to keep the original intention of the code in mind to do that.

When I use "don't code just discuss" before a prompt, I can iterate over a plan of action to tackle a new feature that may take multiple steps. I work with the LLM and it seems to understand "our" plan. I tell it to proceed with step 1 and it understands the purpose of implementing that code.

eg.

  1. Make function A
  2. Make function B to use A
  3. Make function C

I use the next request to fix a bug or tweak its result. When I tell it Let's work on step 2 now it replies I don't have memory of what was discussed but I can <insert completely wrong direction of code here>.

I think it should be possible to create a temporary "Concept Outline" file that Aider keeps in memory to tackle a multistep process.

For example it could keep

  1. The list of steps needed to code the feature
  2. A summary of it's understanding for the outcome with references to the conversations that made the outcome clear
  3. A dictionary of what it proposed for each step with independent summaries of how it would tackle that step. (files needed to edit and/or files needed to add)

Almost like it keeps a kanban board in memory and knows when tasks have been completed to reach the agreed upon goal.

SerialIterator avatar Jul 12 '24 19:07 SerialIterator