Returns, Value & Policy

greedy policy

A greedy policy takes the current best guess at face value: in each state it picks the action that its value estimates say is best, right now, with no thought for exploring alternatives. If your Q-values claim action a has the highest payoff in this state, the greedy policy plays a, every time. It is the cash-it-in rule: exploit what you think you know.

It is defined by choosing, in each state, the action that maximizes Q. Greedy behaviour is exactly what you want once your value estimates are accurate, and acting greedily on the optimal Q gives an optimal policy. The danger comes earlier, during learning: being greedy on still-shaky estimates can lock the agent into a mediocre habit, never sampling the action that was actually best. That is why methods often soften it into epsilon-greedy, taking the greedy action most of the time but a random one occasionally.

\pi(s)=\arg\max_{a}Q(s,a)

The greedy policy always selects the highest-valued action under the current estimates.

Also called
argmax policygreedy action selection