What Are AI Algorithms?

Written by Coursera Staff • Updated on

Explore the ways AI algorithms are changing our lives, from autocorrect to national security. Plus, learn about different types of artificial intelligence algorithms and how they learn.

[Featured image] A machine learning engineer works on a laptop outdoors, using AI algorithms to create insights.

Artificial intelligence algorithms instruct a computer on how to make decisions, execute a function, or perform some other task independently. These algorithms power tools we use daily, such as search engines, autocorrect, or recommendations for suggested content on a television or music streaming app.

In this article, you’ll learn about different types of AI algorithms and how they learn, along with real-life examples of how they make our lives easier and more efficient. 

Read more: How Does AI Work? Basics to Know

What are AI algorithms?

AI algorithms provide instructions for AI technology to think and react to data in ways that are intuitive to how we process information.

Artificial intelligence aims to create computers that can process information and make decisions without humans providing instructions. The AI algorithms represent all of the instructions needed to respond to the data presented to the machine. 

Read more: 10 Artificial Intelligence Examples: AI in Practice

AI algorithms vs. human intelligence

To understand how artificial intelligence algorithms work, first consider how human intelligence functions. For example, let’s say you wanted to make a fruit salad. First, you will need to go to the store to select and purchase fruit. Then, you will bring it home, wash it, and chop it as required for each kind. Lastly, you will mix it all into one big bowl. This is an example of a basic algorithm for making fruit salad. 

In that basic set of instructions, we take for granted multiple leaps of human understanding that would stump a computer almost immediately, such as the following:

  • You understand which store sells fruit.

  • You understand which objects, of all the objects at the grocery store, constitute “fruit.”

  • You understand how to wash and process each fruit individually, cutting apples differently from grapes. 

You may understand these concepts because you’ve encountered them and learned how to work within systems. Given your experience, you could travel to any town in the US and make yourself a fruit salad, even though the grocery store, streets, and fruit might all look a little different. 

Like our human thinking capability, AI algorithms are complex enough to instruct a more nuanced understanding of what the instructions mean and what possible reactions would be appropriate to the goal. You could train an algorithm to make a fruit salad by showing it many pictures of fruit and grocery stores. But it takes artificial intelligence for the computer to see a completely new image and understand whether it’s looking at a grocery store or a bus stop. 

Read more: Machine Learning vs. AI: Differences, Uses, and Benefits

What are AI algorithms used for? 

AI algorithms have applications in many different areas of life. A few situations where you may have interacted with an AI algorithm include: 

  • Search engines: Google, Bing, and Yahoo all use artificial intelligence algorithms to provide information, such as similar questions others ask. 

  • Digital assistants: When you ask Alexa, Siri, or Google to add something to your shopping list or set an alarm, you interact with AI algorithms. 

  • Autocorrect: The autocorrect on your phone or word processor might run on AI algorithms, learn from your specific behavior, and draw information from other sources, such as dictionaries. 

  • Virtual customer service: Automated customer service chatbots can respond to customers when they need help using a website or working with a product, often faster and more efficiently than a customer service agent. 

AI algorithms also have applications for industries, government operations, and even national security:

  • Advanced analytics: AI algorithms can help organizations with predictive analytics, forecasting, and business monitoring. These tools help companies understand what events are likely to happen in the future based on past events. 

  • Finance: Financial institutions use AI algorithms to power fraud detection software, which flags suspicious-looking transactions and can deny transactions that look fraudulent. AI algorithms can also evaluate a credit card application or create an investment portfolio. 

  • Health care: AI algorithms can improve health care outcomes. For example, AI algorithms can read computed tomography (CT) images to look for abnormalities much faster than a doctor can review the image. Patients can also receive more personalized care with AI algorithms, such as medication reminders. 

  • National security: AI algorithms could assist with some or many of the decisions that American commanders face. The potential for AI algorithms to change warfare as we know it is so great that the US Department of Defense has a term to describe it: hyper war. 

Read more: AI Developer Career Guide and Roadmap

Types of AI algorithms

All of the applications of AI algorithms we discussed above function because of three main categories of AI algorithms: supervised, unsupervised, and reinforcement learning. A fourth category, semi-supervised, combines elements from supervised and unsupervised learning algorithms. Together, these algorithm types make up different fields of artificial intelligence, such as machine learning and deep learning. 

1. Supervised learning

Supervised learning algorithms require people to train them using clearly labeled and categorized data. With adequate training, a supervised learning algorithm can label similar pictures without human intervention. For example, in an email account with an automatic spam folder. Spam filters use supervised learning, trained with many examples of what spam is and is not, to predict which folder you would sort the email into. Types of supervised learning algorithms include:

  • Decision tree: This is a chart with a branching shape representing all possible outcomes, with each split or node representing a different categorization test. 

  • Random forest: A random forest algorithm uses many decision trees, each testing for a different input. It makes a prediction based on the combined results of all of the decision trees.  

  • Linear regression: One of the most basic AI algorithms, a linear regression algorithm makes a prediction based on an independent variable determined by the algorithm’s operator. For example, linear regression can predict home sale prices with historical neighborhood real estate data and the individual property for sale. 

2. Unsupervised learning

Unsupervised learning is trained using uncategorized and unlabeled data. Instead of following instructions for how to categorize data, unsupervised learning looks for patterns and determines which categories and labels the data should contain. This makes it possible to analyze raw data sets and can save a lot of time. It’s also useful when the data you’re analyzing doesn’t have clear categories to fit into or when the categories are difficult to predict. Examples include:

  • K-means clustering: A K-means cluster algorithm aims to sort and categorize data. K refers to the number of groups it will sort the data into, and the algorithm returns a mean variable for each category. 

  • Gaussian mixture model: A Gaussian mixture model clusters data similar to a K-means cluster but with some extra capabilities. If you were looking at the results of a K-means cluster on a graph, each returned variable would form the middle of a circle of data. A Gaussian mixture model can organize data that graphs into more complex shapes. 

3. Semi-supervised learning

As you may have guessed by the name, semi-supervised learning uses data sets that contain some labeled and some not-labeled data. The operator-provided labels guide the algorithm in determining the best way to label the rest of the data. This method combines the accuracy of supervised learning with the benefit of less training that unsupervised learning provides. 

  • K-nearest neighbors (KNN): This AI algorithm will classify data by looking at the data closest to it on a graph and grouping data into categories by proximity. 

4. Reinforcement learning

With reinforcement learning, the algorithm can decide the best way to accomplish the task independently, learning through a complex set of rules that “reward” or “punish” the algorithm’s work. This allows for a trial-and-error approach to problem-solving. This form of AI algorithm is most appropriate when the best possible way to solve a problem isn’t clear. The computer programmers set up the rules for reward and punishment, but the algorithm decides the optimal way to work with the data set. 

  • Neural networks: Neural networks “think” like human brains, receiving and processing information through layers of patterns. Neural networks use reinforcement learning to determine the best approach to a problem. 

Learn more with Coursera.

To learn about AI algorithms, enroll today in Introduction to Artificial Intelligence (AI), a course offered by IBM on Coursera. This course takes approximately nine hours to complete and is designed to help you learn skills in artificial intelligence, data science, and machine learning. 

Keep reading

Updated on
Written by:

Editorial Team

Coursera’s editorial team is comprised of highly experienced professional editors, writers, and fact...

This content has been made available for informational purposes only. Learners are advised to conduct additional research to ensure that courses and other credentials pursued meet their personal, professional, and financial goals.