Extract Script in separate module.
Script should be opaque "Monad" to user.