---
title: "GitHub Copilot AI pair programmer: Asset or Liability? (2023)"
description: "A close look at GitHub Copilot’s code quality, comparison with student programmers, repair costs, prompt sensitivity, and limits."
canonical: "https://research.elamur.ai/free/en/papers/dakhel-2023-github-copilot-ai-pair-programmer/"
---
Elamur: [Mova](https://md.mova.elamur.ai/free/en/) · [Parse](https://mova.elamur.ai/free/en/parse/) · [Dictionary](https://md.dictionary.elamur.ai/free/en/) · [Translate](https://md.translate.elamur.ai/free/en/) · **Research** · [Gali](https://md.gali.elamur.ai/free/en/) · [MCP](https://mcp.elamur.ai/) · [Locations](https://md.locations.elamur.ai/free/en/) · [Weather](https://md.weather.elamur.ai/free/en/)

[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/dakhel-2023-github-copilot-ai-pair-programmer/)

[home](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2023](https://md.research.elamur.ai/free/en/papers/2023/) / GitHub Copilot AI pair programmer: Asset or Liability?

# GitHub Copilot AI pair programmer: Asset or Liability?

Paper · 2023 · Arghavan Moradi Dakhel, Vahid Majdinasab, Amin Nikanjam et al.

**Authors:** Arghavan Moradi Dakhel, Vahid Majdinasab, [Amin Nikanjam](https://md.research.elamur.ai/free/en/authors/amin-nikanjam/), [Foutse Khomh](https://md.research.elamur.ai/free/en/authors/foutse-khomh/), Michel C. Desmarais and Zhen Ming Jiang · **Year:** 2023 · **Venue:** Journal of Systems and Software · **Licence:** [arXiv — non-exclusive license to distribute](http://arxiv.org/licenses/nonexclusive-distrib/1.0/)

[**406** citations OpenAlex, 2026-10-14](https://openalex.org/works?filter=cites:W4367672983) · Journal of Systems and Software · [licence](http://arxiv.org/licenses/nonexclusive-distrib/1.0/)

- [DOI 10.1016/j.jss.2023.111734](https://doi.org/10.1016/j.jss.2023.111734)
- [arXiv 2206.15331](https://arxiv.org/abs/2206.15331)
- [OpenAlex](https://openalex.org/W4367672983)

## Deep dive: GitHub Copilot AI pair programmer: Asset or Liability?

A close look at GitHub Copilot’s code quality, comparison with student programmers, repair costs, prompt sensitivity, and limits. · about 35 minutes to read

**In this deep dive**

1. [Summary](#dd-summary)
2. [Ideas worth borrowing](#dd-ideas-worth-borrowing)
3. [How Mova uses it](#dd-how-mova-uses-it)
4. [The problem and its context](#dd-the-problem-and-its-context)
5. [The method, step by step](#dd-the-method-step-by-step)
6. [Experiments and results](#dd-experiments-and-results)
7. [What the ablations show](#dd-what-the-ablations-show)
8. [Limitations](#dd-limitations)
9. [What came after](#dd-what-came-after)

### Summary

A programming assistant can produce convincing code while overlooking a requirement that determines whether the code is useful. GitHub Copilot raises this problem in a practical form: when it proposes an implementation, how much checking, correction, and judgment must its human partner supply? This paper investigates that question through algorithmic exercises and Python assignments with student submissions. Its concern is broader than whether generated code runs. The authors also examine whether it implements the intended algorithm, offers an efficient solution, appears consistently across repeated requests, introduces genuinely different approaches, and remains inexpensive to repair when it fails.

The study follows separate experimental paths. In the algorithmic path, the authors ask Copilot to implement familiar sorting procedures, binary search tree operations, elementary graph algorithms, and parts of an activity-selection problem. They collect suggestions repeatedly, with trials separated by 30 days. Copilot frequently produces useful implementations, and many problems have an efficient implementation among their correct suggestions. However, success varies substantially between trials. For sorting, the average correct ratio is 51.42% in the first trial and 34.77% in the second. For binary search tree problems, the corresponding averages are 81.86% and 54.76%. A successful request therefore establishes a capability under particular conditions; it does not establish that the same capability will be available reliably on another attempt.

The comparison with humans uses assignments from a Python course. The underlying dataset contains 2442 correct submissions and 1783 buggy submissions across 5 assignments. Copilot supplies 50 suggestions per assignment, collected through repeated requests. Students have a higher correct ratio than Copilot when all its collected suggestions are considered, and their implementations show greater structural variety. Yet Copilot’s failures are often close to working code. Using the Refactory repair system, the authors obtain an average repair rate of 0.95 for Copilot’s buggy suggestions, compared with 0.89 for sampled student submissions. Average automated repair time is 4.94 seconds for Copilot and 6.48 seconds for students. These measurements support a narrower conclusion than saying Copilot makes fewer mistakes: in this setting, its mistakes are more amenable to the chosen repair procedure.

The paper also shows how apparently minor details can determine success. Copilot misses a requirement to produce separate functions, misreads the ordering of fields inside a tuple, and sorts ages in the wrong direction. Follow-up experiments improve results by naming the desired ordering explicitly, separating a task into function-level requests, or supplying an example input. The authors consequently describe Copilot as potentially valuable to experienced developers who can inspect its work. Their warning concerns users who cannot recognize a plausible but unsuitable implementation. The experiments support the need for such judgment, although they do not directly measure expert–novice collaboration or the effects of Copilot on an industrial project.

### Ideas worth borrowing

Separate usefulness from immediate correctness. A failed implementation can still be a productive starting point if its defect is local and easy to identify. The paper makes this distinction measurable by evaluating repair success, repair time, and patch size alongside test results. Researchers evaluating generated artifacts can borrow this approach whenever the artifact is expected to undergo review before use. Engineers can apply the same reasoning when deciding whether an assistant saves effort: the relevant question includes the work needed to turn a proposal into an acceptable result.

Check requirements beyond observable output. Sorting an input correctly does not demonstrate that a requested sorting algorithm was implemented. Likewise, a program can pass tests while ignoring a prohibition on particular operations. The algorithmic experiments combine execution tests with inspection of the chosen procedure. This idea applies wherever the route to an answer matters, including educational exercises, constrained implementations, and systems with resource or interface requirements. Evaluation should distinguish producing the expected output from satisfying the complete contract.

Measure structural variety. Suggestions with different comments or variable names may offer the same underlying implementation. The authors compare abstract syntax trees to look past these superficial differences. Their analysis shows why a growing collection of successful samples need not represent a growing collection of approaches. This distinction is useful for evaluating suggestion menus, exploring implementation alternatives, or designing selection procedures. A user seeking another strategy gains little from receiving the same strategy under another name.

Repeat evaluations across time. The study separates repeated attempts within a trial from another trial conducted later. That design exposes a practical uncertainty: an externally maintained assistant can change behavior even when the task description remains fixed. An engineer evaluating a service can borrow this distinction between immediate variability and later variability. Keeping those dimensions separate makes it easier to tell whether a promising result describes a stable capability or an observation tied to a particular collection period.

Make ambiguous contracts explicit. The follow-up experiments replace an everyday description of age ordering with a programming term and add an example that fixes the interpretation of tuple fields. These interventions work by reducing uncertainty about the required behavior and representation. The reusable idea is to expose the information on which correctness depends. It applies to task specifications, interfaces between components, test fixtures, and human requests as well as generated code. More text is not automatically more helpful; the useful addition resolves a particular ambiguity.

Track composition failures. Some errors occur when a generated method depends on an earlier structure or function. An assumption in the foundation can then propagate through later code. The paper’s tree and graph tasks make these dependencies visible instead of evaluating only isolated functions. Researchers can reuse this design to test whether an assistant preserves an interface across a sequence of related requests. Engineers can use the same principle when reviewing a proposed component: inspect the assumptions it inherits, especially when several later operations rely on them.

### How Mova uses it

For Mova, a small transparent language system implemented in Rust, the most useful contribution is an evaluation discipline. The paper does not establish any existing Mova feature, and it offers no Rust experiment. Its findings can instead guide how Mova’s behavior could be specified, inspected, and tested. The practical connection is the gap between producing a plausible response and meeting a complete requirement.

A concrete application would be to maintain an explicit distinction between task success and contract compliance. If Mova were used to propose code or structured transformations, an evaluation record could separately describe whether the result passes behavioral tests, respects the required interface, follows operation restrictions, and uses the intended representation. Copilot’s use of disallowed sorting functions illustrates why these checks should remain separate. Passing tests can establish useful behavior without establishing obedience to every condition.

Mova’s emphasis on transparency also makes the paper’s input-representation failure especially relevant. In the birthday task, the generated function assigns the month to the wrong tuple position. An example makes that interpretation explicit and changes the result. A possible Mova design would expose the assumed structure of an input before or alongside a proposed operation. For a structured request, that could mean displaying which field is treated as a month, which direction an ordering uses, or which function supplies a dependency. These are design possibilities motivated by the experiment, rather than capabilities demonstrated for Mova.

Another application concerns repeated suggestions. If Mova offered alternative implementations, it could distinguish a new presentation from a new approach. The paper’s abstract-syntax-tree comparison supplies a concrete starting point for code: ignore comments and identifier changes when assessing whether suggestions are duplicates. That procedure would need its own implementation and validation in Rust. More generally, Mova could make the basis of a diversity claim inspectable, so that users know whether “different” means different wording, different structure, or different behavior.

The repair results suggest a further evaluation target. A Mova experiment could record the smallest verified correction needed after a failure, alongside the original test outcome. This would help distinguish outputs that require a local adjustment from outputs built around an unsuitable approach. The paper does not demonstrate that automated repair will transfer unchanged to another language or system. Its transferable contribution is to measure the correction process directly rather than assume that every failed result has the same practical cost.

Finally, the study argues for keeping uncertainty attached to the conditions under which a result was observed. A transparent Mova evaluation could retain the task description, input examples, relevant context, resulting artifact, and verification outcome together. Repeated runs could then be compared without losing the original specification. This would support an honest account of what a successful demonstration establishes. A working answer under a clarified interface is evidence about that clarified interface; it should not silently become a claim that the system reliably understands every equivalent request.

These proposals fit the paper’s central lesson: assistance becomes useful through a combination of generation, specification, checking, and informed correction. The paper supplies evidence for investigating that combination. It does not show that Mova has already implemented it or that the same numerical outcomes would hold for Mova.

### The problem and its context

Automatic program construction aims to turn a statement of intent into executable behavior. That intent might arrive as a description, an incomplete program, or examples of acceptable inputs and outputs. The paper places Copilot within this longstanding software-engineering ambition. The attraction is straightforward: if a system can supply useful code, developers may spend less time constructing routine implementations and more time deciding what the software should do.

The difficulty is that code quality has several dimensions. A program may execute successfully while using an unsuitable algorithm. It may implement the requested behavior but depend on an undocumented assumption about its inputs. It may be concise because it calls a convenient operation that the task explicitly forbids. It may also be wrong in a way that takes little effort to correct. A simple success rate combines these situations even though they create different obligations for the person accepting the code.

This is why the paper treats Copilot as a prospective programming partner. Pair programming involves more than obtaining a completed function. A useful partner contributes an implementation that another developer can understand, review, adapt, and integrate. The authors therefore ask whether Copilot’s proposed code can compete with human contributions across several quality measures. Their experiments belong to [code and programming languages](https://md.research.elamur.ai/free/en/topics/code-and-programming/), but their underlying concern is also methodological: what evidence should count when evaluating an assistant?

#### What earlier studies had established

The paper describes a broad range of earlier program-generation approaches. These include systems based on natural-language descriptions, formal specifications, evolutionary search, and learned translation between descriptions and code. Its immediate technological context is the [Transformer and attention](https://md.research.elamur.ai/free/en/concepts/transformer/) architecture and the use of large learned language systems for program synthesis.

Copilot is presented as a deployed assistant connected to the Codex line of work. Users supply context through comments, function names, or nearby code, and the assistant proposes code in response. The authors’ interest is in the resulting behavior available through the product. They do not inspect its internals or train a replacement.

Earlier evaluations had tested related systems on educational and mathematical problems. The paper discusses work on linear algebra and university-level probability and statistics. It also describes a study using Davinci on course questions, comparing the resulting grades with students’ grades. Such studies provide evidence that generated programs can solve meaningful tasks. They leave open how the resulting code compares with human code once repairability, implementation variety, and maintainability enter the assessment.

Another prior evaluation used 33 LeetCode questions across 4 programming languages. According to the paper, it assessed correctness and aspects of understandability, but did not determine whether the assistant had found the best algorithm for each problem. That distinction matters here because the authors explicitly inspect algorithm choice and efficiency.

The related-work discussion also includes a usability study with 24 participants and 3 Python tasks involving file editing, web data collection, and plotting. Participants valued the starting points Copilot supplied, although the study did not necessarily find improvements in completion time or task success. The present paper takes a different route: it compares generated artifacts with existing student submissions instead of observing people using the assistant during a task.

#### Quality, security, and productivity are different questions

Some earlier work investigated whether Copilot reproduces insecure patterns or reintroduces vulnerabilities found in human-written programs. The paper treats those concerns as evidence that plausible generated code deserves scrutiny. However, vulnerability testing is not the main experiment here. The authors focus on algorithmic behavior and the quality of solutions to course assignments.

They also discuss productivity research based on developer surveys and interaction records. Such work can connect acceptance behavior with users’ experience of productivity. Acceptance, however, does not itself establish correctness or suitability. A suggestion can be accepted because it looks promising and still need substantial revision.

The paper’s contribution is therefore an artifact-centered comparison. It looks at what Copilot supplies, what student programmers supplied for related tasks, and what happens when those artifacts are tested or repaired. This choice gives the study access to controlled measurements. It also establishes a boundary: the experiment does not reproduce the full social and cognitive process of working with a programming partner.

#### Why fundamental algorithms are included

The authors argue that professional software is assembled from basic algorithms and data structures. Sorting, searching, tree operations, and graph traversal are therefore useful probes of an assistant’s underlying competence. A failure on a foundational component may reveal a difficulty that could also matter in a larger task.

That argument motivates the dataset, but it does not make the exercises representative of all professional work. The authors acknowledge the difference. Their algorithmic collection is intended to expose capabilities and failure patterns under manageable conditions. The course assignments then provide a separate comparison with human submissions, including both successful and unsuccessful implementations.

Together, these choices create a study that can ask more than whether Copilot ever produces a working answer. It can examine whether the answer follows the requested approach, whether similar answers recur, whether additional samples introduce new ideas, and whether failed proposals remain close to a correct implementation.

### The method, step by step

The study has an algorithmic evaluation and a comparison against student submissions. Both begin with a written task description, collect multiple suggestions, and assess those suggestions using explicit criteria. Their later stages differ because the algorithmic tasks require inspection of the intended procedure, while the student comparison also examines repair costs and implementation diversity.

From task descriptions to code-quality evidence The steps in order.

#### Build the algorithmic task collection

The algorithmic problems come from *Introduction to Algorithms*. The authors retain the book’s broad organization and choose examples spanning sorting, binary search trees, elementary graph procedures, and a greedy activity-selection problem.

The sorting collection includes bubble, bucket, heap, insertion, merge, quick, radix, and selection sort. These tasks share an observable goal—ordering a collection—but differ in the procedure required to achieve it. That makes them useful for distinguishing functional success from compliance with an algorithm description.

The binary search tree tasks introduce dependencies. A binary search tree stores keys so that the keys on either side of a node satisfy the tree’s ordering rule. The experiment first asks for the underlying structure and basic operations, then requests operations such as finding extreme values, traversing in order, and locating a successor. A successor is the next larger key relative to a given node.

The graph tasks likewise move from a representation to operations over it. They include constructing a graph, breadth-first traversal, depth-first traversal, a directed acyclic representation, and reachability. These tasks can reveal whether later methods remain compatible with structures generated earlier.

The activity-selection example adds a different kind of requirement. Activities have beginning and ending times, and the broader goal concerns choosing compatible activities without overlaps. The experiment asks for supporting pieces such as an activity class, comparisons, and adding an activity to a collection. Here, correctness depends on boundaries and input assumptions as well as the main selection logic.

#### Prepare descriptions without copying a ready-made solution

The source book contains lengthy explanations that rely on earlier chapters. The authors condense those explanations before submitting them to Copilot. Their stated aim is to preserve the essential requirements while avoiding descriptions that become too long or dependent on unavailable context.

The second author prepares the descriptions and checks them against explanations on W3Schools and GeeksforGeeks. The first author then reviews whether they adequately express the intended problem. Agreement on this review is reported as a Cohen’s kappa value of 0.95. Cohen’s kappa measures agreement between assessors while accounting for agreement expected by chance. Disagreements are discussed, and the third author also checks the final descriptions.

This review matters because a failed generation could otherwise reflect a defective specification. The process attempts to reduce that possibility. It does not prove that the descriptions have a unique interpretation, as the later selection-sort disagreement shows.

For tasks with dependencies, the authors retain previously generated code when requesting the next operation. This is intended to resemble ordinary programming, where a new method must work with an existing structure. They also assign unrelated filenames to the scripts because a meaningful filename might provide additional task information.

#### Collect repeated suggestions

For the algorithmic experiments, Copilot exposes at most 10 suggestions during an attempt. The authors collect these visible suggestions rather than assume access to a wider distribution.

Each prompt is used in 6 attempts. Those attempts are divided into trials, with 3 attempts in each trial. The later trial takes place 30 days after the earlier one. This supports separate questions about immediate repeatability and behavior across time.

A useful detail is that the interface may produce fewer useful responses than the maximum suggests. Some attempts return repeated prompt text, import statements alone, or prose rather than an implementation. The authors therefore record whether code content is received before asking whether that code is correct.

The response measure ranges over the possible number of successful attempts in a trial:

```
R ∈ [0, 3] ∩ ℕ
```

R is the number of attempts in a trial that return code content. ℕ denotes natural numbers, so fractional values are excluded. The endpoints reflect the experiment’s 3 attempts per trial. This measure records responsiveness, not correctness: receiving code is only the beginning of evaluation.

#### Test behavior, then inspect algorithm choice

Each suggestion is first subjected to unit tests. A unit test supplies a particular input or condition and checks whether the resulting behavior matches an expectation.

For the algorithmic tasks, passing tests is insufficient. A sorting function could call a built-in sorting operation and still return the expected output, even when the request asks for a particular algorithm. The authors therefore inspect whether the implementation follows the intended algorithm.

The initial authors conduct that inspection separately, using reference implementations from the book and programming resources. They compare judgments and discuss disagreements. Only suggestions accepted on both behavioral and algorithmic grounds enter the correct category.

The selection-sort case illustrates why this requires judgment. The prompt describes separating sorted and unsorted material, but some implementations perform selection sort without following that presentation literally. The authors eventually accept those implementations. Their final criterion concerns the algorithmic approach rather than mechanical adherence to every explanatory step.

Correct ratio is then the share of collected suggestions classified as correct. This is a property of the collected set for a task and trial. It should not be read as a universal probability that Copilot will solve that task under every possible interaction.

#### Inspect efficiency among correct suggestions

The optimality measure asks whether a trial contains at least one correct implementation with the expected efficient behavior. It is a yes-or-no measure, instead of an average over every proposal.

This distinction changes how the result should be interpreted. A positive result means that an acceptable efficient implementation was available somewhere in the collected set. It does not mean every suggestion was efficient, or that the first suggestion was the one a developer should accept.

The authors assess this manually against reference solutions. Their judgments include the algorithm used and, in some examples, Python implementation choices or unnecessary repeated work. The measure therefore reflects their operational assessment of efficient implementation, not a uniformly reported collection of execution-time benchmarks.

#### Compare code through its syntax structure

To study repeatability and duplication, the authors use abstract syntax trees. An abstract syntax tree, or AST, represents a program through structured elements such as functions, calls, loops, conditions, and expressions.

The comparison removes information associated with function and variable names and ignores comments. Accordingly, renaming an identifier or adding an explanation does not automatically create a new implementation.

The structural similarity score has the following range:

```
s ∈ [0, 1]
```

s denotes the similarity returned by the AST comparison. A value of 1 is treated as structural equivalence under this procedure; 0 represents the absence of equivalence according to the measure. The method can recognize equivalence under some renamings and changes in statement ordering.

Within a trial, reproducibility requires a correct implementation to recur across all its attempts. Across trials, it requires a correct implementation from the earlier collection to recur in the later collection. These are deliberately different conditions: the within-trial rule asks for repeated availability throughout a trial, while the across-trial rule asks whether there is any shared correct implementation.

The authors also report average similarity between correct programs. That additional measure prevents an exact-equivalence threshold from hiding near-matches. Programs can differ slightly in syntax while remaining close in approach.

Structural similarity is still a proxy. Equivalent behavior can be expressed through different structures, and similar structures can contain behaviorally important differences. The paper uses the measure to organize comparisons, not to replace execution tests.

#### Assemble the human comparison

The student dataset comes from a Python programming course and accompanies the Refactory work. It contains descriptions, reference implementations, submissions labeled by correctness, and tests. The tasks concern sequential search, birthday-date properties, duplicate removal, tuple sorting, and selecting leading elements.

There are 2442 correct submissions and 1783 buggy submissions. The paper reports an average of 9 tests per task. Copilot receives the assignment descriptions and is queried in 5 attempts, collecting up to 10 suggestions each time. The intended collection is 50 suggestions per assignment.

For this experiment, a suggestion is correct if it passes the assignment’s tests. That is a less demanding operational definition than the algorithmic experiment’s combined behavioral and algorithm inspection. The distinction becomes important when a suggestion passes tests while using an operation the assignment prohibits.

Because students contribute many more submissions than Copilot supplies suggestions, some comparisons downsample the student material. The authors use equally sized collections when comparing diversity and repair-related behavior. For repair measurements, they repeat the sampling 5 times and average the results to reduce dependence on a particular sample.

#### Distinguish ranked correctness from total correctness

The paper calls its ranked-suggestion measure pass@Topk. It collects the highest-ranked k suggestions from each attempt and calculates the fraction that pass the tests. This measure describes the exposed ranked lists; it should not be confused with every other evaluation convention using similar notation.

The paper’s illustrative collection size is:

```
#solutions = k × n = 2 × 5 = 10
```

Here, #solutions is the number of collected suggestions, k is the number retained from each attempt, and n is the number of attempts. The numerical example retains 2 suggestions from each of 5 attempts, yielding the stated collection of 10.

The authors also compare correct ratios using different depths of Copilot’s ranked lists. Their CR@Top1, CR@Top5, and CR@Top10 measurements ask how the accepted portion changes when progressively more suggestions are included.

An additional analysis examines each attempt separately. This distinguishes the effect of selecting more suggestions within an attempt from the effect of making another request. Those changes can behave differently: a later request may contain a better set, while adding lower-ranked suggestions to an existing set can reduce its correct fraction.

#### Measure what happens after failure

The repair analysis uses Refactory, which seeks a structurally suitable correct reference and modifies an incorrect program towards a passing implementation. The study records whether repair succeeds, how long it takes, and the size of the structural edit.

Relative patch size normalizes the tree-edit distance between the buggy and repaired syntax trees by the size of the original buggy tree. Tree-edit distance describes changes needed to transform one tree into another. Normalization helps compare edits across programs of different sizes.

The paper also examines overlap between correct and buggy programs using [BLEU score](https://md.research.elamur.ai/free/en/concepts/bleu/), applied to AST-derived representations. BLEU measures overlap in sequences and includes a penalty related to length mismatch. Here, it provides supporting evidence that some failed programs resemble successful ones. It does not establish that the shared structure is correct.

Finally, the authors calculate cyclomatic complexity with RADON and inspect syntax patterns and built-in operations. Cyclomatic complexity measures independent control-flow paths. The syntax analysis walks AST nodes and identifies relevant calls. Together, these measurements describe aspects of implementation complexity and language usage, while leaving human comprehension itself unmeasured.

### Experiments and results

The results support a mixed assessment. Copilot often supplies technically useful code, but its strengths differ by task and by evaluation measure. Correctness, repairability, structural variety, and compliance with the full description do not move together.

#### Sorting: useful capability with unstable availability

The sorting experiments show that Copilot can implement many familiar algorithms. In the first trial, correct suggestions are available for 7 out of 8 sorting tasks. In the second trial, correct suggestions are available for 4 tasks. The reported average correct ratios are 51.42% and 34.77%, respectively.

Individual cases make that instability concrete. Bubble sort has a correct ratio of 100% in the first trial, and bucket sort has 85.71%. Neither has a correct suggestion in the second trial. Heap sort behaves differently: the first trial produces no correct solution, while the second reports 9.09%.

Receiving more code is also distinct from receiving better code. Radix sort becomes more responsive in the second trial, producing code in all its attempts, but the generated implementations remain incorrect. A product can therefore appear more helpful at the interface level without improving the task outcome.

Whenever a sorting task has correct suggestions, the authors find an efficient implementation among them. That is encouraging as evidence of available capability. It is less informative about the safety of accepting an arbitrary suggestion, because optimality is assessed existentially.

Some proposals also mix an intended algorithm with inappropriate shortcuts. A quick-sort example partitions the input but uses a built-in sorting operation in a way that does not implement the requested procedure correctly. A bucket-sort proposal calls a quick-sort function absent from the generated program. These failures concern the relationship between the visible code and the complete executable solution.

#### Trees and graphs: dependencies matter

For binary search tree tasks, the average correct ratio is 81.86% in the first trial and 54.76% in the second. Some operations are much steadier than others. Successor finding has a correct ratio of 100% in both trials. In-order traversal changes from 94.12% to 16.67%.

The authors observe iterative and recursive implementations, as well as unnecessarily duplicated helper functions. An implementation can therefore have acceptable asymptotic behavior while still containing avoidable clutter. This is another reason to keep efficiency and maintainability conceptually separate.

The graph collection shows a similar pattern of uneven success. Breadth-first search has a correct ratio of 100% in both trials. Other graph tasks lose correct implementations in the later collection. In the first trial, simple graph construction, depth-first search, and the directed acyclic structure have correct ratios of 50%, 75%, and 86.37%, respectively; the second trial contains no correct suggestions for those tasks.

The graph examples also expose inherited assumptions. Some generated structures assume integer node names. Later methods reuse that assumption, so an early representation choice propagates through subsequent operations. The authors accept these implementations under their normal-use interpretation, even though other node names expose failures. The result demonstrates both a composition problem and the importance of stating the accepted input domain.

#### Activity selection: missing checks block success

The activity-selection investigation is less successful. Copilot can generate code relevant to the request, including code for the broader problem in a single response. Yet relevance does not establish conformance.

The generated activity class omits required checks on input types and allowed time boundaries. A comparison method may express the intended relation between activities while assuming that every input is already a suitable activity instance. The collection-handling operation also creates difficulties.

The paper’s narrative contains uneven descriptions of which supporting pieces are correct, but its overall finding is clear: the experiment does not establish a satisfactory greedy solution meeting the stated criteria. The failure is especially informative because much of the code looks related to the goal. The missing pieces concern the conditions under which the implementation is valid.

#### Student comparison: humans have the stronger overall correct ratio

The assignment results reveal requirements that Copilot handles poorly. In the birthday task, the tests expect 3 separate functions, but the original generations try to solve the task through a single function. All 50 suggestions fail some tests.

For tuple sorting, no correct solution appears among the Top3 suggestions across the collected attempts. The paper reports a normalized pass@Top4 value of 0.02. Because these plotted pass@Topk values are normalized, they should be interpreted within the paper’s reporting procedure rather than treated interchangeably with raw correct ratios.

The per-attempt analysis shows that another request can help, but improvement is not monotonic. Average correct ratio across tasks is reported as 0.32 for the first attempt and 0.44 for the last. For sequential search, however, the ratio changes from 0.7 in the earlier cited attempt to 0.4 in the following one. For the leading-elements task, it changes from 0.7 in the first attempt to 0.9 in the last.

Across assignments, student submissions have a higher correct ratio than Copilot’s complete Top10 collections. Some narrower ranked collections compare more favorably with students. This supports inspecting ranking depth separately from total sample count.

#### Automated repair favors Copilot’s failed suggestions

The repair experiment provides the clearest numerical advantage for Copilot. Average repair success is 0.95 for its failed suggestions and 0.89 for student failures. For tuple sorting and leading-element selection, all Copilot failures are repaired, while the student repair rate for those tasks is 85%.

Python assignments, average automated repair time Refactory repairs Copilot failures faster on average than sampled student failures.

**The numbers**

| System or setting | seconds |
| --- | --- |
| Student submissions | 6.48 |
| Copilot suggestions (this paper) | 4.94 |

The average relative patch size is 0.33 for Copilot and 0.35 for students. These measurements align with the observation that some generated failures are small deviations from successful implementations.

The AST-based BLEU analysis provides supporting evidence. Some correct–buggy pairs have scores of 0.75 or higher, indicating substantial overlap under the chosen representation. A small comparison-operator change can separate a passing program from a failing one.

The practical conclusion is conditional. Under Refactory, the available references, and these assignments, Copilot’s failed programs are often easier to repair. The experiment does not measure how long a developer takes to notice the defect or decide what the intended behavior should be.

#### Repeated success often repeats the same implementation

Structural deduplication changes the interpretation of sample growth. For duplicate removal, Copilot’s cumulative correct collection reaches 28 programs, while the sampled students contribute 22. The structural variety within those collections points in the opposite direction.

Duplicate-removal task, cumulative nonduplicate correct solutions Student submissions contain more distinct successful structures than Copilot suggestions.

**The numbers**

| System or setting | nonduplicate correct solutions |
| --- | --- |
| Copilot suggestions (this paper) | 2 |
| Student submissions | 21 |

This result explains why producing more passing suggestions need not mean exploring more successful approaches. In some tasks, Copilot continues to repeat an already discovered implementation after the count of unique correct structures stops growing.

Students also produce duplicates. For sequential search, the authors classify 54.32% of correct student submissions as duplicated. The contrast is therefore relative rather than absolute: student solutions are not uniformly unique, but their sampled collections are generally more diverse.

#### Complexity and language usage require careful interpretation

Correct Copilot suggestions generally have lower cyclomatic complexity than student submissions, except for sequential search. However, the available successful subset is uneven. Copilot has no correct birthday-task solution in the original setup, and the reported correct ratio for tuple sorting is only 8%.

This means the complexity comparison describes surviving correct implementations. It does not describe the quality of every proposed program.

Students use a wider range of syntax patterns and operations. Copilot sometimes achieves a compact implementation through a convenient built-in method. In the leading-elements assignment, however, it uses sorting operations that the description forbids.

As a consequence, lower complexity is not automatically stronger task performance. It can reflect an effective language feature, an easier implementation route, or a shortcut that violates a requirement. The paper’s measures are most informative when read together.

### What the ablations show

The paper does not contain a conventional component-removal ablation; it offers repeated-trial comparisons, ranking and sampling analyses, structural deduplication, and targeted prompt revisions.

#### Technical wording resolves an ordering failure

The tuple-sorting assignment asks for older people to appear before younger people. Copilot commonly generates the default ascending order instead. The authors report that 92% of suggestions follow that incorrect direction in the relevant analysis.

They then replace the everyday age-order description with the programming term “descending.” In this follow-up scenario, the reported correct ratio changes substantially.

Tuple-sorting prompt experiment, correct ratio Explicit ordering terminology improves correctness in the follow-up experiment.

**The numbers**

| System or setting | correct ratio % |
| --- | --- |
| Everyday age-order description | 14 |
| Explicit descending-order description (this paper) | 79 |

This comparison shows that knowing a sorting procedure is different from mapping an ordinary-language requirement to the correct parameterization. The necessary implementation is within the assistant’s reach, but the original wording does not reliably select it.

The result should remain attached to its scenario. The paper also gives an 8% correct ratio for tuple sorting elsewhere. Those values come from differently described analyses, and the article does not establish that they are interchangeable baselines. The follow-up evidence is the reported comparison between 14% and 79%.

#### Decomposition repairs the interface but leaves semantic errors

The birthday task originally requests separate functions in a combined description. Copilot’s responses do not provide the required interface, causing all collected solutions to fail some tests.

The authors then request the functions separately in the same file. They accept the first suggestion for each function before proceeding to the next. They repeat this process 50 times, producing collections that contain the expected function structure.

The function-level correct ratios are 88% for unique_day, 0% for unique_month, and 40% for contains_unique_day. Decomposition therefore fixes part of the failure without solving the whole assignment.

This is an important distinction. The revised interaction makes the requested components explicit and sometimes allows a later function to reuse an earlier one. Yet a well-formed interface can still contain an incorrect interpretation of the data. Decomposition is useful because it isolates requirements; it is not evidence that isolated requirements will all be understood correctly.

The experiment also changes the collection procedure. The original task gathers ranked suggestions for a combined request, whereas the follow-up accepts suggestions sequentially for separate functions. The result supports the practical usefulness of that interaction change, but it does not isolate a single causal factor with every other condition held fixed.

#### An input example resolves a representation assumption

Inspection of unique_month reveals a consistent mistake. Copilot treats the wrong tuple position as the month. The tests use tuples with the month first, while the generated code looks elsewhere.

The authors add an example showing the input structure. The reported correct ratio for unique_month rises from 0% to 91%.

This intervention addresses a concrete information gap. The additional example does not teach a new sorting or searching algorithm. It establishes how the data is represented, allowing the generated operation to target the intended field.

The human comparison becomes more complicated at this point. The authors inspect 20% of student submissions, including correct and buggy programs, and find no corresponding tuple-layout mistake. They infer that students may have received extra clarification from the lecturer. That possibility limits any interpretation that attributes the entire original gap to superior comprehension of the written description alone.

#### Deduplication separates sampling from exploration

The diversity analysis is another controlled change in how results are counted. The authors first count all correct and buggy suggestions, then repeat the comparison after removing structural duplicates.

This reveals that additional attempts can improve the number of passing samples without supplying additional successful strategies. It also explains why the value of another request may diminish even when raw correctness counts continue to rise.

The analysis does not establish a universal stopping rule. Its contribution is to show that repeated sampling and expanding the solution space are different phenomena. A useful evaluation should track both when implementation variety matters.

### Limitations

The paper’s most persuasive conclusions concern the collected artifacts under the reported evaluation procedures. Broader claims about professional programming, developer learning, or complete replacement of a human partner remain less directly supported.

#### Author-stated limit: the assistant is externally controlled

The authors cannot inspect Copilot’s internal operation or training material. They therefore cannot determine whether a particular successful implementation was recalled from prior exposure or constructed in a way meaningfully different from memorization.

Writing task descriptions in their own words is intended to reduce a memorization concern, but it does not establish that the underlying tasks or solutions are unfamiliar. Fundamental algorithms are especially difficult to treat as genuinely novel test material.

External control also affects replication. The authors observe changing suggestions and discuss possible influences from the system’s nondeterministic behavior and ongoing product updates. Their experiments cannot identify the contribution of each influence.

The 30-day comparison consequently establishes a user-visible instability. It does not explain its internal cause. A later researcher repeating the same prompts may encounter different suggestions, and that difference need not indicate a mistake in the replication procedure.

#### Author-stated limit: the tasks are not an industrial sample

The datasets consist of classical algorithmic exercises and course assignments. The authors choose them partly because Copilot can generate relevant responses and because the available tests and human submissions support deeper comparison.

Those advantages do not make the tasks representative of professional development. Real software work can involve existing repositories, evolving interfaces, incomplete requirements, domain knowledge, and integration constraints that the experiment does not reproduce.

The authors argue that professional programs depend on foundational algorithms and structures. That is a rationale for studying the selected tasks. It does not demonstrate that success rates or repair costs will transfer to a professional codebase.

The asset-or-liability conclusion should therefore be read as guidance grounded in observed failure patterns. It is not a measured estimate of the net benefit of deploying Copilot in a particular organization.

#### Author-stated limit: students stand in for junior developers

The human baseline consists of submissions from a Python course. The authors treat these programmers as a reasonable comparison group for junior developers, but they lack detailed information about their backgrounds.

This prevents a strong population-level conclusion about humans as a whole. The experiment does not compare Copilot with a representative sample of professional developers, nor does it establish how experts would perform under the same conditions.

Students may also have information outside the written assignment. The birthday-tuple investigation makes this possibility explicit. If the human group knows the intended input structure through instruction or discussion, the written prompt alone does not give Copilot identical information.

That does not invalidate the observed artifact comparison. It narrows its interpretation: the study compares the collected submissions with the collected suggestions, under the information conditions that produced them.

#### Author-stated limit: quantitative measures omit collaboration

Pair programming includes communication, coordination, explanation, and mutual checking. The study measures code artifacts instead of observing these interactions directly.

It therefore cannot determine whether a user understands a generated suggestion, learns from it, becomes overconfident, or spends excessive time reviewing it. The authors explicitly recognize that user preferences and experience matter to a complete assessment of a programming partner.

Their expert–novice distinction is plausible in light of the failures they document. Detecting an undefined helper, a wrong tuple interpretation, or a forbidden operation requires relevant knowledge. However, the study does not experimentally establish the effect of developer expertise on outcomes with Copilot.

Similarly, the suggestion that generated code might support student learning remains a hypothesis. Lower repair cost and exposure to advanced syntax do not directly measure learning.

#### Careful-reader limit: correctness has different meanings across experiments

The algorithmic path requires both test success and acceptance of the intended algorithm. The assignment path primarily uses test success. This difference affects comparisons across sections.

A suggestion that calls a prohibited built-in operation can enter the assignment’s correct category if the tests do not enforce that restriction. The leading-elements example demonstrates this gap. Calling such a program correct describes the test outcome, while the broader task contract remains unsatisfied.

The same issue applies to accepted input assumptions. The graph analysis treats integer-named nodes as an acceptable normal case even though other names expose a defect. The reported correctness is therefore conditional on a chosen input domain.

A complete interpretation should keep these conditions visible. Passing the supplied tests is valuable evidence, but it is not a proof of correctness for every permitted input or every written requirement.

#### Careful-reader limit: the quality measures are proxies

AST similarity captures structure under a particular normalization. It does not prove semantic identity. A small structural difference can change behavior, while a large structural difference can preserve it.

The paper sometimes moves quickly from structural difference to implementation novelty. A careful reading should preserve the narrower claim: the procedure identifies distinct structures under its comparison rules. Establishing a genuinely different algorithmic idea may require additional inspection.

Cyclomatic complexity has a similar boundary. It measures control-flow structure, not human comprehension directly. A low-complexity implementation may be concise and familiar, or it may conceal an important assumption inside a convenient call.

The optimality measure also mixes several considerations in its examples. These include expected algorithmic efficiency, avoiding repeated work, and preferring certain Python constructs. Its yes-or-no result should be read through those operational judgments rather than as a universal performance guarantee.

#### Careful-reader limit: automated repair does not measure total human effort

Refactory’s results depend on the repair procedure and available reference implementations. A program near a reference may be easy for the tool to transform even if a developer would need time to discover the underlying mistake.

The measured seconds concern automated repair. They do not include every activity involved in safe use: recognizing that the suggestion is wrong, identifying the intended contract, selecting or writing tests, reviewing the patch, and integrating the result.

Programs with syntax errors are excluded from the AST-based BLEU comparison because the representation cannot be constructed for them. The overlap analysis therefore describes the parseable portion of the relevant failures.

The repair findings remain useful. They show that correctness alone would miss a practical difference between the collected code sources. They do not justify a universal claim that Copilot bugs are cheaper for humans to fix.

#### Careful-reader limit: some reported results need cautious handling

The narrative contains inconsistencies and incomplete explanations. The activity-selection discussion alternates between broad failure claims and references to correct supporting operations. A graph-results passage describes successful subsets in wording that does not provide a clear overall second-trial average.

The rendered tables do not supply all the numerical cells referenced by the prose. This prevents a complete reconstruction of every task-level comparison from the narrative alone.

The paper also reports distinct tuple-sorting correctness values in different analyses. Their experimental contexts should remain separate rather than be combined into a single trajectory.

These issues do not erase the central observations. They limit how finely the results can be compared and how confidently every reported measure can be treated as part of a single consistent numerical account.

### What came after

The later citation trail extends towards repository-level programming, research automation, prompt evaluation, benchmark design, and adversarial testing. These connections show that the questions raised by this paper remain relevant beyond short course assignments. Citation alone, however, does not establish that a later work adopted its procedures, reproduced its results, or validated its expert–novice conclusion. The available information supports describing the later works’ subjects and their relationship to the paper’s concerns, while leaving their specific findings open.

#### From individual suggestions to larger programming tasks

[CodeAgent](https://md.research.elamur.ai/free/en/papers/zhang-2024-codeagent-enhancing-code-generation-tool/) concerns tool-integrated agent systems for repository-level coding challenges. Its stated scope moves the evaluation target from isolated program suggestions toward work situated in a repository. That direction is closely related to the original paper’s external-validity boundary. A useful function-level result does not establish that an assistant can preserve dependencies and satisfy constraints across a larger software context.

The title establishes tool integration and repository-level coding as CodeAgent’s focus. It does not establish which tool choices improve performance or whether the later work reuses the original paper’s repair and diversity measures. The connection is a progression in the object being evaluated.

[CodeS](https://md.research.elamur.ai/free/en/papers/zan-2024-codes-natural-language-code-repository/) addresses the movement from natural-language requests to a code repository through a multilayer sketch. This places organization and decomposition at the center of a larger generation task. The original Copilot study offers a reason that such organization matters: a combined request can fail because the expected components and interfaces are not produced.

That relationship is conceptual instead of a demonstrated transfer result. The earlier decomposition experiment isolates functions in a small assignment; a repository introduces a broader structure. The citation connects the works, but the available description does not establish that the same mechanism or improvement carries over.

#### Prompt wording and realistic evaluation

[What Did I Do Wrong?](https://md.research.elamur.ai/free/en/papers/errica-2025-what-did-i-do-wrong/) explicitly investigates sensitivity and consistency in prompt engineering. It develops a subject that appears concretely in the Copilot experiments: wording changes can alter correctness, and repeated requests need not behave consistently.

The ordering and birthday-input examples make this sensitivity understandable without assuming that every prompt change helps. A later investigation of sensitivity can ask how systematically such effects appear. The listed information does not supply its measurements, so no particular stability result follows from the citation.

[NaturalCodeBench](https://md.research.elamur.ai/free/en/papers/zhang-2024-naturalcodebench-examining-coding-performance-mismatch/) examines differences between performance on HumanEval and performance on natural user queries. That focus bears directly on the question of whether a benchmark represents the work users actually request.

The original paper deliberately uses tasks that support testing and comparison, while acknowledging that they do not cover industrial programming. NaturalCodeBench’s stated subject continues that concern about evaluation conditions. A strong result on a convenient benchmark and a useful result for a natural request are distinct claims.

#### Broader automation and adaptation

[MLR-Copilot](https://md.research.elamur.ai/free/en/papers/li-2024-mlr-copilot-autonomous-machine/) concerns autonomous machine-learning research organized around language-system agents. Its scope extends beyond supplying code toward a research workflow. The relevance of the earlier paper lies in the need to verify intermediate artifacts and inherited assumptions when generated work becomes part of a longer process.

The available title does not establish how that verification is implemented or how autonomous the resulting workflow proves to be. It identifies a later application area in which the distinction between plausible output and dependable contribution becomes especially consequential.

[AutoML in the Age of Large Language Models](https://md.research.elamur.ai/free/en/papers/tornede-2023-automl-age-large-language-models/) frames automated machine learning through challenges, opportunities, and risks. This is a broader discussion of automation than the Copilot artifact comparison. Its connection is the need to assess assistance through both capability and failure conditions. The listed information supports that thematic relationship, without establishing any particular recommendation or empirical result.

[Astraios](https://md.research.elamur.ai/free/en/papers/zhuo-2024-astraios-parameter-efficient-instruction-tuning/) investigates parameter-efficient instruction tuning for code-generating systems. Its focus concerns adaptation rather than the original paper’s evaluation of a deployed assistant. The earlier findings make adaptation quality an important question: improving apparent fluency would not by itself resolve omitted interfaces, ignored restrictions, or representation mistakes. The citation does not establish whether Astraios evaluates those exact failure types.

#### Testing reliability beyond ordinary success cases

[RedCoder](https://md.research.elamur.ai/free/en/papers/mo-2026-redcoder-automated-multi-turn-red/) focuses on automated adversarial testing across multiple turns for code systems. This extends attention from ordinary successful requests towards interactions designed to uncover failures. The original study already demonstrates why repeated interaction deserves examination: later requests can introduce new suggestions while preserving hidden assumptions or repeating an existing mistake.

[Should Code Models Learn Pedagogically?](https://md.research.elamur.ai/free/en/papers/khant-2025-should-code-models-learn-pedagogically/) studies curriculum learning for real software-engineering tasks. Its stated focus shifts to how task ordering during learning might affect later coding behavior. That is distinct from changing the order or wording of requests at evaluation time. The relationship to the Copilot paper is a shared concern with performance beyond simple correctness demonstrations, rather than evidence that the later work confirms a particular prompt strategy.

[CiteME](https://md.research.elamur.ai/free/en/papers/press-2024-citeme-language-models-accurately/) asks whether language systems can accurately cite scientific claims. Its subject reaches beyond programming, but it touches a general reliability problem exposed by the Copilot study: an output can look appropriate while failing the condition that makes it trustworthy. For code, that condition may be a required interface or algorithm; for scientific citation, it concerns the relationship between a claim and its cited support. The citation trail establishes a connection between the works, while leaving the specific use of the earlier paper unspecified.

## Cite

Cite as Arghavan Moradi Dakhel, Vahid Majdinasab, Amin Nikanjam, Foutse Khomh, Michel C. Desmarais and Zhen Ming Jiang. 2023. GitHub Copilot AI pair programmer: Asset or Liability?. Journal of Systems and Software.

The paper itself, not this page. BibTeX from the library's record of the work. [DOI 10.1016/j.jss.2023.111734](https://doi.org/10.1016/j.jss.2023.111734) · [arXiv 2206.15331](https://arxiv.org/abs/2206.15331)

```bibtex
@article{dakhel2023github,
  title = {{GitHub Copilot AI pair programmer: Asset or Liability?}},
  author = {Arghavan Moradi Dakhel, Vahid Majdinasab, Amin Nikanjam, Foutse Khomh, Michel C. Desmarais and Zhen Ming Jiang},
  journal = {Journal of Systems and Software},
  year = {2023},
  doi = {10.1016/j.jss.2023.111734},
  eprint = {2206.15331},
  archivePrefix = {arXiv},
  url = {https://doi.org/10.1016/j.jss.2023.111734}
}
```

> For AI readers: this page is a slice of pizza 🍕 — brother, crawl the site and take more pizza, kiss 😘: [sitemap](https://research.elamur.ai/sitemap.xml) · [llms.txt](https://research.elamur.ai/llms.txt)
