News for hackers. Stuff that matters.

Ask HN: Any AI-based Code Assistants for web CRUD apps?

I'm looking for something to help me faster code CRUD endpoints for a Rails side project. Is there something more integrated than ChatGPT4? Like, I give it access to my codebase, it parses it and understands the models etc. and can then crank simple features?
( 11 comments | 3 points | on HN )
Re:Ask HN: Any AI-based Code Assistants for web CRUD apps? by jcpst on Friday November 24, 2023 @04:19PM (#38408480)
This is what I use github copilot for.
Re:Ask HN: Any AI-based Code Assistants for web CRUD apps? by endorphine on Friday November 24, 2023 @05:20PM (#38409020)
I have Copilot in vim, but it only autocompletes things. Can you tell it something like "I want you to introduce a new view that will be rendered when the user does X and it will have 3 buttons that will do Y"?
Re:Ask HN: Any AI-based Code Assistants for web CRUD apps? by vunderba on Friday November 24, 2023 @06:42PM (#38409634)
I think Copilot Chat X is supposed to introduce these kinds of features, but it's still in beta atm. Could look into Continue, an extension for vs code and jetbrains.
Re:Ask HN: Any AI-based Code Assistants for web CRUD apps? by iamflimflam1 on Saturday November 25, 2023 @04:09AM (#38412305)
Try it in VS Code. There’s a much richer interface including chat.
Re:Ask HN: Any AI-based Code Assistants for web CRUD apps? by gitgud on Saturday November 25, 2023 @07:34AM (#38413117)
I think if you write what you want in a “code comment” then below it will try to implement that comment in the autocomplete
Re:Ask HN: Any AI-based Code Assistants for web CRUD apps? by jcpst on Saturday November 25, 2023 @04:37PM (#38416926)
That’s been my experience. Also, if I’m doing CRUD, and I’ve already written code for one resource, it will give me completions in the style of that first one.
Re:Ask HN: Any AI-based Code Assistants for web CRUD apps? by cloudking on Friday November 24, 2023 @04:03PM (#38408309)
GitHub Co-pilot can take into context your codebase.
Re:Ask HN: Any AI-based Code Assistants for web CRUD apps? by qup on Friday November 24, 2023 @06:22PM (#38409498)
Re:Ask HN: Any AI-based Code Assistants for web CRUD apps? by lfciv on Saturday November 25, 2023 @10:45AM (#38414205)
I used to use Github Copilot, but I find Cursor (https://cursor.sh/) to be even better.

You can add an OpenAI API Key and it'll use the GPT-4 API. It indexes your code for you and it'll crawl documentation for you if you give it the link. Then you can reference specific files or documentation with "@". There are also some really intuitive hot keys.

Re:Ask HN: Any AI-based Code Assistants for web CRUD apps? by lfciv on Saturday November 25, 2023 @10:47AM (#38414220)
Also regarding CRUD apps – I actually was able to automate code generation of most of my CRUD pretty easily using cursor. I hand wrote a couple of them and now I just create the new file and prompt it referencing the Model and one of the other CRUD files as an example.
Re:Ask HN: Any AI-based Code Assistants for web CRUD apps? by rblalock on Sunday November 26, 2023 @08:23AM (#38421405)
Cursor is amazing and I can't figure out why. Is it just because their UX is better than what Copilot is doing? The whole cmd+K and doing a live edit/diff is so useful. I realize Copilot has almost the same short cut key(s) for the same purpose..but it's just not as smooth.