To learn from experience, a reinforcement learning (RL) agent needs four key elements:
State: What situation is the agent in?
Actions: What are the possible moves from here?
Reward: What does the agent receive after an action?
Value function: How good is a state (or action), both now and in the future?
This is the foundation of how an RL agent learns to make better decisions over time.