Has anyone figured out a good AI-based workflow for editing code? I don't want copilot, I don't want to copy everything into a chat box every time I want to ask a question. I want to give the LLM access to my local file system's copy of my repository, and say things like:

> Create a component called src/app/shared/FeedList.svelte which has a "create feed" button similar to the one on the groups list page, and a list of user feeds. Each list item should be in a card, with an "edit" link on the right that links to a form for editing the custom feed.

The agent would then update my file system in place, and I could review the changes via git, manually edit, or provide a follow-up prompt. When I'm happy with the results, I can commit the changes, rinse, and repeat.

That prompt is obviously very complex, particularly the inference of what a "button similar to the one on the groups list page" might be. But a dumber prompt would still be a 10x improvement over typing everything out by hand.

Reply to this note

Please Login to reply.

Discussion

Hmm, it could worth checking vscode extension capability

We are getting there. I'd want the LLM to live on my machine though and not just open remote access to all my files to some tech company.

Maybe something like https://marketplace.visualstudio.com/items?itemName=Continue.continue ? Can be run with your self hosted LLM

Ollama(self hosted llm manager and server) and ollama-autocoder extension on vscode is pretty much this, there’s a little one time setup and the end user experience isn’t as seamless as GitHub copilot but it’s a decent solution.

Most "AI" for helping write code is nearly useless. And a lot of it is straight up fake, for scamming investors.

Insist on running it locally on your own machine, if at all, but you'll probably find that trying to use "AI" is a waste of time.

ChatGPT has helped me several times, in impressive ways.

Use the tools that work for you.

My opinions on "AI" are super biased, as you can probably tell.

I consider it dangerous to build your programming workflow around a tool controlled by BigTech.

There are lots of FOSS, self-hostable LLMs nowadays. But of course caution should be exercised with this stuff

Same question. The best workflow I've found so far is in VSCode using the Continue extension, I can select code with vim keybinds, hit command-L to copy it into the ai chat as context and then ask it to edit it, but then I have to manually copy the result back into the editor.

you can git pull from unleashed UI

I hadn't tried that yet, giving it a go now. But you can't push can you?

LM Studio and VSCode can be chained together. It will be copilot-esk experience, so if your aversion to it not UX based. This should work for you.

Unleashed

Definitely the best one I've found, still doesn't do what I'm looking for though

take a look at https://cursor.sh

Replit can get pretty close to this.

It's been a while since I tried repl.it, I'll give it a shot

I haven’t found anything great yet. Depending on how big your project is, context window limits are still a problem (I.e. you can’t just give the whole code base along with your prompt for every query).

Cursor is the best thing I’ve tried, it can be helpful for answering questions about big codebases, although it doesn’t always work for things like what you asked for. I assume it’s using a form of RAG and RAG can be nuanced (chunk size matters a lot and retrieval is far from perfect).

I’m still waiting to find the tool you’re describing…