I found a duplicate at index "46.037.812" of 100.000.000, my idea is to at least get…
- User
I found a duplicate at index "46.037.812" of 100.000.000, my idea is to at least get 100.000.000 names without duplicates. Should I add more syllables or something? The syllables I have are for spanish-like names
Also took 893.90 seconds., which is ALOT! is there a way to improve this, maybe by parallel running the three parts of a name or something?
- Assistant
- User
sorry the code got cut out, here is my current code:
import random import string
def generate_dynamic_full_name(seed): # Syllables for first names first_syllables = ["al", "bo", "cha", "da", "el", "fer", "gar", "jua", "lu", "ma", "pe", "ra", "san", "to", "vi"]
code# Syllables for last names last_syllables = ["son", "sen", "man", "berg", "stein", "ez", "go", "la", "na", "ro", "va", "z", "do", "ga", "ri"] random.seed(seed) # Generate first name first_name = ''.join(random.choices(first_syllables, k=random.randint(2, 4))).capitalize() first_name += ''.join(random.choices(string.ascii_lowercase, k=random.randint(2, 4))) middle_name = "" if (random.choice([True, False])): middle_name = ''.join(random.choices(first_syllables, k=random.randint(2, 3))).capitalize() middle_name += ''.join(random.choices(string.ascii_lowercase, k=random.randint(2, 4))) # Generate last name last_name = ''.join(random.choices(last_syllables, k=random.randint(2, 4))).capitalize() last_name += ''.join(random.choices(string.ascii_lowercase, k=random.randint(2, 4))) return f"{first_name}{f" {middle_name} " if middle_name else " "}{last_name}" - Assistant
- User
no sorry, my idea is to be generating names on the fly not to add X amount, that is just a test to check when it fails
- Assistant
- User
I need more syllables, spanish-like names, I want to add a few more to make it more diverse, what can I add both for names and last names?
- Assistant
Certainly! To create a wider variety of Spanish-like names, we can expand both the first name and last name syllable lists. Here are some additional syllables you can consider adding:
Additional Syllables for First Names:
-
Syllables:
- "an"
- "ar"
- "el"
- "li"
- "ma"
- "na"
- "sa"
-
- User
no, in last names you place an entire word as syllables
- Assistant