Artificial Intelligence (AI) is a growing part of our daily lives. We interact with Siri on our iPhones, we order Amazon products with Alexa and soon we’ll be trusting our cars to safely drive us to our destinations. Now we also have AI helping us write software code by interpreting and delivering solutions by predicting developers’ intention for code. The AI can offer robust code options, complete code snippets, classes, and methods. This is a much more robust contribution and collaboration than a suggested path. It helps you write complete code blocks.
How do we get an AI model that writes code for us?
Artificial Intelligence is the result of repetitive Machine Learning (ML) using a large dataset. A facial recognition AI, for example, is the result of ML pouring over millions of images of human and animal faces. The success and failure to recognize a human face is tracked and shapes the next repetition of testing.
Similarly, to predict what a developer is going to need for his next line of code the AI would need ML from a large variety of software code. Comparing software code written in different programming languages would also improve the quality of the AI’s code recommendation. GitHub is arguably the largest data store for a variety of software code written in almost every programming language. GitHub has leveraged its vast inclusive content to create an exclusive AI code completion tool called CoPilot.
The controversy of using an AI code completion
Simple code recommendation tools, like Intellisense, have been part of developer toolkits for decades. A more complete AI-driven service as a software substitute has stirred emotional, ethical, and legal concerns.
Job Threat - Software development takes education and years of experience to become proficient. Some software developers could look at AI-written code as a threat to their job or that their expertise is being undervalued. When considering an AI tool to write software, be sure to consider the broader impact on morale and the unity of the development team. It may be a good fit for the team and another tool to use. It could also be a source of resentment and dissolve productivity in highly functional teams.
Exclusive Service Created from Inclusive Community Content - An AI-driven Service as a Software Substitute tool is leveraging available big data to give their AI enough training to be a reliable solution. In his paper ‘Copilot, Copying, Commons, Community, Culture’ Robert F.J. Seddon compares the four conceptions (i) of community written by Peter Dahos - ‘A Philosophy of Intellectual Property” (ii). Since GitHub is arguably the largest repository of publicly available software, it is a resource provided by an inclusive community. When the owner of that inclusive content leverages it into a commodity (a product) it becomes an exclusive resource immediately limiting access to the inclusive community.
Untested Legal Position on Intellectual Rights - If you use an AI-powered code completion tool that has a model built from a public, open-source software, how can this AI-created code be used for commercial solutions? Can this code be merged into an enterprise intellectual property?
In the July 2021 article ‘Analyzing the Legal Implications of GitHub Copilot’ (iii) the FOSSA team interviewed an Intellectual Property lawyer to get answers to these questions. In this article, the lawyer gave a great example of how Google provides sample content from millions of books it has indexed. It was ruled that Google was not infringing on the copyrighted material because a small sample of the material was made available. Comparing that to a code completion tool, it is not providing a complete body of work, only a small section of it.
But you should still be cautious using an AI to provide code completion. “I’d caution anyone using Copilot right now to help write code to pay close attention to the nature of Copilot’s suggestions,” Downing says. “To the extent you see a piece of suggested code that’s very clearly regurgitated from another source — perhaps it still has comments attached to it, for example — use your common sense and don’t use those kinds of suggestions.”
The Future Of AI
The development of AI tools is accelerating at an exponential rate. You can expect it to become more integrated with your personal and work activities. As more samples of big data become available, there are more opportunities to train an AI solution. One prediction I have for an AI tool: A solution that would interrogate an entire enterprise, examining internal file systems, code repositories and network topology then create workflow documentation, offering process improvement recommendations along the way.
I enjoy pair-programming with another developer but if that’s not an option I would consider an AI tool to get a feeling of collaboration during the development process. For some teams, it could be the support a developer needs to be productive.
As a developer, I don’t feel my job is at risk from AI-written code because there is high demand for skilled developers. I see it as a tool, similar to Intellisense, that would help me get the job done.
I know AI-written code raises moral concerns around inclusive vs. exclusive communities. The developer community needs to guard against abusive behavior from companies commoditizing on open and inclusive resources.
(i) Copilot, Copying, Commons, Community, Culture
by Robert F.J. Seddon, honorary fellow of University of Durham
(ii) Drahos, Peter. A Philosophy of Intellectual Property. 1996, Dartmouth, pp. 67-70
(iii) “Analyzing the Legal Implications of GitHub Copilot” - FOSSA 7/14/2021https://fossa.com/blog/analyzing-legal-implications-github-copilot/