changed training data

This commit is contained in:
Nick
2019-11-15 18:42:28 -07:00
parent dac9605ada
commit e431de8e34
2 changed files with 939 additions and 933 deletions
+9 -3
View File
@@ -31,14 +31,20 @@ def get_stories(filename):
return stories
output_file_path = "text_adventures.csv"
output_file_path = "text_adventures.txt"
with open(output_file_path, 'w') as output_file:
writer = csv.writer(output_file, delimiter=',', quotechar='"', quoting=csv.QUOTE_MINIMAL)
filenames = ["story0.json"]
stories = []
for filename in filenames:
stories += get_stories(filename)
raw_text = ""
start_token = "<|startoftext|>"
end_token = "<|endoftext|>"
for story in stories:
writer.writerow([story])
raw_text += start_token + story + end_token + "\n"
output_file.write(raw_text)
File diff suppressed because it is too large Load Diff