Welcome
This is a small module that can be used to generate prompts for text-to-image generative AI.
The package is available on pypi.
In order to install the package you would use the following command.
pip install propmpter-r3ap3rpy
Then all you have to do is import the module and use it as follows.
from prompter import PromptGenerator
p = PromptGenerator()
p()
'Madonna grilling at Jerusalem.'
p()
'Natalie Portman cycling at Mumbai.'
p()
'John von Neumann baseball at Tower of London.'
You have the option to update the data.json.
from prompter import PromptGenerator
p = PromptGenerator()
p.update("People","Dani Ernő")
When updating the data the section is converted to lower-case and verified, also the value is checked whether it's in the section converted to lower-case before checking, if not it's added, otherwise an exception is thrown.
You can also delete from the data.json entries. By default it will delete first occurence from each section, but you can pass the all_occurence=True to remove all occurences.
from prompter import PromptGenerator
p = PromptGenerator()
p.delete("Dani Ernő") # deletes value from every sections
p.delete("people","Pablo Picasso") # deletes value from given section
You have the option to get basic stats from your database.
from prompter import PromptGenerator
p = PromptGenerator()
p.stats
###############################################
# people # 107 #
# activity # 107 #
# location # 107 #
###############################################
The details attribute will print the content in a table format to your terminal.
You have restore_db() which is a static method, it allows you to restore any backups in the data folder, the backup_db() which is an instance method allows you to backup the actual state of the database to a default or custom filename!
In order to run the tests you can do the following.
git clone https://github.com/r3ap3rpy/prompter
cd prompter
pip install -r requirements.txt
pytest -vvvvv
You can also use pylint, currently the passing score is 9,5, the workflow will fail if score goes under it.
Metadata
Release files for prompter-r3ap3rpy 0.1.9
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| prompter_r3ap3rpy-0.1.9.tar.gz | 10.3 kB | Without provenance | Details for prompter_r3ap3rpy-0.1.9.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| prompter_r3ap3rpy-0.1.9-py3-none-any.whl | Python 3 | none | any | Details for prompter_r3ap3rpy-0.1.9-py3-none-any.whl |
Total release size: 21.3 kB
Release files / prompter_r3ap3rpy-0.1.9.tar.gz
| Download URL | prompter_r3ap3rpy-0.1.9.tar.gz |
|---|---|
| Size | 10.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1bd1525704033e7c7553d544590a89fa4370d2a5970a753698269e0a266efafb
|
|
BLAKE2b-256 checksum How to use checksums |
b6f1ae7b68e8bbedd006ad59a9dda500d77578b30e00f214db57150b862e736f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Release files / prompter_r3ap3rpy-0.1.9-py3-none-any.whl
| Download URL | prompter_r3ap3rpy-0.1.9-py3-none-any.whl |
|---|---|
| Size | 11.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3f5fc1e7a6a27c081ed2537e82b6d12d5c7de5524d758860e6e0528535d53057
|
|
BLAKE2b-256 checksum How to use checksums |
c83f35e715fcd75ac1878e8a018031fa55316062621995db177a4c248407862d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Security for prompter-r3ap3rpy 0.1.9
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.