This commit is contained in:
nickwalton
2019-10-30 17:53:48 -06:00
parent c4598e5b45
commit 9c1c1c5b3d
2 changed files with 2 additions and 3 deletions
+2 -1
View File
@@ -169,6 +169,7 @@ class CTRLGenerator():
# print("\n\nBEFORE RESULT_REPLACE:")
# print(repr(result))
result = cut_trailing_sentence(result)
first_letter_capitalized = result[0].isupper()
result = result.replace('."', '".')
result = result.replace("#", "")
@@ -274,7 +275,7 @@ class CTRLGenerator():
def generate(self, prompt, options=None):
prompt = self.prompt_replace(prompt)
debug_print = False
debug_print = True
if debug_print:
print("\n\n*****DEBUG*****")
-2
View File
@@ -102,7 +102,6 @@ class UnconstrainedStoryManager(StoryManager):
def generate_result(self, action):
block = self.generator.generate(self.story_context() + action)
block = cut_trailing_sentence(block)
return block
@@ -199,7 +198,6 @@ class ConstrainedStoryManager(StoryManager):
def generate_action_result(self, prompt, phrase, options=None):
action = phrase + " " + self.generator.generate(prompt + " " + phrase, options)
action_result = cut_trailing_sentence(action)
action, result = split_first_sentence(action_result)
return action, result