Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/bbaovanc/liblistloader
Python library for loading word lists. Built for https://github.com/BBaoVanC/libnamegen.
https://github.com/bbaovanc/liblistloader
list-manager pip pip3 pypi pypi-package pypi-source python python-3 python-3-6 python-3-7 python-3-8 python-library python3 python36 python37 python38
Last synced: 3 days ago
JSON representation
Python library for loading word lists. Built for https://github.com/BBaoVanC/libnamegen.
- Host: GitHub
- URL: https://github.com/bbaovanc/liblistloader
- Owner: BBaoVanC
- License: gpl-3.0
- Created: 2020-03-18T20:51:37.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2022-01-13T16:46:29.000Z (about 3 years ago)
- Last Synced: 2025-01-19T07:42:12.796Z (9 days ago)
- Topics: list-manager, pip, pip3, pypi, pypi-package, pypi-source, python, python-3, python-3-6, python-3-7, python-3-8, python-library, python3, python36, python37, python38
- Language: Python
- Homepage: https://pypi.org/project/liblistloader/
- Size: 51.8 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# liblistloader
[![Build Status](https://drone.bbaovanc.com/api/badges/bbaovanc/liblistloader/status.svg)](https://drone.bbaovanc.com/bbaovanc/liblistloader)
![PyPI](https://img.shields.io/pypi/v/liblistloader)
![PyPI - License](https://img.shields.io/pypi/l/liblistloader)Library for loading word lists from files. Built for [libnamegen](https://git.bbaovanc.com/bbaovanc/libnamegen)
## Features
* Easy to use
* Imported as module
* Always tested before release
* Officially supports latest two versions of Python 3---
## Included word lists
* `liblistloader.desiquintans_nounlist`: [The Great Noun List](http://www.desiquintans.com/nounlist) by desiquintans.com
---
## How to Install
Run the command `pip install liblistloader`. If you want to specify a specific Python version to use for pip, use a command such as `pip3` or `pip3.8`.
---
## Documentation
### API
To import a single list, type `import liblistloader.[word list]`. Then, you can get a list, each item being a word in the word list, by typing `liblistloader.[word list].words`.
WARNING! These lists are VERY long! For example, desiquintans_nounlist is 6,801 words long! Therefore, `liblistloader.desiquintans_nounlist.words` returns a list with 6,801 items in it. I would not recommend the following code for your sanity:
``` python
import liblistloader.desiquintans_nounlistfor word in liblistloader.desiquintans_nounlist.words:
print(word)
```Output (total 6,801 lines):
``` plaintext
ATM
CD
SUV
TV
aardvark
abacus
abbey
abbreviation
abdomen
...
```---
Import all noun lists and pick a random word from a few:
``` python
import random
import liblistloaderprint("desiquintans_nounlist: " + random.choice(liblistloader.desiquintans_nounlist.words))
```Output (will vary because a random word is being picked):
``` plaintext
desiquintans_nounlist: velocity
```---
## License
_liblistloader_ is licensed under the GPLv3 license. For more information, please refer to [`LICENSE`](https://git.bbaovanc.com/bbaovanc/liblistloader/src/branch/master/LICENSE).