This commit is contained in:
Auric Vente
2024-07-25 21:50:36 -06:00
parent 962f59d794
commit 1dc4cb8b78
2 changed files with 8 additions and 4 deletions

View File

@@ -173,12 +173,16 @@ class Utils:
return ""
word = Utils.rand_word.word(include_parts_of_speech=opts, word_max_length=8)
return str(word)
@staticmethod
def random_words(num: int = 1) -> list[str]:
return [Utils.random_word() for _ in range(num)]
def random_words(num: int = 1, noun: bool = True, adj: bool = True) -> list[str]:
return [
Utils.random_word(
noun=noun,
)
for _ in range(num)
]
@staticmethod
def capitalize(word: str) -> str: