A credit-assignment lab

An agent wanders for two hundred steps and finally earns a reward. Which of those steps deserve the credit? Reinforcement learning has three classic answers. Here they are, drawn live on a world you can edit.

Tap any empty space to drop a reward for the agents drifting behind this page.

Episode 0 Ready
Credit given to each step of this episode

Four experiments

Each loads a map and settings chosen to make one idea obvious. Watch the ribbon under the grid.

Same map, same settings, six seeds each

Race all three

Trains fresh Monte Carlo, Q-learning and SARSA(λ) agents on the current map with your settings, then plots discounted return against the best any policy can do.

Not run yet
Monte Carlo Q-learning SARSA(λ) Best possible (V*)
LearnerEpisodes to 80% of bestReturn, last 20Share of best
Run the race to fill this table.