Library for replacing function calls with LLM inference.
Project description
Replace a function call with LLM inference. Sends the source code and arguments to an LLM, which then predicts what the output should be.
[!CAUTION] Please, for the love of all things good and holy, do not use this in any sort of production setting. This library should only be used for experimentation or prototyping.
📦 Installation
pip install git+https://github.com/dross20/llmify
💻 Quickstart
To use llmify, simply apply it as a decorator to a function like so:
from llmify import llmify
@llmify()
def add(a, b):
return a + b
result = add(1, 2)
print(result) # Output: 3 (probably)
To change the model used for inference, pass in a value for the model keyword argument:
@llmify(model="gpt-5")
def add(a, b):
...
You can also use llmify on function stubs, so long as they have docstrings or comments:
@llmify()
def greet_user(name):
"""Greet the user in a friendly manner."""
...
greeting = greet_user("Mortimer")
print(greeting) # Output: "Hello, Mortimer!"
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file llmify_decorator-0.0.2.tar.gz.
File metadata
- Download URL: llmify_decorator-0.0.2.tar.gz
- Upload date:
- Size: 5.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1f08f74e0706da6deac845a761282ab60721b5275548f9cec8e760636b47e2ee
|
|
| MD5 |
27ae51d6feecacc5dca517098a7d9079
|
|
| BLAKE2b-256 |
4d07a5164e328bc079184036eaeee95b6cacddb9c75cf0e1d4e2a8cd9a852485
|
Provenance
The following attestation bundles were made for llmify_decorator-0.0.2.tar.gz:
Publisher:
publish-to-pypi.yml on dross20/llmify
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
llmify_decorator-0.0.2.tar.gz -
Subject digest:
1f08f74e0706da6deac845a761282ab60721b5275548f9cec8e760636b47e2ee - Sigstore transparency entry: 407434016
- Sigstore integration time:
-
Permalink:
dross20/llmify@3b4ad3c4f90d823c845bbdb4b5b8d7043fe7004f -
Branch / Tag:
refs/tags/v0.0.2 - Owner: https://github.com/dross20
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-to-pypi.yml@3b4ad3c4f90d823c845bbdb4b5b8d7043fe7004f -
Trigger Event:
push
-
Statement type:
File details
Details for the file llmify_decorator-0.0.2-py3-none-any.whl.
File metadata
- Download URL: llmify_decorator-0.0.2-py3-none-any.whl
- Upload date:
- Size: 6.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
738ecacb4af3cf3ed199d467c2ee631b773b29809363d6898d8c123e75c43ac7
|
|
| MD5 |
7037798a490951a4ab0897eed990044f
|
|
| BLAKE2b-256 |
9425010639ad99dd859929b841288d3a579b355285df9c2fa8b8b3d92a543493
|
Provenance
The following attestation bundles were made for llmify_decorator-0.0.2-py3-none-any.whl:
Publisher:
publish-to-pypi.yml on dross20/llmify
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
llmify_decorator-0.0.2-py3-none-any.whl -
Subject digest:
738ecacb4af3cf3ed199d467c2ee631b773b29809363d6898d8c123e75c43ac7 - Sigstore transparency entry: 407434038
- Sigstore integration time:
-
Permalink:
dross20/llmify@3b4ad3c4f90d823c845bbdb4b5b8d7043fe7004f -
Branch / Tag:
refs/tags/v0.0.2 - Owner: https://github.com/dross20
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-to-pypi.yml@3b4ad3c4f90d823c845bbdb4b5b8d7043fe7004f -
Trigger Event:
push
-
Statement type: