Lurker News

Comments (1,272) 260 threads

Earlier comments
mdellavo2 replies#
Should I be impressed that the example parse_expenses.py on the home page doesnt include any error handling and uses a float for currency? This seems like it's going to revolutionize copy and paste programming.
arrayjumper3 replies#
It's a copilot. You're still the pilot. To be honest this seems like it can definitely save me a bunch of googling and let me stay in the ide.
mdellavo#
in their own example the copilot aimed for the mountains with float() - thanks but no thanks
rglover1 reply#
Tell that to the new programmer who builds a piece of software using this creating an absolute mess.

The danger here isn't with experienced developers (this is, obviously, a tool with great potential for productivity). It's with people who just blindly trust what the robot spits out.
Once code like that is implemented in a mission-critical system without discernment, all hell will break loose.
Edit: worth watching this for context https://www.youtube.com/watch?v=ZSRHeXYDLko

sergiomattei1 reply#
So? If you're making a mission critical system, don't hire subpar developers.

It's not Copilot's problem. Powerful tools can be misused by anyone.

Continue this thread — 1 reply

bob1029#
What is the hard boundary between you and your AI companion?

What happens when people think their "self driving" cars are more capable than they actually are? Many times, you are better off in a dumb car, because your expectations are such that you have to pay attention to a continuous stream of events and respond in a stateful manner.
If you try to bootstrap a holistic understanding of your problem in between bursts of auto-generated code, I don't think you are going to have a fantastic time of it.

acid__1 reply#
The output is great for a quick one-off script. Maybe if you make the comments look more “enterprise-y”, it’ll go for more careful code?
mdellavo#
I would say the use of float makes it a nonstarter - even for "quick one-off" scripts. That's a fundamental error in the generated code. It maybe looks correct at a quick glance but it's only introducing subtle errors to find down the line.
marcodiego#
Consider the following chain of events:

  - I write GPL'ed code.

  - Someone uses this tool to develop a proprietary solution.

  - I later prove that the tool generated code that is equal to mine.
Now the code of the proprietary solution must be GPL licensed! Cool!

How I'd defend myself? I'd only use such a tool if there are guarantees of the licenses of the code it was trained on. Without such guarantees, it is just too risky.

jms552 replies#
So the AI doesn't actually understand the code does it? It only looks for similar things. So if I'm writing a game in Rust using the hecs ECS library, how is it going to help me? How many other people have written a game in that language using that library in this genre trying to do this task before? Probably very very few.

And yeah that's a niche example, maybe this is super helpful for writing a react app or something very library heavy. But gut feeling without trying it is that there's no way this could actually work on anything but the most common tasks that you can google and find solutions for already, just made easier so you don't actually have to google for it.
When I used tabnine which learned from you as you edit, it was fairly helpful for very repetitive code within the same project. But it was no where near "read english and write the code I meant for it". I'm curious to know how well this actually performs for non-common tasks, and whether it can understand ideas in your codebase that you come up with. If I make a WorldAbstractionOverEntities thing in my code, and then later use it in the project, will the AI be able to help me out? Or is it going to go "sorry, no one on github has used this thing you came up with an hour ago, I can't help you". An AI that could understand your own codebase and the abstractions you make and not just popular libraries would be infinitely more useful imo.
That said, I haven't tried this, maybe it'll turn out really good.

sktrdie#
> how is it going to help me? How many other people have written a game in that language using that library in this genre trying to do this task before?

Because you write code using a bunch of patterns: iterating over data, destructing an object, calling functions etc. If you can generalize the usage of these patterns in such a way that it understands the context where you want to use them you're essentially doing this Copilot thing.
I agree that it'll be hard to have it understand fully the context and paradigms behind your existing project, but if it can help me automate some things in such a way that I can just let it run its thing and than have me "poke around it to get it right" then this is still amazing.

YeGoblynQueenne#
I have no idea how well Copilot will work in practice, but, in principle, imagine a huge Cartesian space where every program in Copilot's training data is a point. Call this space S. Now suppose S contains two programs P1 and P2. Copilot should be able to represent P1, P2 and any program in S that is on a gradient between P1 and P2. If you want to write a new program, P3, such that P3 is in S between P1 and P2, then you're in luck. Otherwise you'll get garbage.

This is explained in more detail in the article below; see the first section titled "Deep Learning: the geometric view":
https://blog.keras.io/the-limitations-of-deep-learning.html
In other words, Copilot should work well for boilerplate code and allow for many variations, but for anything more original it should be hit-and-miss. In principle. In practice, we'll know in a year or two, once enough people have used it. Or not even then.

bravogamma#
Generating new code is not very hard for humans. But maintaining, extending, debugging code - often that’s where the real challenges are. Will the AI copilot be able to fix bugs in its code based on bug reports?

Load more comments