Categories
Software development

GitHub Copilot recent experience

Reading Time: 2 minutes

We have using GitHub Copilot probably for 2 years now. First used as a tool for code view, and then expanded as plug-in inside the IDE (both IntelliJ and VS Code). We can ask all kinds of questions in the conversation dialog. Personally I used it to generate unit test code a few months ago.

While the tool is helpful both in code review and in software (or application) development in general, recently I also noticed two issues, both are annoying. And it seems the issues are somewhat related to what Martin Fowler said in his recent blog post “I don’t like LLMs“.

Issue one: it gave totally irrelevant code review comments. I don’t know where the comments originated from, but the tone it used again reminds me of the Mr. Fowler’s post. For me the only solution is add my comments in the Copilot code review comments and move on. It’s not the only time Copilot code review provided this kind of comments. The overall tone from Copilot is

Issue two: this one honestly stumbled upon me, and took me a while to understand the rationale of Copilot’s mistake. I asked Copilot to fix an issue of “unnecessary mockito stubbing” during unit testing. Note the code was generated by Copilot, and what it does was: to remove 2 lines of code which is not supposed to remove, while the correct solution is to remove the same 2 lines of code in a similar function. The main difference between the 2 functions here is one fucntion is with togglz off, while the other is with togglz on. It kept doing that for a few times, until I realized I can manually do it by removing those two lines in the correct function. I think in this case Copilot still is helpful to me – but this small incident reinforced my thinking of “trust but verify” for AI generated code.

At the same time, I read a bit of “When AI writes almost all code, what happens to software engineering?” (Substack link, I came across it from LinkedIn) by Pragmatic Programmer aka Gergely Orosz. It sounds like he is more bullish on AI or AI generating code. Note the Substack article was written in last Nov or Dec.

Another related observation is, I notice sometimes colleagues would say: let AI do the algorithm or something like that (the implied meaning seems to me is we are not as smart as AI).

One counter argument is: the big tech companies are the ones leading the charge using AI to generating code, but at the same time their code quality sometimes are horrendous, such as the Uber Driver App – e.g., this personal experience I had when I was delivering for Uber Eats.

Last but not least let me share a short talk I came across from my friend and a professor in management science at my alma mater Huazhong University of Science and Technology, as shown below. In Chinese. I assume you can ask ChatGPT or Google Gemini for translations if needed.

Categories
Software development Technology

AI AI AI

Reading Time: 2 minutes
Screenshot from Chatgpt

Background

Years ago when I think of AI, I only think about the autonomous driving (driverless car or self driving car). The tech behind it is so called “deep learning“, and it’s a part of Artificial Intelligence. Now it’s all the Chatgpt and Generative AI, or in Chinese tech community, AIGC (AIG generated content) is on the rage.

Is it AI or just computer vs human? I recall I could not beat the computer on chess.com (I believe it’ just the computer algorithm behind it, there is no machine learning behind the scene) easily. Note I am not a very good chess player. But I recall Google has this AlphaZero and it beats chess world-champion. The latter probably has some artificial intelligence and some machine learning capability.

Apple’s approach

(CNBC) Apple’s practical approach to A.I.: No bragging, just features

Personally I like Apple’s way of roll out AI as time goes approach. For Apple: over the years I noticed iPhone in particular would guess where I want to go, I think it probably looked at my calendar and the usage of map app. Also I like the “featured photo” and “memories” feature on the iPhone photos app very much. The other day I saw the feature photo on my iPhone was my old daughter 1st school day picture. I know Facebook and Google photos can probably do that too. But for Facebook I think I would need to upload the photo that day. Not sure about Google, because I used Android at most for 1 year or 2, among my last 13 years use of smartphone.

Apple rarely rolls out things or features when they are not ready. I recall the rumor (a while ago especially) there was talk of Apple Car. But till today there is no Apple Car been seen in the real world, which is quite different from Tesla, Alphabet (Google) Waymo and Cruise (GM).

Impact on other people’s livelihood

The main worry in addition to invasion or erosion of privacy, is the AI could potentially take over people’s jobs. One area is in the creative arena, artists, writers etc. Below is a real story.

An artist explains why Marvel’s use of AI to animate a sequence is worrying : NPR

Also ethic issues such as faking (pretend as) other people, and we saw some of that as well: It takes a few dollars and 8 minutes to create a deepfake. And that’s only the start

I related question I have: how many of the Twitter Chinese porn video are made by AI, those #pigButcher style of videos. Also this one made by AI

Again, Google, Microsoft, and Meta can’t stop talking about A.I. — here’s why Apple rarely mentions it.

Tech leaders mention AI almost 170 times during earnings calls: report (you can do a google search on it if you are curious, I am not lying).