func-gen
func-gen can be used to generate unix text processing utilities from English text. It uses langchain to create javascript functions to process text, and it uses Extism and the JavaScript PDK to safely execute the code in a Wasm sandbox.
Install
Note: First you need to install Extism on your machine if you have not:
pip install --upgrade extism-func-gen
Run
# Need to set the OpenAI API key
export OPENAI_API_KEY="sk-<paste-key-here>"
# Create a func
func-gen count_vowels -d "Write a function that counts the number of vowels in an input string"
# Use a func
echo "hello world" | func-gen count_vowels
# 3
# List the funcs
func-gen --list
Metadata
Release files for extism-func-gen 0.4.0
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 |
|---|---|---|---|---|
| extism_func_gen-0.4.0.tar.gz | 349.9 kB | Without provenance | Details for extism_func_gen-0.4.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| extism_func_gen-0.4.0-py3-none-any.whl | Python 3 | none | any | Details for extism_func_gen-0.4.0-py3-none-any.whl |
Total release size: 701.3 kB
Release files / extism_func_gen-0.4.0.tar.gz
| Download URL | extism_func_gen-0.4.0.tar.gz |
|---|---|
| Size | 349.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3e07f7d1a45dca183c7655f47ab0e4800f819d641cacc801a67267befc190eab
|
|
BLAKE2b-256 checksum How to use checksums |
488daf1c9b4ad095fc7b4b0d6e8d1035255201b93517e02ab80a75104608e02f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.4.2 CPython/3.11.3 Darwin/22.1.0
|
Release files / extism_func_gen-0.4.0-py3-none-any.whl
| Download URL | extism_func_gen-0.4.0-py3-none-any.whl |
|---|---|
| Size | 351.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
aa5df151a5bb5266d914631adc5cdfb47a39a1dd38267dd4140e49625e7418e1
|
|
BLAKE2b-256 checksum How to use checksums |
25f99dc15f4df99e27fe1b7eaec68f8e07181422f4a1622234ce4ca617b49d4b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.4.2 CPython/3.11.3 Darwin/22.1.0
|
Security for extism-func-gen 0.4.0
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.