A text generation plugin using local LLMs or other text generation methods. Builds on top of `transformers` by Hugging Face.
Project description
Nendo Plugin TextGen
A text generation plugin using local LLMs or other text generation methods.
Builds on top of transformers
by Hugging Face.
Features
- Generate text from a prompt using a local LLM
- Access all LLMs from the Hugging Face Model Hub
Requirements
Since we depend on transformers
, please make sure that you fulfill their requirements.
You also need Pytorch installed on your system, please refer to the pytorch installation instructions.
Installation
- Install Nendo
pip install nendo-plugin-textgen
If you have a CUDA GPU you can install the following library for an additional speedup:
pip install flash-attn --no-build-isolation
Then set ATTN_IMPLEMENTATION=flash_attention_2
in your environment variables.
Usage
Take a look at a basic usage example below. For more detailed information, please refer to the documentation.
>>> from nendo import Nendo
>>> nd = Nendo(plugins=["nendo_plugin_textgen"])
>>> nd.plugins.textgen(prompt=["Tell me about your favorite song."])[0]
Contributing
Visit our docs to learn all about how to contribute to Nendo: Contributing
License
Nendo: MIT License
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
Built Distribution
Hashes for nendo_plugin_textgen-0.1.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 644a56daa44df1956a53caf186431c81b18ae2aabee15d4322e43491516b241e |
|
MD5 | 92e3995ea28c47e9fe0b7f470fcfe8bf |
|
BLAKE2b-256 | b3df719906ec71a373fb53234d54fe3b95d2dc0de9208e03430cd1dd7653fc92 |
Hashes for nendo_plugin_textgen-0.1.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1a6a0945a3b06fc09995caa89d25d7a90920bdc646a959ec05e5611391c5a7c1 |
|
MD5 | 72dada8856e477a2b9fc0f3628bf7fca |
|
BLAKE2b-256 | 561aca80f02bb15dbcf2d33b06b03514d7d18cd8cf57edd562a2b1a6c0932a5a |