def METHOD_NAME(self, state):
    """
    Given a state, choose the next item at random.
    """
    if state == tuple([ BEGIN ] * self.state_size):
        choices = self.begin_choices
        cumdist = self.begin_cumdist
    else:
        choices, weights = zip(*self.model[state].items())
        cumdist = list(accumulate(weights))
    r = random.random() * cumdist[-1]
    selection = choices[bisect.bisect(cumdist, r)]
    return selection