# What is the difference between policy and action in reinforcement learning?

I'm confused with the two terminology - action and policy - in Reinforcement Learning. As far as I know, the action is:

It is what the agent makes in a given state.

However, the book I'm reading now (Hands-On Reinforcement Learning with Python) writes the following to explain policy:

we defined the entity that tells us what to do in every state as policy.

Now, I feel that the policy is the same as the action. So what is the difference between the two, and how can I use them apart correctly?

• @Blaszard Correct. Suppose epsilon = 0.1, and you have 2 actions. There is an 0.9 probability of greedily selecting the best action (or choosing randomly among multiple "equally best" actions), and an 0.1 probability of selecting uniformly at random. In that second case, there is again an 0.5 probability of selecting the best action, and 0.5 probability of selecting the worst (for 2 actions). Mathematically, that can be summarized as a total probability of 0.95 for best action, and 0.05 for worst action. – Dennis Soemers Aug 1 '18 at 20:10