Dead simple package for generating random Phrases
Project description
Phrasegen: Little package for making phrases
Phrasegen is a package that can help you generate variable sized Random phrases.
We use word lists from one of the Trezor projects, thus, support multiple languages.
Installation
From PyPI
# Install the latest version with pip
pip install phrasegen
You can also Clone and install:
git clone https://github.com/NotStatilko/phrasegen
pip install ./phrasegen
Usage Example
from phrasegen import Generator
gen = Generator() # Generator() is a class provider for Word lists
print(gen.supported_languages) # ('ja', 'ru', 'cs', 'ko', 'zh_cn'...
# .generate() method just randomly select words from
# the list of words. Dead simple process.
print(gen.en.generate()) # 'poem flock future since whisper plate'
print(gen.it.generate()) # 'risultato molosso irlanda oasi scuro proroga'
print(gen.fr.generate()) # 'citrus najisto podzim podivit buchta prodej'
# V 'used+warm+coffee+fox+task+purity+light+neck'
print(gen.en.generate(count=8, separator='+'))
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
phrasegen-1.0.tar.gz
(93.2 kB
view details)
Built Distribution
phrasegen-1.0-py3-none-any.whl
(89.6 kB
view details)
File details
Details for the file phrasegen-1.0.tar.gz
.
File metadata
- Download URL: phrasegen-1.0.tar.gz
- Upload date:
- Size: 93.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5f44fa1d104058c43ae17ed273f97a9dc3c629976df2711ceaed1a9d91a4457c |
|
MD5 | 067ea3ef258d2c473c85b088006595e9 |
|
BLAKE2b-256 | e94542656f650e22fb02be8ad330c93f1bdd78ae13a9d375bcb38a0aa862955a |
File details
Details for the file phrasegen-1.0-py3-none-any.whl
.
File metadata
- Download URL: phrasegen-1.0-py3-none-any.whl
- Upload date:
- Size: 89.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 126e8025a18b5ed0621e98844ca967581f87a5b39f4caa62f4d28c9904a9f199 |
|
MD5 | d9f4fea72012f3369dea38287854ada3 |
|
BLAKE2b-256 | eeefa740f7db23f5a8f4660669e293a9e9a46b01803a4ee0d6225adde2529ea8 |