System names generation - Italian variant
Posted: Mon Aug 17, 2020 8:03 am
Dear All, as promised on github I will briefly summarize what I did and what could be done codewise to get some Italian-sounding system names, if you think this could be ok with the current name generation.
I tried a few approaches dividing city names into segments, but I found out that some specific order, and a largish library (~300 syllables) would be nice to have to get sensible results.
The current implementation uses three sets of syllables, which I got taking the about 13k Italian cities and town names and syllabifying it, after cleaning up some specific features of Italian names.
The results is three distinct sets of syllables, of about 100-150 syllables each: then one would run an RNG to pick syllables, as follows: pick one from the "starting" syllable, then zero, one or two "middle" syllables, and one last from the "ending syllable" set.
This implementation has still some round edges because it generates some sequences of syllables that, while grammatically plausible, are uncommon in Italian lexicon. However they might become more common in the next 1200 years ;-)
The system could also be further improved by adding, maybe with a small percentage (say 5%), either a prefix or suffix to the name. Typically in Italy we have prefix such as "mount-name", "valley-name", "church-name", "castle-name", ect; or suffix based on other geographical references: "name-high", "name-low", "name-old", "name-new", "name-seaside" etc. Finally, a fairly common instance is a prefix that uses a name of a Saint before the town name, like "Saint-saintname-townname".
If you think it would fit the style I could try to test out the first two extra features, but would avoid adding in the third to avoid any religious reference in the game.
I am attaching here the three syllables files and a python3 script (in a zip file) to generate names so you can get a feeling of how it works. I have no idea if this uses too much memory or processing power, so feel free to comment on it and tell me if I should work further on it. Just run the script with python3 in the same folder of the three text files.
As always thank you for your time and effort.
https://www.dropbox.com/s/o6vuisdwb72q9 ... s.zip?dl=0
I tried a few approaches dividing city names into segments, but I found out that some specific order, and a largish library (~300 syllables) would be nice to have to get sensible results.
The current implementation uses three sets of syllables, which I got taking the about 13k Italian cities and town names and syllabifying it, after cleaning up some specific features of Italian names.
The results is three distinct sets of syllables, of about 100-150 syllables each: then one would run an RNG to pick syllables, as follows: pick one from the "starting" syllable, then zero, one or two "middle" syllables, and one last from the "ending syllable" set.
This implementation has still some round edges because it generates some sequences of syllables that, while grammatically plausible, are uncommon in Italian lexicon. However they might become more common in the next 1200 years ;-)
The system could also be further improved by adding, maybe with a small percentage (say 5%), either a prefix or suffix to the name. Typically in Italy we have prefix such as "mount-name", "valley-name", "church-name", "castle-name", ect; or suffix based on other geographical references: "name-high", "name-low", "name-old", "name-new", "name-seaside" etc. Finally, a fairly common instance is a prefix that uses a name of a Saint before the town name, like "Saint-saintname-townname".
If you think it would fit the style I could try to test out the first two extra features, but would avoid adding in the third to avoid any religious reference in the game.
I am attaching here the three syllables files and a python3 script (in a zip file) to generate names so you can get a feeling of how it works. I have no idea if this uses too much memory or processing power, so feel free to comment on it and tell me if I should work further on it. Just run the script with python3 in the same folder of the three text files.
As always thank you for your time and effort.
https://www.dropbox.com/s/o6vuisdwb72q9 ... s.zip?dl=0