Tuesday, March 2, 2021

What is Artificial Intelligence (AI)? - How AI works

Throughout this article we'll  aim to explain - first, what is artificial intelligence? Secondly, how does AI work? So, what is artificial intelligence you  ask? In 1956, John McCarthy the man who coined the term AI defined it to be the science  and engineering of making intelligent machines. 

Simply it's a science of making smart machines  that will eventually think like humans do. In movies, these are typically depicted  as robots who will destroy the world. Now, artificial intelligence is used in our  everyday lives and also is much broader than that.

Like when you asked your  phone to call your mother, or when youtube helped you find this  very video. Great choice by the way! To properly understand what artificial intelligence can achieve we probably   want to know what we even mean by human intelligence. There's a lot to human intelligence and we define it in five components that frame the goals we have as AI is developed.

First, the ability to learn and improve. Second, the ability to adapt in new environments and situations. Even though we may never have walked down a specific path we know how to adapt to it and walk through it without having experienced it before. Third, the ability to react to surroundings. For example, when we drive down a road and a person appears we know to stop the car. 

Fourth, the ability to solve problems. For example, figuring out the solution to a puzzle. Finally, the fifth component is understanding language. As humans we communicate through language and are also able to understand context. For example if someone says I ate a date today. We understand that we mean the fruit (date) was eaten not a person.

Machines can do some of these sometimes better than humans. For example, when AlphaGo beat the  world champion at the game of go. The game that has more combinations than atoms in the universe. But in terms of AI being used and developed right now - there's a large range going from what is called strong AI also known as artificial general intelligence (AGI) to weak AI. Strong AI is intelligence at its general meaning it can do many things like humans. Such as solve many different types of problems in many different situations.

Weak AI are machines and algorithms that can solve one specific problem very well but won't deal very well with being thrown a new problem in a new context. Currently artificial general intelligence has not yet been achieved but is a constant subject of research. So how does AI really work?

To be able to perform these many tasks and learn the artificial intelligence requires: information (inputs) as well as outputs such as predictions or decisions. Inputs can come from numbers, for example, age or height in a scientific experiment all collected in a spreadsheet or text in tweets or online reviews images and videos and audio. The analysis of text refers to the field of natural language processing in data science, images is computer vision and audio is speech recognition. 

We won't go into how these work specifically in this article however if you're interested check out the related articles in the links. Once we have inputs we want to be able to use them to result in outputs such as a prediction for example: What netflix shows should we recommend for this user? or decisions such as stopping a self-driving car when it sees a pedestrian crossing the road. One field that focuses on creating models to make predictions or decisions through AI is called machine learning.

Machine learning is the use of algorithms or models to analyze and learn from large amounts of data without explicitly being told how. Three key ways that we can teach a machine to learn are: supervised, unsupervised and reinforcement. Supervised learning is where you provide the data with the answers to the questions you're after to later make predictions on new or future data. For example you may want to predict whether it will or won't rain in the future. You've already collected information on temperature and humidity levels as well as whether it rained or not then, you let your machine learn from this and predict rain for future days.

In unsupervised learning you don't have the specific answer to your question in your data. Unlike in supervised learning this approach is used to group items together for example the items on amazon under what items do other customers buy after viewing this item or an anomaly detection for example finding abnormal bank transactions. The bank will not be provided information or whether the transaction was fraudulent or not. However, with the information they have they're able to
detect whether something seems unusual. 

Finally, there's reinforcement learning where you let the machine harness the power of trial and error you give it a reward if it does something correctly and a punishment when it doesn't.

To summarise AI is a way in which we can make machines intelligent. To enable these machines to understand the world they require inputs such as numbers audio video or other data. This enables machines to provide us with outputs such as decisions or predictions.