Coder Social home page Coder Social logo

pali-nimi's Introduction

pali nimi

a tool to generate names

generate names based on toki pona's phonotactics
can be used to help name characters, worlds, pets, etc

instalation

this python script was made using python 3.10
might work on other python3 versions as well

to install, simply clone this repository:

git clone https://github.com/ShyPiano/pali-nimi.git

usage

in the repository's directory, run the following command:

python3 palinimi.py 2 3

this will print out all possible valid toki pona names with 2 to 3 syllables

you can pick the minimum and maximum number of syllables, but large numbers will take a long time to generate due to the exponential growth of possible syllable permutations
and long names probably aren't too good anyway

you can optionally exclude toki pona vocabulary, restrict words to match a regex, and set how often words are randomly dropped
doing this will constrain the amount of words outputted to more manageable numbers
learn how by viewing the help message:

python3 palinimi.py -h

you can also use this as a module for other python scripts

import palinimi

contributing

feel free to
just fork the repository, make your changes in a new branch, commit and make a pull request

License

pali nimi is licensed under the mit license

pali-nimi's People

Contributors

shypiano avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

pali-nimi's Issues

yield_tok_words doesn't yield words in alphabetical order

Despite claiming to do so, the function yield_tok_words doesn't correctly return words in alphabetical order
Take this example (some output omitted for brevity):

>>> list(yield_tok_words(2))
[(...) 'ana', 'anan', 'ane', 'anen', 'ani', 'anin', 'ano', 'anon', 'anu', 'anun', 'apa', (...) 'anja', 'anjan', 'anje', 'anjen', 'anjo', 'anjon', 'anju', 'anjun', (...)]

Note that the words starting with "anj" should come before "ano".

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.