paul-gauthier / aider

aider is AI pair programming in your terminal
https://aider.chat/
Apache License 2.0
12.62k stars 1.21k forks source link

Feature request: vscode extension #68

Open shootdaj opened 12 months ago

shootdaj commented 12 months ago

Would be amazing to have this as an extension to vscode (and Visual Studio if possible) similar to Github Copilot chat. Would really make using this very seamless. Either way, this is an amazingly helpful tool. Thank you

paul-gauthier commented 11 months ago

Thanks for trying aider and making this suggestion.

I've certainly thought about making a VS Code plugin. I guess I'm curious what would be the key benefits you would like to see in such an extension?

My normal workflow is to have my editor open and then beside it have a terminal open where I'm chatting with aider. As aider edits the files, my editor notices the changes and reloads automatically.

I guess I'm wondering if you have specific ideas for how a VS Code extension could provide an improved workflow?

joshuavial commented 11 months ago

The things I'm finding useful in the neovim plugin are

Things i'm thinking about adding are

I did some experiments with vs code and found running aider in its built in terminal was quite stuttery when in streaming mode, and a bit of a black box when it was off. Having a hybrid mode with some kind of progress indicator but not the whole output might be useful

paul-gauthier commented 11 months ago

I did some experiments with vs code and found running aider in its built in terminal was quite stuttery when in streaming mode, and a bit of a black box when it was off. Having a hybrid mode with some kind of progress indicator but not the whole output might be useful

I wonder if --no-pretty would work better? It streams, but doesn't involve python rich for colors, etc.

joshuavial commented 11 months ago

yep, no pretty sorted out the flickering issue.

On Fri, 14 Jul 2023 at 10:25, paul-gauthier @.***> wrote:

I did some experiments with vs code and found running aider in its built in terminal was quite stuttery when in streaming mode, and a bit of a black box when it was off. Having a hybrid mode with some kind of progress indicator but not the whole output might be useful

I wonder if --no-pretty would work better? It streams, but doesn't involve python rich for colors, etc.

— Reply to this email directly, view it on GitHub https://github.com/paul-gauthier/aider/issues/68#issuecomment-1634994266, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAARU5OFFUGDRUETIBXMXJLXQBYVFANCNFSM6AAAAAA2BWYNX4 . You are receiving this because you commented.Message ID: @.***>

--

http://enspiral.com/ Joshua Vial Website http://codewithjv.com Twitter @joshuavial http://twitter.com/joshuavial Phone +64 21 684 495 Book a meeting https://calendly.com/joshua-vial

paul-gauthier commented 11 months ago

FYI, aider now detects if it is running inside vscode and disables pretty.

ncd76 commented 10 months ago

+1 for the UI.

Not sure why it needs to be inside VSC - easier to develop I suppose as plugin rather than a full stand alone deployment which would be better as not everyone uses VSC and they are not dependant on each other

Also a full installer. At some point a great tool like this (imo) should have one for wider adoption.

What would a UI do? Everything the CLI can do but with buttons, toggles and text boxes.

I'd be more than happy to help in this regard if appropriate?

younes-io commented 10 months ago

I'm voting for this.. +1

alexturpin commented 10 months ago

Personally what I would love is being able to view the commit diffs in VS Code instead of the CLI. For now I use --no-auto-commits which works great.

omri123 commented 9 months ago

Hi, I would love to experiment with this idea. I have been looking for a good model of human-machine interaction for a long while, and Aider is the best I have seen. Would you like to review the following design?

The extension will be a direct interface to Aider. Activating Aider will open Aider in a terminal, and the user can type commands directly or using various context menus (file explorer -> some-file.txt -> add file to chat, etc.).

Benefits: the extension integrates Aider into the user's regular browsing workflow and makes it accessible via the marketplace.

Futuristic thoughts:

Later on, we can utilize vscode utilities to add information to the chat:

Using vscode-github integration, we can

We can also add aider commands that utilize built-in vscode utilities like "open diff view". By the way, we can also execute diff from Aider outside of vscode.

I plan to put the time and implement it, and your comments will be very valuable for me. Thank you very much:)

hellcats commented 7 months ago

One advantage of an editor interface is the ability to select text as a target for a prompt rather than having to describe what you want changed. I've found myself numbering comments so I can refer to sections of code with less typing. Something like Cursor editor.

omri123 commented 7 months ago

Thank you for this use case! By the way, I have a version in which aider see the code with line numbers. Would you like to try it? I would love to get feedback for it

https://github.com/paul-gauthier/aider/pull/348

hellcats commented 7 months ago

Sure, would love to.

On Nov 19, 2023, at 3:34 PM, omri123 @.***> wrote:

Thank you for this use case! By the way, I have a version in which aider see the code with line numbers. Would you like to try it? I would love to get feedback for it

348 https://github.com/paul-gauthier/aider/pull/348

— Reply to this email directly, view it on GitHub https://github.com/paul-gauthier/aider/issues/68#issuecomment-1817984467, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABKEQUJ343WPAYCTC45DSOLYFJ3P3AVCNFSM6AAAAAA2BWYNX6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMJXHE4DINBWG4. You are receiving this because you commented.

luisalrp commented 7 months ago

Is it possible to use it on Cursor?

joshuavial commented 7 months ago

@luisalrp yes - cursor is a clone of vs code so you can just fire up aider in the terminal window. If anyone gets excited enough to build a full vs code plugin then I expect it would work with cursor as well.

MattFlower commented 7 months ago

I just wanted to give a brief plug to my newly minted VSCode Extension for Aider. The extension follows in the footsteps of @joshuavial's neovim plugin in terms of features. Right now the main feature is the automatic addition and removal of files to the chat.

I'm extremely thankful for Aider and happy to contribute in this small way. If you run into any trouble with the extension, please let me know.

In case there was any question, of course I wrote it using Aider!

paul-gauthier commented 7 months ago

@MattFlower thanks so much for building and sharing this! I added a link in the install instructions.

omri123 commented 7 months ago

I would like to tell about a new vscode extension based on aider. This extension allows you to add additional conversation context from github issues and vscode language server. Everything goes with the good known aider command and auto completion. You can download it here

/add \issue-{id}
/add \references-{symbol}
/drop ...
# and a new command to show a context item:
/show ...

You can add any github issue, but only issues assigned to you will appear in autocomplete. The extension uses a fork of aider. @paul-gauthier to reach new audiences, most of the extension README is copied from aiders with an attribute. Are you ok with this arrangement?

0xdevalias commented 1 month ago

Semi-related: