Snakelang
Snakelang is a Python module that uses OpenAI's GPT-4 model to automatically generate Python code based on natural language descriptions of the desired functionality.
Installation
The easiest way to install Snakelang is through pip:
python3 -m pip install snakelang
Usage
To use Snakelang, you will need to import the snakelang module and use the @snakelang.spec decorator to specify the desired functionality. Here is an example usage:
import snakelang
@snakelang.spec("Compute the nth number in the Fibonacci series.")
def myfib(n: int) -> int:
""
This code will generate a Python function named myfib that computes the nth number in the Fibonacci series.
To actually execute the function, you can call it as you would any other Python function:
for i in range(20):
print(myfib(i))
Snakelang caches the results of translating natural language to Python, so subsequent executions in the same directory will run much faster.
Metadata
Release files for snakelang 0.0.3
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 |
|---|---|---|---|---|
| snakelang-0.0.3.tar.gz | 3.4 kB | Without provenance | Details for snakelang-0.0.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| snakelang-0.0.3-py3-none-any.whl | Python 3 | none | any | Details for snakelang-0.0.3-py3-none-any.whl |
Total release size: 6.9 kB
Release files / snakelang-0.0.3.tar.gz
| Download URL | snakelang-0.0.3.tar.gz |
|---|---|
| Size | 3.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
16f0f16f4f03b0d61db7cb28e1befff02eb94b7ca803954ab0696cca1b87e02c
|
|
BLAKE2b-256 checksum How to use checksums |
375754920437f40fcc16e3518e900a205a41f04939f82390a24cc65ff2edd15c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.1
|
Release files / snakelang-0.0.3-py3-none-any.whl
| Download URL | snakelang-0.0.3-py3-none-any.whl |
|---|---|
| Size | 3.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3c1bdd349c80a2b6bab81779b37aa309b14f41e76b1049694ea93d4ae58a4f54
|
|
BLAKE2b-256 checksum How to use checksums |
eaf63f163affa7b15739665d40a1ad121e5647e4f982f658ddec951f4dc1da44
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.1
|
Security for snakelang 0.0.3
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.