Blog #18

Machine Learning

 1 Dec 2019

Machine learning (ML) has been gaining popularity in recent years, articles are shared online daily, software vendors and service providers have begun to offer Machine Learning as-a-service and you will no doubt have heard about self-driving cars.

In this post, I run through what ML is, the types of ML that are available and touch on some real-world applications.


First, a definition. Simply put, machine learning is a type of artificial intelligence.

Software applications are normally programmed by a human using a high-level language such as C#. The machine then follows these rules and behaves in a predictable manner.

Machine learning is a departure from this relatively static paradigm to a more dynamic model whereby the machine can learn without being programmed by a human and make decisions by itself.

How Does it Work?

For the machine to be able to make independent decisions, it must be supplied with training data.

The machine effectively mines the training data and applies one or more algorithms to identify patterns. These patterns can then be used to adjust the behaviour of software or business processes automatically for new incoming data - this may involve arriving at financial predictions or placing text into specific categories.

This flavour of machine learning is called Supervised Learning and brings us onto the types of machine learning.

Types Of Learning

Supervised learning

A supervised learning algorithm analyzes the training data and produces an inferred function, which can be used for mapping new examples. An optimal scenario will allow for the algorithm to correctly determine the class labels for unseen instances.

Unsupervised learning

Unsupervised machine learning is the machine learning task of inferring a function to describe hidden structure from "unlabeled" data (a classification or categorization is not included in the observations).

Since the examples given to the learner are unlabeled, there is no evaluation of the accuracy of the structure that is output by the relevant algorithm—which is one way of distinguishing unsupervised learning from supervised learning and reinforcement learning.

Real World Applications

Consider the following example:

You have an application that accepts support tickets online and you want to identify which type of category each support ticket belongs to. Based on previous experience, the support team have found that users are repeatedly selecting wrong ticket categories which is adding time to the investigation process.

The support team would like the machine to determine the actual ticket category by parsing the ticket narrative supplied by the user before it is passed onto them, thereby saving them time.

How can machine learning help with this?

This is ultimately a text classification problem which is a form of Supervised Learning. I studied this form of machine learning during a Masters degree a few years ago and subsequently built software that performed sentiment analysis against Twitter data with this approach.

It determined if people were expressing positive or negative emotion in their tweets and subsequently sent email notifications.

The support ticket example we are discussing is no different.

By supplying a classifier examples of historical tickets (the training data)that reflected specific categories, the machine can then attempt to classify incoming support tickets as belonging to the “email server” or “web server” categories.

A solution like this would give out fictitious support team the solution they require.

In terms of the underlying algorithm behind the classifier, Bayesian Theorem in one that generates relatively accurate results.  I cover that in detail in another blog post if you’re interested.

Other examples

Some other examples of real-world examples of machine learning include, but are not limited to are:

  • Recommendation engines (Netflix and Amazon)
  • Finance and fraud detection
  • Speech recognition
  • Email spam filtering
  • Real-time ads on web pages and mobile devices
  • Pattern and image recognition

Microsoft Cognitive Services

Via their Cognitive Services platform, Microsoft offer machine learning algorithms and APIs “as a service”.  This shields you from complex algorithms and makes it easy to integrate tried and tested algorithms into your existing stack using REST endpoints - no PhD required!


In this post, we’ve ran over machine learning at a very high level, in the next post, I’ll explore Microsoft Cognitive Services, what's on offer and what you can do with it.


Currently there are no comments. Be the first to post one!

Post Comment