4 ms·
What's funny is that i often see Copilot give you code that Intellisense/a type system will tell you is obviously wrong. I wish Copilot was more integrated with
by madeofpalk 4y ago
What's funny is that i often see Copilot give you code that Intellisense/a type system will tell you is obviously wrong. I wish Copilot was more integrated with type systems.
- phire 4y agoWhat's worse, is that if you make a mistake in the code leading up to it's completion (even one picked up by Intellisense), Copilot will now assume that you actually wanted the mistakes, and it's autocompletion will give you even more mistakes.
- neoberg 4y agoIt produces very good results with typescript. When there is an interface and I'm creating an object that implements the interface; it produces a result that fits into that type.
- madeofpalk 4y agoThis has not been my experience with Copilot and Typescript.
- adamddev1 4y agoSame here.
- baby 4y agoSame with Rust. Sometimes I just have to write a comment saying "display implementation for X" and it will autocomplete with the trait implementation. This is extra magical because I don't need to remember the exact detail of the trait.
- dgunay 4y agoIt is definitely hit or miss, but I don't find it too annoying to just clean up the small mismatches that crop up sometimes.
- gamegoblin 4y agoRight now Copilot is just given the surrounding code, which is obviously limited. I suspect the next big jump will be a model that is given: 1. The surrounding code 2. The type/intellisense information of all the identifiers in the surrounding code 3. The class/function definition of any identifiers in the surrounding code I think #3 will be huge. There is a huge difference in Copilot's performance when dealing with types defined right above where you are writing code, and types defined in some far-away module or library. Right now if you use a class you defined in another file or adjacent project, Copilot can't see it. But your IDE has jump-to-definition functionality that could trivially be wired in to something like Copilot. The team behind Stable Diffusion (the image synthesis model that's been all over HN recently) have said they are working on stuff like Copilot as well, so I expect we will see a huge transformation in this space in the next year or two.
- wokwokwok 4y agoThis. It feels like something that is obvious and should go in the copilot plugin rather than copilot itself. Given N suggestions, validate the code + snippet on them using normal error checking. Promote suggestions with no errors. The intellij plugin, for example, will often suggest 'default' suggestions that are entirely wrong. Given that `foo.bar.foobar()` exists, it'll suggestion `foo.something.SomethingClever()` when those functions don't exist, or exist on types other than foo. However, if you look at all the suggestions on the side panel, you'll see several of them are actually valid. It's just that the default completion isn't.