Markov: actually use the working backwards results
thinko, there were code paths where the working backwards results were discarded. don't discard them.
This commit is contained in:
parent
0b6d5e3f44
commit
5d90c98fb2
|
@ -397,8 +397,6 @@ class Markov(Module):
|
|||
back_k2 = self._retrieve_random_k2_for_value(working_backwards[0], context_id)
|
||||
if back_k2 == self.start2:
|
||||
self.log.debug("random further back was start2, finishing")
|
||||
gen_words += working_backwards
|
||||
self.log.debug("gen_words: {0:s}".format(" ".join(gen_words)))
|
||||
break
|
||||
elif back_k2:
|
||||
working_backwards.insert(0, back_k2)
|
||||
|
@ -406,10 +404,10 @@ class Markov(Module):
|
|||
self.log.debug("working_backwards: {0:s}".format(" ".join(working_backwards)))
|
||||
else:
|
||||
self.log.debug("nothing (at all!?) further back, finishing")
|
||||
gen_words += working_backwards
|
||||
self.log.debug("gen_words: {0:s}".format(" ".join(gen_words)))
|
||||
break
|
||||
|
||||
gen_words += working_backwards
|
||||
self.log.debug("gen_words: {0:s}".format(" ".join(gen_words)))
|
||||
else:
|
||||
# work forwards
|
||||
self.log.debug("looking forwards")
|
||||
|
|
Loading…
Reference in New Issue