VT2021 GitHubCopilot fiche: Difference between revisions

From air
Jump to navigation Jump to search
No edit summary
No edit summary
Line 16: Line 16:


===Acteurs===
===Acteurs===

todo
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.


===Concurrence===
===Concurrence===


Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
todo


==Fonctionnement==
==Fonctionnement==
todo


[[File:diagram.png | 500px | thumb | right | Comment ça marche]]


Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
[[File:github-github-copilot.gif | 500px | thumb | right | Autogénération de code d'une fonction]]


Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.


[[File:diagram.png | 500px | thumb | right | Comment ça marche]]


Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.

[[File:github-github-copilot.gif | 500px | thumb | right | Autogénération de code d'une fonction]]


==Critique==
==Critique==

Revision as of 18:38, 24 November 2021

Github Copilot est un outil d'intelligence artificielle développé par Github qui vous aide à écrire du code plus rapidement en complétant automatiquement le code.

GitHub Copilot Logo

GitHub Copilot

Abstract

"GitHub Copilot is an AI pair programmer that helps you write code faster and with less work. GitHub Copilot draws context from comments and code, and suggests individual lines and whole functions instantly. GitHub Copilot is powered by OpenAI Codex, a new AI system created by OpenAI. The GitHub Copilot technical preview is available as an extension for Visual Studio Code, Neovim, and the JetBrains suite of IDEs." - Documentation officielle de GitHub Copilot

Résumé

"GitHub Copilot est un outil d'IA qui vous aide à écrire du code plus rapidement et avec moins de travail. GitHub Copilot tire un contexte à partir de commentaires et du code, et suggère instantanément des lignes individuelles et des fonctions entières. GitHub Copilot est alimenté par OpenAI Codex, un nouveau système d'IA créé par OpenAI. L'aperçu technique de GitHub Copilot est disponible sous forme d'extension pour Visual Studio Code, Neovim et la suite d'IDE JetBrains." - Documentation officielle de GitHub Copilot

Origines

Acteurs

Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.

Concurrence

Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.

Fonctionnement

Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.

Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.

Comment ça marche

Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum. Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum. Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.

Autogénération de code d'une fonction

Critique

Même si il s'agit actuelllement d'une technical review, l’outil reste assez impresionnant et bluffant sur du code populaire : javascript / python / java / ... (code très présent sur github), ça reste assez bluffant, surtout quand on commence à écrire un commentaire et que l’on voit le code se générer devant vos yeux.

Aspect Juridique

Le fait d’exploiter des tonnes de code sous licence GPL pour alimenter un produit commercial peut poser de sérieuses questions d’éthique, notamment sur l’aspect violation de licence. GitHub indique « qu’entraîner des modèles de machine learning sur des données publiques est considéré comme une utilisation acceptable au sein de la communauté du machine learning ». On peut se poser légitiment la question de "Est-ce que le fait de d’utiliser un outil de génération de code donne vraiment le droit d’auteur sur votre code ?". Github assure que l'utilisateur qui utilise l'outil de génération a bien les droits mais cette partie reste flou. Le débat n'est pas encore résolu. Néanmoins, il y a des alternatives et quelques solutions pouvant résoudre ce problème à termes. Parmi celles ci on retrouve : - Détecter si le code est utilisable ou pas (en fonction de sa license) - Entrainer l'IA uniquement avec les codes sources d'un projet / ou du code d'une entreprise.

Remplacement des développeurs

Les développeurs coûtent cher aux entreprises. On peut légitimement se demander si cette outil ne causerait pas la perte des développeurs. Bien que l'outil soit assez bluffant, ce genre de solution doit être vu comme un outil et non un danger. Il permet d'alléger le temps de recherche / déboggage du développeur. Pour produire du code correct, il faut connaitre la technologie utilisé. Il est impossible d'utiliser GitHub Copilot sans avoir pratiqué de code. L'expertise et les compétences du développeur sont trop importantes pour pouvoir s'en passer. On peut plutôt voir cette outil comme un remplacement de Stackoverflow plutôt qu'un remplaçant des développeurs. Selon le CEO de GitHub, « les problèmes que nous mettions plusieurs jours à corriger pourraient diminuer en nombre, mais il y aura toujours des problèmes que les humains devront résoudre. »

Retour Utilisateur

  • Mémorisation d'éléments triviaux

Github Copylot nous permet de ne pas avoir à mémoriser un tas de choses triviaux sur le code. Quand on code il y a beaucoup de chose que l’on doit mémoriser ou alors qu’on a besoin de rechercher sur google.

  • Prédiction de code

L'effet "Woah!" de l'outil est accentué par son potentiel de prédiction. Il permet de générer jusqu'à 10 solutions différentes et permet même de prédire à l'avance les commentaires permettant de décrire eux même le code attendu.

  • Review de code

Le développeur prend la place du reviewer de code en utilisant cette outil. La lecture de code est une compétence importante que beaucoup d'entre nous ne pratiquent pas assez à l’école. Cela nous force à lire du code et à raisonner à ce sujet et à se demander est ce que cela va réellement produire le résultat souhaité. Mais c’est à une seule condition, c’est de vraiment prendre le temps de lire ce code. L'outil peut devenir très dangereux pour des développeurs juniors qui se reposeraient trop sur ce système et laisserait l'outil générer des failles de sécurité dans leur code.

Bilan

Il ne fait aucun doute qu'il fonctionne parfaitement pour les tâches simples sur des projets à petite échelle. À grande échelle, sur des projets plus conséquents, on aperçoit très rapidement les limites de l'outil notamment dans des applications qui se produisent dans un contexte de découplage backend/frontend, ou qui concernent un ensemble de microservices. Si la tâche n'est pas clairement définie et que le programmeur doit faire preuve de créativité, GitHub Copilot ne sera pas aussi utile.

On peut aussi se questionner sur le code qui est généré, GitHub Copilot a besoin d'une supervision totale. Il faut que la balance entre le temps gagnée sur l'écriture de code soit supérieur au temps perdue à la relecture de celui-ci.

Il sera très intéressant de suivre l'avancement du projet au cours des prochaines années quand celui-ci aura bien été roder afin d'atteindre un niveau de satisfaction suffisant.

Demonstration

Une démonstration de GitHub Copilot est accessible à ce lien : VT2021-GitHubCopilot_demo

Sources

Veille Technologique 2021