refactor(core): revise Algorithm interface
refactor(core): revise Algorithm interface

* Rename Algorithm::handle_sample -> Algorithm::handle_transition.
* Change argument type for Algorithm::handle_terminal from a Transition
  to state S.
* Update BatchAlgorithm to reflect the changes.

tspooner/rsrl