Cover photo

Machine Learning in 3 Minutes

Machine Learning (ML) is a subset of artificial intelligence that involves teaching machines how to learn from data and improve their performance over time. Machines can much more quickly identify patterns in data than a human, and that’s what machine learning is all about, identifying patterns.

There are three main types: supervised learning, unsupervised learning, and reinforcement learning.

Supervised Learning

In supervised learning, machines learn from labeled data. That means we feed the algorithm a dataset with input-output pairs, and the algorithm learns to map the inputs to the correct outputs. Once trained, the algorithm can take a new set of inputs and predict the corresponding outputs.

An example of this would be a system that identifies and flags emails as spam. The machine learning algorithm learns to identify patterns associated with spam emails such as certain keywords, the email’s format, the sender’s email address, etc. After training the model can analyze new, never seen emails and predict if it’s spam or not.

The input-output pairs for this would look like:

Input:

  • Subject: “Claim Your Free Bitcoin”

  • Body: “You have a free Bitcoin waiting for you. Click here to connect your wallet.”

  • Sender: spammer@example.com

  • Recipient: yourname@gmail.com

Output: 1 (spam)

Input:

Output: 0 (not spam)

Unsupervised Learning

Unsupervised learning involves training machines on data where the output is unknown. The algorithm’s job is to find underlying patterns or structures in the data.

Netflix recommendation system is a good example of unsupervised learning, and while Netflix system is far more sophisticated than this example, this serves as a good baseline understanding. Netflix utilizes unsupervised learning to analyze user data such as: viewing history, ratings, and engagement signals to identify patterns and similarities among users and the movies they watch to create user clusters or segments.

Input:

  • User A: Watched “Stranger Things,” rated it 5 stars

  • User B: Watched “Narcos” and “Breaking Bad,” rated them 4 stars

  • User C: Watched “The Crown” and “Downton Abbey,” rated them 5 stars

Output: User Clusters

  • Cluster 1: Users like sci-fi and thriller genres

  • Cluster 2: Users like crime and drama genres

  • Cluster 3: Users like historical and period dramas

Through clusters the Netflix recommendation system can predict a user’s preferences based on the movies watched and rated by other users in the same cluster. For example:

Input:

  • User D: Watched “Black Mirror”

Output: Recommendation

  • Recommend “Stranger Things” (based on Cluster 1’s preferences)

The more a user interacts with the platform and generated more data, the system will continually update and refine the clusters, enhancing the accuracy of its recommendations and hopefully preventing this 👇 scenario.

Reinforcement Learning

Reinforcement learning is a bit different. It involves an agent learning to make decisions by interacting with its environment. The agent takes actions, gets feedback, and uses that feedback to make better decisions over time.

When applied to chess, the agent (AI player) interacts with the chessboard, receives rewards or penalties based on its moves, and adjusts its strategies to improve its gameplay over time.

Input:

  • Chessboard State: The current state of the chessboard, including the positions of the pieces.

  • AI Player’s Turn: Whether it’s the AI player’s turn to move or the opponent’s turn.

Output:

  • Selected Move: The move chosen by the AI player based on the current state and its learned policy.

Throughout the training process, the AI player uses reinforcement learning algorithms to evaluate positions, search for optimal moves, and update its policy based on rewards obtained during gameplay.

Loading...
highlight
Collect this post to permanently own it.
Mercer AI logo
Subscribe to Mercer AI and never miss a post.
#machine learning#deep learning#ai#artificial intelligence