nlpip - A natural language based unix pipeline utility
nlpip takes a text written in natural language as input, and performs a
specified command also written in natural language, and then outputs the result
in natural language.
Here's a demo:
Installation
First, you need to install nlpip using pip:
pip install nlpip
Then, set your OpenAI's API key as an environment variable:
export OPENAI_API_KEY=WRITE_YOUR_KEY_HERE
How to use
nlpip or just nlp for short, provides following default commands:
keywords: Extract keywords from input textpoem: Write poem using input textsummarize: Summarize input textsentiment: Analyze sentiment of input text
For example, if you want summarize input.txt and turn it into a poem, you can
run the following command:
cat input.txt | nlp summarize | nlp poem
How to create a new command
To create a new command, you just need to create a text file containing the
command in natural language. For example, if you want to create a command that
translates input text into French, you can create a file named
~/.nlpip/prompts/fr.txt in with:
Translate into French
Then, you can run the following command:
echo Hello | nlp fr
And you will get the following output:
Bonjour
You may override default commands by creating a file with the same name in
~/.nlpip/prompts/.
Credit
nlpipis inspired by Schillace Laws of Semantic AI.
Metadata
Release files for nlpip 0.1.6
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 |
|---|---|---|---|---|
| nlpip-0.1.6.tar.gz | 5.8 kB | Without provenance | Details for nlpip-0.1.6.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| nlpip-0.1.6-py3-none-any.whl | Python 3 | none | any | Details for nlpip-0.1.6-py3-none-any.whl |
Total release size: 11.7 kB
Release files / nlpip-0.1.6.tar.gz
| Download URL | nlpip-0.1.6.tar.gz |
|---|---|
| Size | 5.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
054de198454d607a7c4e6ddea629db439ec37b96aceb27a565f6f52210af67b9
|
|
BLAKE2b-256 checksum How to use checksums |
0fbd8dfab1f0bae2ac69a27d00b556efffbdd18e5d19ce6c9eba80fea5ba5a41
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.0
|
Release files / nlpip-0.1.6-py3-none-any.whl
| Download URL | nlpip-0.1.6-py3-none-any.whl |
|---|---|
| Size | 5.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a634bbcbd5210571d89f54484d11329da8a6ea5b3058dca2b6c79a9bf67a0c51
|
|
BLAKE2b-256 checksum How to use checksums |
e9bb487d482f910ea461034f85a72e2b84f098ed977b18924f1d5c35b8850321
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.0
|
Security for nlpip 0.1.6
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.