0% found this document useful (0 votes)
55 views14 pages

AI-Assisted-Coding

This document discusses the implications of AI-assisted coding for software developers, highlighting its benefits such as time-saving and potential uses in IT operations. It compares major tools like GitHub Copilot and Amazon CodeWhisperer, while also addressing concerns regarding open source licensing violations and the legal ramifications of using AI-generated code. The report emphasizes the ongoing evolution of AI-assisted coding and its uncertain future in software development.

Uploaded by

yağmur özel
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
55 views14 pages

AI-Assisted-Coding

This document discusses the implications of AI-assisted coding for software developers, highlighting its benefits such as time-saving and potential uses in IT operations. It compares major tools like GitHub Copilot and Amazon CodeWhisperer, while also addressing concerns regarding open source licensing violations and the legal ramifications of using AI-generated code. The report emphasizes the ongoing evolution of AI-assisted coding and its uncertain future in software development.

Uploaded by

yağmur özel
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

AI-Assisted Coding:

What Software
Developers Need
to Know
Should developers use AI to generate code? While there’s no clear
answer, this guide breaks down the pros and cons — and potential
impact — of AI-assisted coding in today’s development environment.
By Christopher Tozzi

NEXT
AI-Assisted Coding: What Software Developers Need to Know

TABLE OF CONTENTS
What Is AI-Assisted Coding, and Should You Use It?............................................... 4

4 Ways AI-Assisted Coding Can Benefit ITOps Engineers........................................ 7

Does AI-Assisted Coding Violate Open Source Licenses?........................................ 9

GitHub Copilot vs. Amazon CodeWhisperer: Key Differences................................. 12

PREVIOUS NEXT
2
AI-Assisted Coding: What Software Developers Need to Know

INTRODUCTION
There’s a shortage of software developers, and that isn’t going to change off in 2023, as more developers will at least start experimenting with it to
anytime soon. With the U.S. Bureau of Labor Statistics expecting that more generate code.
than 165,000 software developer jobs will need to be filled each year through This special report explains what AI-assisted coding is and its potential in
the end of the decade, developers now have more options. But the lack of today’s development environment, covering both its benefits and drawbacks
talent is also putting more strain on them, with their increasing and more for developers. And although GitHub Copilot and Amazon CodeWhisperer
complex workloads often leading to burnout — a 2021 Haystack Analytics aren’t the only AI-powered code generation tools, they are major players,
study found that a whopping 83% of developers suffer from burnout. so we compare the two tools to help developers choose which one best
But help may here in the form of AI-assisted coding — the use of machine suits their needs. The benefits of AI-assisted coding aren’t limited to just
learning models to generate code automatically. Developers are already software developers — this report also details four areas where AI-assisted
turning to AI-assisted coding, thanks in large part to the launch last June code generation tools and platforms can help ITOps engineers.
of Microsoft’s GitHub Copilot AI-assisted development tool and, just two AI-assisted coding isn’t without controversy, however. There are questions
days later, AWS’ Amazon CodeWhisperer. about whether AI-generated code violates open source software licenses,
There are a lot of benefits to using AI-assisted coding, the main one, of and at least one lawsuit has been filed claiming it does. We take a deep dive
course, being that it saves developers time by allowing them to write code into the potential licensing implications of AI-assisted coding that developers
without actually having to write code. That’s why we believe its use will take should know about before diving into AI-assisted programming.

PREVIOUS NEXT
3
AI-Assisted Coding: What Software Developers Need to Know

What Is AI-Assisted Coding and Should You Use It?


AI-assisted coding represents a frontier that’s still being conquered. Should IT pros take advantage now? Let’s break it down.

F
or years, the idea that you could to do. Then, the tools automatically generate
automatically generate custom source the code to do it, complete with custom
code seemed like fiction. But it has variable names and the invocation of external
become reality thanks to new services modules or services, where necessary.
like GitHub Copilot and Tabnine, which In the background, the tools are powered
provide AI-assisted code generation. by algorithms that were trained using vast
Solutions like these have shifted the amounts of existing source code — which
question from “how can we use AI to generate usually comes in the form of publicly available
code?” to “should we use AI to generate code?” source code produced by open source
There’s no clear answer, but there is plenty projects. Based on these examples, the
to say about the pros and cons of AI-assisted algorithms generate custom code on demand.
coding in today’s development environment.
How New Is AI-Assisted Code Generation?
What Is AI-Assisted Coding? The idea of automatically generating
AI-assisted coding is the use of machine source code for applications isn’t especially
learning models to generate code new. Low-code and no-code development
automatically. Most existing AI-assisted tools have been around for decades. And
coding tools let developers describe in IDEs have long offered autocomplete
natural language what they want their code features, which you could consider a simple

PREVIOUS NEXT
4
AI-Assisted Coding: What Software Developers Need to Know

form of automated code generation. Where to Find AI-Assisted Coding Tools


What’s different about AI-assisted code A variety of vendors now sell AI-assisted
“AI-assisted code generation offers one main benefit:
generation, however, is that, like low- coding tools or services. Probably the most
code and no-code tools, it doesn’t rely on famous are GitHub Copilot (which is based It saves developers time by allowing them to write code
on OpenAI Codex) and Microsoft Intellicode.
prebuilt code modules to allow developers without actually having to write code.”
to construct applications without writing Smaller companies, including Kite and
much (or any) code themselves. Instead, Tabnine, also offer production-ready tools
AI-assisted coding tools generate custom for AI-assisted code generation. at least now — to be able to generate truly Copilot is not named Autopilot).
code entirely from scratch. Open source tools exist in this domain, too, complex code. Plus, to get good results when Extensive code review: Developers have
This means that, at least in theory, there’s although — like many open source solutions in using these tools, developers often have to be to accept (or reject) automatically generated
newly established domains — they tend to be relatively specific about how they want their code as they work. For some coders, the
no limitation on what AI-assisted code
rougher around the edges than the commercial application to do something — so developers need to review code constantly could be
generation tools can do. As long as the
alternatives. To date, the main open source more or less need to know how they would distracting. They may be able to work more
algorithms are good enough and the data
AI-assisted coding tool is PolyCoder. write the code, even if they use AI-assisted efficiently if they just write out all of their
they are trained on is comprehensive enough,
AI-assisted coding tools could in principle tools to write it for them. code manually.
The Pros and Cons of AI-Powered Coding
write highly complex applications based only AI-assisted code generation offers one On the other hand, there are clear Legal and ethical issues: One of the
on natural-language descriptions of how main benefit: It saves developers time by drawbacks to AI-assisted coding: stickier issues involving AI-assisted
those applications should work. allowing them to write code without actually Low accuracy: Advanced AI-assisted coding tools is that, because the tools
Although developers have long talked — having to write code. coding solutions, like OpenAI Codex, are trained using open source code, they
usually half-jokingly — about the idea of You could also argue that AI-powered coding generate accurate code only 37% of the time, essentially reproduce code that was written
using AI to write code, AI-assisted coding tools are helpful in situations where developers according to their developers. That obviously by another project. This raises legal and
solutions have really only matured over the want to implement certain code but don’t falls far short of the performance necessary ethical questions, which have not yet been
past couple of years. They represent perhaps know how. I’m not convinced that that is the for programmers to let AI fully take the wheel sorted out. If your AI-assisted coding tool
the latest major innovation in the realm of case currently, however, because AI-assisted (which, to be fair, is not what these solutions produces code that closely resembles
software development. coding tools aren’t sophisticated enough — currently promise — there’s a reason why code in another GitHub repo, does it make

PREVIOUS NEXT
5
AI-Assisted Coding: What Software Developers Need to Know

you a plagiarizer or a license violator? We


don’t yet know, but we probably will gain
perspective as people begin suing each
other over these issues.
These challenges mean that AI-assisted
coding tools may be handy for developers
who want a fast way to generate relatively
simple code, and who are willing to review
— and, if necessary, tweak — it to ensure
it’s accurate. I also suspect that we’ll
see AI-assisted coding used more often
by programmers working on proprietary
projects whose source code won’t be
exposed to public scrutiny, and who
therefore are less likely to get caught up
in accusations that they’ve stolen other
projects’ code through their AI-powered
code generators.
But time will tell. For now, AI-assisted
coding represents a frontier that is still being
conquered. It will probably take several more
years before we know how good AI-assisted
coding tools end up being, and whether
they expose users to complicated legal or
ethical challenges.

PREVIOUS NEXT
6
AI-Assisted Coding: What Software Developers Need to Know

4 Ways AI-Assisted Coding Can Benefit ITOps Engineers


AI-assisted coding doesn’t just help software developers. It also helps ITOps engineers. Here’s how.

A
I-assisted coding — a practice that 1. Creating Infrastructure-as-Code hosting environments. By writing code to consuming and error-prone process.
uses artificial intelligence to help Templates define how the resources should be configured, However, the caveat with IaC is that
generate code — benefits software Infrastructure-as-code (IaC) tools are a then applying the configurations automatically, someone has to write the IaC templates that
developers first and foremost. great solution for ITOps engineers who have ITOps engineers can use IaC to avoid having determine how resources will be configured.
to configure large numbers of servers or cloud to configure each resource by hand — a time- Traditionally, that’s a task that ITOps
But the potential benefits of AI-assisted
engineers have had to perform by hand.
coding aren’t limited to software development.
But in the future, configuring IaC files may
They could also extend into other IT domains,
no longer require manual effort. AI-powered
including IT operations. Indeed, going coding tools could write the files automatically,
forward, the most efficient ITOps teams will based on natural-language input from ITOps
likely be relying increasingly on AI-powered engineers about how infrastructure should
coding tools to help speed their work and be configured. Rather than writing, say, a
reduce the risk of making mistakes. Terraform file by hand, you could simply say,
To prove the point, here’s a look at four areas “Write a Terraform file to set up a t2.micro
where ITOps engineers can benefit from AI- instance,” and an AI tool would write the
necessary configuration code for you.
assisted code generation tools and platforms,
along with an estimation of how close we are to 2. Writing Policy-as-Code Rules
a world where AI-powered coding tools become ITOps teams could adopt a similar strategy
a routine part of IT operations workflows. for writing policy-as-code files. Policy-as-code

PREVIOUS NEXT
7
AI-Assisted Coding: What Software Developers Need to Know

is an approach to setting up IT resources of coding technologies can address real-world


any type — not just infrastructure — using “AS with IaC files, someone has traditionally had to write policy-as- ITOps needs. One problem is that, for the
code-based configuration files. most part, the AI-assisted coding tools
As with IaC files, someone has traditionally had code rules or policies by hand. But AI-assisted coding could allow available today, like GitHub Copilot and
to write policy-as-code rules or policies by hand. ITOps teams to generate policy-as-code rules automatically.” Visual Studio IntelliCode, are geared toward
But AI-assisted coding could allow ITOps teams software development more than ITOps, and
to generate policy-as-code rules automatically. they are generally better at writing software
This would be important because it might automate this process. Engineers could received when I asked OpenAI to “generate a code than at writing configuration code.
encourage further adoption of policy-as-code describe how alerts should be managed, Terraform file to create a t2.micro instance”: A second challenge is that a lot of the
approaches to IT operations management. and the tools could write code to manage provider “aws” { ITOps platforms that could benefit most
Today, the use of code-based configuration the alerts accordingly.   region            = «us-east-1» from AI-assisted coding don’t yet support the
engines remains primarily limited to IaC. But   access_key = “ACCESS_KEY_HERE” integrations necessary to enable AI-powered
if it were possible to generate all types of 4. Configuring Observability Tools
  secret_key = “SECRET_KEY_HERE” configurations. In other words, we aren’t yet
policy configurations automatically, it would Likewise, observability tools could
} seeing integrations between, for instance,
become easier to configure any type of IT conceivably be configured using code
resource “aws_instance” “test” { observability platforms on the one hand
resource using this approach. generated by AI-powered tools. ITOps
  ami          = «ami-0ff8a91d» and AI-assisted coding tools on the other.
engineers could describe the metrics they
3. Alert Management   instance_type = «t2.micro» Vendors that target the ITOps space will need
want to collect and the data sources they
Alert management is another area where } to embrace AI-assisted code generation in
want to monitor, then leave it to AI to write
ITOps teams can benefit from AI-assisted Admittedly, that was a pretty simple query, order for this to change.
configuration files for their observability
coding. To manage alerts, engineers have but it shows that – at least for basic use Still, it seems pretty clear that AI-assisted
platforms based on those descriptions.
traditionally had to write rules that determine cases – the AI technology available today coding already offers tangible benefits to IT
when a monitoring tool should generate We Have the Technology is already quite good at writing the code operations teams, in addition to software
an alert, as well as how interrelated alerts Technologically speaking, the tools necessary necessary to complete ITOps tasks. development teams. The challenge going
should be grouped together. to perform the types of work described above On the other hand, there are limitations forward is for ITOps to figure out how to leverage
AI-powered code generation tools could already exist. For example, here’s the output I on the extent to which today’s AI-assisted AI-assisted coding in an efficient way.

PREVIOUS NEXT
8
AI-Assisted Coding: What Software Developers Need to Know

Does AI-Assisted
Coding Violate Open
Source Licenses?
There are questions about whether AI-generated code violates software licenses.
What does this mean for IT pros who use AI-assisted code generators?

A
I has thrown a wrench in traditional Here’s what developers need to know
understandings of open source about the potential licensing implications
software licensing — and developers of AI-assisted coding, and how to make
should pay attention, whether or not informed decisions about risks associated
they use open source software in the with these tools. for the code they write. generated code to be governed by the same
conventional sense. As a result, it’s plausible to argue — protections (such as the requirement that
The reason why is that AI-powered code Copilot, AI-Assisted Coding, and Open as some folks have — that AI-assisted it remain publicly available) as the original
generation tools, like GitHub Copilot and Source Licenses coding tools infringe on open source open source code on which the AI code
Amazon CodeWhisperer, are raising complex The cause for potential concern surrounding software licenses because the tools analyze generators were trained.
legal questions about what counts as open AI-assisted coding and open source licensing source code to generate their own code, so The fact that most AI-assisted coding
source licensing infringement. The answers infringement is simple enough: AI-assisted AI-generated code could be considered a tools never asked for or received
to those questions may turn out to be benign code generators like Copilot were trained “derivative work” of open source codebases. permissions from open source developers
— or they may place developers who use AI- by parsing millions of lines of open source Under the terms of many open source to train using their code also complicates
assisted code generators in legal hot water. code, and they use that code as the basis licenses, this would require the auto- matters — although legally, that’s probably

PREVIOUS NEXT
9
AI-Assisted Coding: What Software Developers Need to Know

not as important as the argument that original code. They analyze code written other people’s code and using it to help guide lawsuit would have to show that parsing
AI-generated code counts as a derivative by other people to generate their code, but their own programming endeavors. To my of public code repositories by AI-powered
work of open source projects. their code is their own. knowledge, no one has ever argued that a tools is different from humans who look
At l e a s t o n e d eve l o p e r h a s In this sense, AI-generated code doesn’t developer who reads publicly available code at publicly available code, and that seems
already launched a campaign aiming to seem to be all that different from code that written by other developers has violated hard to do.
investigate GitHub, which owns Copilot, human programmers write by looking at anyone’s rights or license. To succeed, a
for “violating its legal duties to open-source An Open Question
authors and end users.” That campaign has For now, the issue of whether tools
spawned a class-action lawsuit “on behalf like Copilot violate open source licenses,
of a proposed class of possibly millions and whether developers who use Copilot
of GitHub users … challenging the legality are bound by the terms of the licenses
of GitHub Copilot.” The suit targets not associated with the code on which Copilot
just Microsoft (which owns GitHub and trained, remains an open question. But it
Copilot) but also OpenAI, whose AI engine has important ramifications for the future
powers Copilot. of both AI-assisted coding and open
source licensing.
Is AI-Generated Code Really Illegal? If a court were to decide that AI-assisted
Parties claiming that AI-assisted coders coding violates open source licensing terms,
have broken the law — or at least violated it would threaten to shut down the nascent
licenses — seem to be facing an uphill battle AI-generated coding industry before it really
inside the courtroom in many ways. has a chance to take off.
Probably the hardest hurdle for them to It would also set a precedent that open
clear stems from the fact that tools like source licensing terms extend much further
Copilot don’t actually copy open source than most people previously imagined. It
code verbatim. They generate their own, would establish a much more expansive

PREVIOUS NEXT
10
AI-Assisted Coding: What Software Developers Need to Know

definition of “derivative work” in this context, CodeWhisperer, which was also trained in
and it might make some developers (and part on open source codebases.
businesses) think harder about when to use But they’re not. They’re singling out
open source code, and which specific open Microsoft and its partners.
source licenses to use or to avoid. Nonetheless, there’s a chance that the
fear, uncertainty, and doubt raised by this
Fear, Uncertainty, and Doubt:
debate will itself entice many developers
Open Source Edition
to shy away from AI-assisted coding. In
I’m no lawyer, but it seems unlikely to me
that respect, the campaign against tools
that courts would actually find AI-assisted
like Copilot may succeed, even if it ends up
coding tools to be in violation of open
source licenses. having no legal leg to stand on.
I also have a hunch that a lot of the That’s ironic, because Microsoft
legal saber-rattling that has occurred adopted this very strategy starting back
surrounding this issue reflects a desire by in the 1990s, when it filed legally dubious
some developers to throw shade over AI- lawsuits involving Unix licenses in order to
assisted coding — and possibly Microsoft, discourage businesses from using Linux.
the parent company of GitHub — more More than two decades later, Microsoft
than it results from genuine concern over has declared its love for Linux, and it no
licensing terms and developer rights. longer spreads fear, uncertainty, and doubt
After all, you’d think that if these folks about open source software. But at least
were worried about the legality of AI- a few open source developers are now
assisted coding in general, they’d also arguably wielding this tactic against an AI-
be investigating or suing companies like assisted coding tool owned by Microsoft.
Amazon, which has developed an AI- As the French say: Plus ça change, plus
assisted development tool of its own, c’est la même chose.

PREVIOUS
11
AI-Assisted Coding: What Software Developers Need to Know

GitHub Copilot vs.


Amazon CodeWhisperer:
Key Differences
The two AI-assisted software development tools are similar in many ways, but the
differences are worth noting. Here’s what developers need to know about Copilot
and CodeWhisperer.

O
n the surface, GitHub Copilot and But when you dive into the details, you’ll
Amazon CodeWhisperer don’t look notice that Copilot and CodeWhisperer work
that different. They are both tools a bit differently, as this article explains. They
that use AI to help accelerate software also focus on different sets of use cases,
development processes. They are also which is the most important distinction
both owned by and integrated with the between them.
ecosystems of major tech companies — What Is Copilot?
Microsoft in the case of Copilot, and Amazon Copilot is an AI-assisted software Copilot works by analyzing the code writing new code. Under the hood, Copilot
in the case of CodeWhisperer — which makes development tool from GitHub (which is that developers have written — including is powered by OpenAI Codex, an AI model
them different from AI-assisted development owned by Microsoft). GitHub introduced it in comments that describe how code should
tools owned by startups, such as Tabnine, 2021 and released it into general availability work, even if the code itself isn’t written yet that was trained on code inside millions of
rather than tech behemoths. in 2022. — then offers automated suggestions for publicly available source code repositories.

PREVIOUS NEXT
12
AI-Assisted Coding: What Software Developers Need to Know

What Is CodeWhisperer? A third similarity is that neither tool claims Nor does it mean that code written with want to write code for moving files between
CodeWhisperer is an AI-assisted software to be capable of writing entire software CodeWhisperer will only run on Amazon
Amazon S3 buckets, for instance, or for
development tool from Amazon. Like Copilot, programs on its own — at least for now. platforms. In most cases, it can run anywhere.
working with EC2 instances, you’ll probably
CodeWhisperer interprets comments made Both Copilot and CodeWhisperer limit Still, when it comes to writing code related
by developers, then automatically suggests themselves to helping complete relatively to Amazon technologies, CodeWhisperer have an easier time getting good code if you

code they might want to implement. small segments of code based on context typically does a better job than Copilot. If you use CodeWhisperer.
Amazon hasn’t disclosed a lot of details that developers provide.
about how CodeWhisperer works in the back
Major Differences Between Copilot
end, but it says that the AI models that power and CodeWhisperer
the tool were trained using both open source When you dig deeper into the specific use
code and code that is internal to Amazon. cases for each tool, however, you’ll notice
some important differences between Copilot
Copilot vs. CodeWhisperer:
and CodeWhisperer.
Key Similarities
The biggest difference is that Copilot is
From a functional perspective, Copilot and
designed to be more of a general-purpose
CodeWhisperer are quite similar. They both
AI-assisted development tool, whereas
address the same needs, and developers can
CodeWhisperer caters first and foremost
use them in the same ways. With either tool, to development use cases associated
you basically just describe what you want with Amazon platforms, such as Amazon
your code to do, then let AI models auto- Web Services.
suggest the code you need to do it. To be clear, this doesn’t mean you can’t use
Copilot and CodeWhisperer are also similar CodeWhisperer to help write applications
in that they are both cloud-based solutions that aren’t linked in any particular way to
offered by major tech vendors. the Amazon ecosystem. You certainly can.

PREVIOUS NEXT
13
AI-Assisted Coding: What Software Developers Need to Know

In contrast, although Copilot is hosted on a Choosing Between Copilot


Microsoft-owned platform, it doesn’t cater in and CodeWhisperer
Because of the differences described
any special way to Microsoft technologies or
above, it seems relatively easy at present
Microsoft-related programming use cases.
to decide whether Copilot or CodeWhisperer
It’s a general-purpose tool.
is better for varying AI-assisted
Another important difference between
development needs.
Copilot and CodeWhisperer is that In general, Copilot is the clear choice
CodeWhisperer supports many fewer because it offers support for a much broader
programming languages and IDEs. Currently, set of use cases. At present, the main reason
it’s compatible with just C#, Java, JavaScript, to choose CodeWhisperer over Copilot
Python, and TypeScript as programming would be if you are writing code related to
languages, and most of the IDEs it supports Amazon APIs, and/or if you only need your
are Amazon-based ones (JetBrains and AI-assisted development tool to support
Visual Studio Code are the exceptions). the limited set of programming languages
and IDEs with which CodeWhisperer
Copilot isn’t subject to these limitations.
is compatible.
Copilot can generate code in virtually any
This may change in the future if Amazon
language. And although GitHub says it’s
extends CodeWhisperer into a more
“optimized” only for certain languages, the list
general-purpose AI-assisted development
of such languages — which include Python, platform. But for now, Copilot beats
JavaScript, TypeScript, Ruby, Go, C#, and CodeWhisperer when it comes to flexibility
C++ — is longer than the list of languages and breadth, although CodeWhisperer
that CodeWhisperer supports. Copilot also is better at writing code for Amazon’s
supports almost all of the major IDEs. own APIs.

PREVIOUS
14

You might also like