Live data from Hacker News

Coping with Copilot

sigarch.org

191–200 of 463 posts

Re: Coping with Copilot

#191

Earlier quoted context omitted.

someone can still mirror your stuff on github. I wonder if they should make a special open source license, that disallows use of the source code for the purpose of training something like Copilot.

> I wonder if they should make a special open source license, that disallows use of the source code for the purpose of training something like Copilot. Since Microsoft uses material for copilot outside of licensing on the basis that it is Fair Use, that would probably have no effect in practice on whether or not the material is used in training something like Copilot. For that to matter, you’d first have to win a law…

> Since Microsoft uses material for copilot outside of licensing on the basis that it is Fair Use, that would probably have no effect in practice

i think that any formal violation of an open source license would be very bad in terms of public relations - even if they can claim fair use.

Re: Coping with Copilot

#192
Do people no longer generally have exams on paper?

For lower level courses we had online assignments, and pen and paper exams - which is where the majority of the course grade came from. If you didn't [intimately] know what you were doing on the assignments, you'd fail the classes due to the tests.

Re: Coping with Copilot

#193
Ever heard of just-in-time learning? Copilot (if it gets good enough) is the damn teaching tool! All they need to do is come up with a programming goal/project thats extremely important/relevant/exciting to them, and break the problem down into sub-problems for copilot. This time they'll actually give a shit to understand why copilot wrote a bug or why the code works. No more boring pointless teacher assignments that hold no relevance whatsoever for the students most immediate and important goals and concerns in life. Finally life is fucking good for students for once and they dont need to google every answer for an hour.

Re: Coping with Copilot

#195
No big deal. If students have access to this, then instead of trying to teach them and grade them on fibonacci - let the next generation have larger assignments. Like building a 3d rendered first person shooter (a basic one with no AI)

Re: Coping with Copilot

#196
post #175

Earlier quoted context omitted.

Copilot doesn't change the fact that trivial questions (such as 'write a Fibonacci function') can already be googled. What I don't know (I can't try the 'free' Copilot without providing a credit card), is how well it understands unusual constraints and separate pieces of C++ classes that make the real programs we write. For instance, a simple test would be: "write a fibonacci function but skip the number 5". Does it…

I (surprisingly) could not get it to generate a Fibonacci function that skips 5.

As a human, I’m having trouble understanding the problem description. What does it mean to “skip 5”? I’ve always understood the definition of a Fibonacci sequence to be, starting with 2 numbers (usually 1 and 1) the next number in the sequence is the sum of the previous 2.

So starting with 1 and 1, we get 2. 2 and 1 is three. 3 and 2 is five. What do we do from here? Do I not add 5 and 3? If not, then what do I add? 3 and 2 again? Do I repeat 3 and get 6? What does it mean to “skip 5”?

Re: Coping with Copilot

#197

Earlier quoted context omitted.

I've been writing code for nearly as long and man, you have to try it. It's more like autocomplete on roids than something that generates Fibonacci methods automagically.

Not until there's a setting that can guarantee the automcomplete is based on verifiably license-unencumbered source that is automatically tracked in some kind of sourcemap that tells me which parts of "the code I didn't write" comes from which other project and file inside that project. Until then, copilot is a giant liability that ensures I can't use it for code that my company ends up owning, nor can I contribute c…

I would also be comfortable with a service that was willing to broadly indemnify me as the customer from copyright and patent claims arising from code generated by their service. I doubt that will ever happen either.

Re: Coping with Copilot

#198

Copilot is limited to short snippets. You can't just ask it to write a HTTP server. Also I don't see how having copilot generate the code for listening on a server socket is any better than when I copied how to do it out of a man page. Copilot doesn't add anything new, you've always been able to look up the documentation or look up how other people approach the problem. The fibonacci example doesn't make much sense e…

Copilot can almost write an HTTP server. Here is how I did it:

1. Start a new python file with the line "# This is an implementation of an HTTP server"

2. Press autocomplete a bunch of times and stop somewhere when "enough" libraries are imported

3. Press "#" and let it autocomplete the comment about what comes next (global variables for PORT and BUFFER_SIZE in my case)

4. Again, Press "#" and let it autocomplete a bunch of comments and functions ("get_file_extension", "get_file_content_type", "get_file_size" in my case)

5. At this step, I had to cheat a bit since it was generating too many "get_*" functions, so I started a comment with "# Initialize" and let it autocomplete again to get "init_server_socket"

6. From here on, it generated handle_request, parse_request, get_file_path and send_response automatically.

7. Lastly, I wrote "def main" and let it autocomplete again.

This produced an HTTP server which almost worked. I just had to fix a small issue with "file_path", since it expected that files were stored in the root directory, but I wanted it to load files from the local directory.

The code is not great since it does not handle most errors gracefully and is vulnerable to directory traversal, but I didn't even have to think about the HTTP protocol while writing it, so it is still quite impressive.

A few good points:

It generated a huge selection of MIME types which I probably would have had to look up by hand.

The generated server is multi-threaded!

It automatically reuses the socket, so I do not have to wait a minute every time I restart the server.

Here is the final code: https://bpa.st/CTRA

Re: Coping with Copilot

#199
post #165

Earlier quoted context omitted.

> They're, for the most part, things we tried to put in libraries. We need some people who can do things like making those libraries. It also seems plausible that the people who have at least some of the knowledge and judgement to do that effectively will, on average, be more effective on more mundane tasks as well. Larry Wall is one who wrote (somewhat drolly) about the virtues of laziness, but there was nothing laz…

> We need some people who can do things like making those libraries. Do we? For things as simple as copilot tends to put out? Why? Do you also believe we need to keep people around that do other automated things? Plowing fields by hand? Hand compiling higher level languages (as the first lisp compiler was bootstrapped)? I mean, keep the information around. Don't go burning textbooks on subjects just because we automa…

[deleted]

Re: Coping with Copilot

#200
post #126

Earlier quoted context omitted.

> if students are unwilling to learn, or are taking shortcuts, it will ultimately hurt them in the long run That's a very limited, and dismissive view. If you allow students to use copilot, you're handing out certificates or diplomas to people who can't code. That will very quickly erode the value of your institute's certification, and with it, that of the other students. Otherwise, why not give everyone an MSc in CS…

"you're handing out certificates or diplomas to people who can't code" The diploma is not issued after only the 101 course.

So people who couldn't find a max value in an array will somehow excel at advanced concepts later?
Post reply on HN