Suppose you decide to teach a dog a new trick, say “fetch the ball”. When the dog brings the ball back, he gets a treat (a positive reward). When he starts chewing a shoe instead, he gets nothing, or you scold him mildly (negative feedback). Gradually the dog works out for himself which behaviour leads to a reward and starts repeating it more often. Reinforcement learning works on the same principle. An artificial intelligence (the agent) tries various actions in its digital world and receives points for each one – positive for success, negative for failure. In this way it learns for itself, by trial and error, which strategy is best for reaching the goal.
Reinforcement learning is the area of machine learning concerned with how a software agent should behave in a given environment in order to maximise cumulative reward. The model is not trained on labelled data; it learns through interaction by trial and error. The agent performs actions in an environment, which then moves to a new state and provides the agent with a reward or a penalty. The agent’s goal is to learn an optimal policy, that is, a mapping from states to actions leading to the highest total reward over the long run. This approach is key to solving problems involving dynamic decision-making, such as playing games, controlling robots or optimising logistics processes.