HomeJavaModsLibVilNam
LibVilNam
ModsJava

LibVilNam

by Guzio · on Modrinth

Cross-mod village name generation compatibility library. „Welcome to [YOUR VILLAGE NAME HERE], village-chief-sama! UwU”

⬇ Download on Modrinth

LibVilNam

Cross-mod village name generation compatibility library.

Welcome to [YOUR VILLAGE NAME HERE], village-chief-sama! UwU

What in the alphabet-soup am I looking at?

VibVilNam is a village names library (that's actually just its name, except it's written in the Linux naming convention, so everything is shortened to 3 characters max, and „Library” goes first not last - just like „C Library” becomes „LibC”), that any other mod can use to attach names to villages in a cross-compatible way.

And what the hell does that mean?

Imagine you have one mod that places some kind of transportation markers in villages (maybe the transportation method is walking and the marker is a minimap waypoint; maybe it's a waystone mod; maybe it's a train station attached to a procedurally generated network) and another mod that welcomes you when you enter a village (maybe something like Traveller's Titles, but for villages; maybe something sign-based). Now, wouldn't it be oh' so nice if the mod said „Welcome to (village X)!” and then the transportation marker was also called „(village X)”? Unfortunately, this isn't possible today.

...Unless the mod integrates with LibVilNam! That's right! Tired of multiple mods giving conflicting village names, when running large enough modpacks? We're here to the rescue! LVN provides a library that other mod authors can hook into to make their village names consistent with all other mods that also support LibVilNam (see list below). In some cases, the mods themselves may not even have to support LVN directly, as we have an as-of-yet-short (but steadily growing) list of official integrations with popular mods, for which we maintain support inside LibVilNam itself.

Do you only have a single village-naming mod? LibVilName can be useful, too! Most name-generating mods just blindly toss together an adjective/noun and a city-like word, and form a name from them (for example, Sunnyvale, Steamtown, Icetopia, etc.). This is fine, but it quickly gets repetitive and boring. LVN uses a different technique, called a Markov Chain, which is kinda like a small LLM (well, if it's small, then that's no longer a Large Language Model, but you get the idea). It trains its understanding on how a given language connects its syllables in a provided dataset (see Configuring LibVilNam below on how to provide it) and then tries to extrapolate from there. All this means that you get much more realistic-sounding and unique names, and you also have a lot of control over the style of generated names (just use a different training dataset), letting you fairly easily change eg. languages or even go back to those old repetitive names (if you liked them, for some reason). [ Note, that Markov Chains don't support any fancy LLM optimization concepts like Attention (which sits at the core of every modern chatbot), which theoretically makes them less memory-efficient than an LLM (if one was to use a Markov Chain to generate a full paragraph, they'd need exabytes of RAM), but they need very little memory overhead (your dataset itself kinda is the model - no need to load tens of GBs of model weights into a GPU), which in practice makes them far better than LLMs for generating short one-word sequences (like a village name) - thanks to this, LVN runs fully locally on your CPU, and you don't need to (can't, actually) put any AIslop-API tokens anywhere. ]

Download

Supported mods

Below is the list of supported mods. If a mod is marked as [AUTO], no extra config will be needed, and it picks up LibVilNam (or LibVilNam (or 3rd-party integrator) picks it up) automatically.

1st-party support

These are the mods that use LibVilNam directly, either by relying on it as a direct dependency or as an extra possible integration:

Nothing here yet! Built a mod with LibVilNam support? Please open a pull request to this file, we'd love to showcase you as our first consumer!

2nd-party support

LibVilNam itself integrates with those mods via Mixins:

3rd-party support

The following mods offer integration between LibVilNam and some other mods:

Nothing here yet! Built a mod with LibVilNam support? Please open a pull request to this file, we'd love to showcase you as our first consumer!

Usage - For regular players

Most basic usage of LibVilNam is laughably simple. For most mods (those marked as [AUTO] above), all you need is to install LVN and the chosen mod, and you can enjoy shared village names between mods. Sometimes, you may need to install an extra mod (those in the 3rd-party support list above) to bridge the gap, or to change some config value to explicitly enable LVN support (if there is no [AUTO] marking). That's mod-specific, so it's not documented here.

For advanced use, however, see below:

Configuring LibVilNam

LibVilNam's config file depends on your modding platform. On Forge, you'll find it at ~/.minecraft/config/lvn-common.toml and for Fabric, it's ~/.minecraft/config/lvn.properties (Linux client via the official Minecraft launcher for both - adjust for your OS, client/server situation, and launcher yourself). Wherever your file is, it will contain the following keys:

Picking a dataset

By default, LibVilNam trains its Markov Chain on this dataset. It's a hand-curated list of over four thousand various Polish geographical place-names (villages, cities, wojweództwos, gminas, and powiats - and some words may be parts of street-names, too, because of how the data was obtained). We decided to go this route, instead of training it on eg. American or British places, because:

...in theory. In practice, we understand that some players may not want to deal with having to pronounce „Sokołobrychodnorostrów” (*real name produced by our generator during development). For that reason, we offer the ability to change how the generator works by using a different dataset. The exact instructions for doing that are above, here I'd like to instead focus on obtaining it. In general, you have 2 routes: either you download a database from your local government and try to massage the data yourself (unless your gov't provides more useful stuff than ours), or you head over to SamCodes Markov, press Settings, set Length Range 3-23 + Order 3 + Prior 0.00 + Backoff 0 (that's the params used by LibVilNam), and start messing around with pre-made datasets until you find one that generates names that look like something you might want to use. If you need a starting point, we found that their „Currencies” dataset produces some interesting results, that look great as some sort of non-descript fantasy language (at least if you assume that „Mark” means city/town/village/etc. in that language, as that suffix seems somewhat common).

In-game commands

World files

LibVilNam persists its village names between restarts in ~/.minecraft/saves/[world name]/lvn/[dimension namespace]/[dimension id].csv. For example, for villages located in the minecraft:overworld dimension of the „My Forever World” world, the path will be: ~/.minecraft/saves/My Forever World/lvn/minecraft/overworld.csv.

Usage - For consumers

There is no developer guide or community yet. All I can say is use Modrinth Maven to add a dependency, and then check out our public API on on GitHub to figure out how to interact with it (it's really simple, I promise). An instance of the API can be obtained via hub.guzio.lvn.internal.Main.i().getAPI() (that's the 1st and last time one should ever interact with the internal package, as everything else there is highly platform- and version-dependent - meanwhile, public methods in hub.guzio.lvn.API (except for its constructor) and hub.guzio.lvn.Village are guaranteed to follow SemVer).

License

Words of encouragement

*If you happen to have more of an idea than I did, and also managed to realize said idea (or would just like to humanize the current realization of NanoBannana's „idea” - cuz tbh it pulled-off quite a nice design overall (with the Markov literal-Chain and a sort of emblem-style design), it's just laughably in cohesive (2 out of the 3 generated name examples on the sign are explicitly not the kind of name generation this mod does; the chain is contorted into an abomination; the book looks nothing like Minecraft) and soulles), a pull request with your logo would be hugely welcome! Even more-so if you release the artwork under CraftLDAP-style logo-licensing mentality, ie. license it under CC BY-NC-ND 4.0 with the willingness to lower the requirements for good-faith derivative works (one of which would have to be LibVilNam itself, otherwise I'd literally be legally unable to use it) or something more permissive than this (I just would prefer to avoid stuff that don't allow for derivatives (though any contribution is appreciated and I'm sure an arrangement can be worked out), as I think that goes against the spirit of any creative works - there is a reason why I publish everything under MIT).

That's all!

Hope you enjoy this silly little project :3

Quick facts

Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.

Verified by MCModsHub

These come from our own check of the pack file, not from the source page.

Explore more