How Does AI Actually Work?

AI, as the public generally sees it, does not actually exist. There is no robot sitting behind our screens that makes decisions on its own. It’s all about training an algorithm in a process commonly known as machine learning. This is done through large datasets. The internet is the biggest dataset available to us and has allowed AI such as ChatGPT to exist. To take an example, the famous YouTube algorithm is constantly learning by picking up on trends and what kind of content is worth pushing to the top of the list.

How Does AI Learn?

For AI to learn, you need machine learning models. There are many of these, and they all work in unique ways. To name a few, there are “decision trees”, “linear regression” and “random forests”. Regardless of the model, an algorithm will start by guessing and will progressively become more accurate as more guesses are made. With that being said, you cannot just leave an algorithm guessing because what is going to tell that algorithm a guess is a ‘bad’ guess?

Berkeley describes machine learning as a process split down into three steps:

  • A decision process: how the algorithm takes a given data set and makes a guess as to what the pattern is.
  • An error function: how to measure the success of the decision process. Did the algorithm get it correct, or how much did the guess miss?
  • An updating or optimisation process: this is where the decision process is changed to then make the next guesses in the future better.

This process mirrors how humans learn. We try to solve a problem, and our mistakes are identified, either through self-assessment or feedback from others. We then revisit our approach and adjust it to improve. For example, when children first learn mathematics, they rarely get the answers right on their initial attempts. Instead, they go through a cycle of reviewing and correcting their errors as part of the learning process.

What Are the Types of Learning?

Supervised Learning:

IBM describes this as training sets that “teach models to yield the desired output.” The training set includes inputs and the correct outputs. The algorithm measures its accuracy through the loss function and adjusts until the error has been minimised successfully. You can think of this as having a teacher who knows the correct answers—you’re working towards matching those answers, and the teacher can tell you if you’re right or wrong.

Unsupervised Learning:

Unsupervised learning is more complex but highly useful as it can identify patterns without human guidance. To give you an overview, the algorithm uses a technique called clustering, where unlabelled data is grouped based on similarities. Once grouped, patterns within the data become apparent.

Semi-supervised Learning:

This is exactly how it sounds. It combines both supervised and unsupervised learning together. As described by Altexsoft, this is a learning technique that “uses a small portion of labelled data and lots of unlabelled data to train a predictive model.”.

Reinforcement Learning:

For reinforcement learning to work, it uses trial and error and relies heavily on feedback. As explained by the University of York, “The feedback is either negative or positive, signalled as punishment or reward with, of course, the aim of maximising the reward function.”.

Conclusion

The development of AI is a very complex topic, and we have only scratched the surface here. It’s impossible to tell where the future will lead us with AI, but at the moment, we are quite far from having our own Skynet. There are complicated arithmetic and logical algorithms that work in cohesion with very large data sets to give us useful answers to our questions or to generate something new.