added list of intact words and changed capitalisation rules
This commit is contained in:
parent
3272d367b9
commit
d3e6b954fe
5
api.py
5
api.py
@ -50,6 +50,8 @@ def build_word_dict():
|
||||
for y in range(len(current)):
|
||||
charNeeded = current[y]
|
||||
for item in wordList:
|
||||
if item not in intact:
|
||||
item = item.lower()
|
||||
if (len(item)-1) >= y:
|
||||
addKey = str(y) + item[y]
|
||||
if addKey not in toChooseFrom.keys():
|
||||
@ -185,8 +187,11 @@ def api_args():
|
||||
testKey = str(y) + current[y]
|
||||
# print(current[y],random.choice(toChooseFrom[testKey]))
|
||||
api_phrase.append(random.choice(toChooseFrom[testKey]))
|
||||
api_phrase[0] = api_phrase[0].capitalize()
|
||||
api_phrase_str_word = ' '.join(api_phrase)
|
||||
print('api_phrase_str_word: ',api_phrase_str_word)
|
||||
api_phrase_str = api_phrase_str + '\\n' + api_phrase_str_word
|
||||
print('api_phrase_str: ',api_phrase_str)
|
||||
api_phrase_str_word = ''
|
||||
api_phrase_str = api_phrase_str[2:]
|
||||
|
||||
|
1
intact_words.py
Normal file
1
intact_words.py
Normal file
@ -0,0 +1 @@
|
||||
intact = ["Black","Indigenous"]
|
BIN
queermottoapi.db
BIN
queermottoapi.db
Binary file not shown.
Loading…
Reference in New Issue
Block a user