Q-learning & SARSA
Step 6 of 10 in Reinforcement Learning · Build · Medium
Learn the value of each action in each state. Q-learning learns the optimal policy while exploring (off-policy); SARSA learns the policy it follows (on-policy).
Build it
Cliff walking
Q-learning vs SARSA on cliff walking; plot the paths each learns.
Done when: Q-learning hugs the cliff, SARSA takes the safe path; you explain why.
Resources
- Wikipedia: Q-learning Article
- Sutton & Barto (free book) Book
- OpenAI Spinning Up Course
Earn this star
On the map, you log what you built. Finish the step and its star lights.
Open this step on the map