Agents & Environments

Reinforcement Learning

A glimpse of Agents & Environments

Put a player at position 0, the left end of a corridor with positions 0, 1, 2 and 3. It can move left or right. Reaching position 3 ends the game and gives +5 reward. Every other move gives −1.

The agent chooses the move. The environment applies the corridor's rules and returns what happened. A policy is the rule the agent uses to choose actions. “Always move right” is already a policy, even though it has not learned anything.

Continue learning

Pro unlocks guided learning, complete notes, practical walkthroughs, exercises, and every AI Research lesson.