Subshell + MLX LLM-calling backends (Claude/Codex CLI, local MLX) shared across tools.
Project description
spawnllm
Subshell + MLX LLM-calling backends (Claude/Codex CLI, local MLX) shared across tools.
spawnllm centralizes the LLM-calling plumbing that small tools keep re-inventing: driving the
claude and codex CLIs as subshells — with structured Pydantic output, model tiers, and
faithful error capture — and running local Apple-Silicon MLX models with adapter fusion,
prompt-cache reuse, and batched generation. Depend on it once and each tool keeps only its
domain logic instead of its own copy of the backends.
Install
No install needed — run everything through uvx:
uvx spawnllm --help
uvx fetches spawnllm into a throwaway environment and runs it. To add it
to a project instead:
uv add spawnllm
For the local MLX engine (Apple Silicon only), pull the extra:
uv add "spawnllm[mlx]"
Quickstart
List the backends spawnllm can drive:
uvx spawnllm backends
claude
codex
mlx
What problems does this solve?
- Duplicate subshell plumbing. Building
claude/codexargv, piping stdin/stdout, teeing stderr, and turning non-zero exits into useful errors — written once, not re-derived per tool. - Structured-output boilerplate. A Pydantic model becomes a JSON-schema constraint and a parsed, validated result the same way for every backend.
- Local MLX is fiddly. Adapter fusion, prompt-cache reuse, worker-thread lifecycle, and batched single-token generation live behind one engine instead of in every consumer.
- Behavior drift. Two tools that call the same models stay byte-for-byte consistent because they share the backend layer rather than each maintaining a copy.
Docs
Read the docs for the full guide and API reference.
Project details
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 spawnllm-0.1.2.tar.gz.
File metadata
- Download URL: spawnllm-0.1.2.tar.gz
- Upload date:
- Size: 13.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e968fa8c9333513bea3d28f25a582dd9ccf6f152ade2d343844e0731ebfd7fae
|
|
| MD5 |
3499f951bb8aaf58b0db9f7f3c7cafd6
|
|
| BLAKE2b-256 |
ca1cbfa3e0742fb4c51a7cc6fed2ea96588576732c54c3665f3a1e9a5ceb005d
|
Provenance
The following attestation bundles were made for spawnllm-0.1.2.tar.gz:
Publisher:
release-pypi.yml on yasyf/spawnllm
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
spawnllm-0.1.2.tar.gz -
Subject digest:
e968fa8c9333513bea3d28f25a582dd9ccf6f152ade2d343844e0731ebfd7fae - Sigstore transparency entry: 1779572751
- Sigstore integration time:
-
Permalink:
yasyf/spawnllm@154eeff33ee845c26e3c966f584dcfb43be41a1c -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/yasyf
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-pypi.yml@154eeff33ee845c26e3c966f584dcfb43be41a1c -
Trigger Event:
push
-
Statement type:
File details
Details for the file spawnllm-0.1.2-py3-none-any.whl.
File metadata
- Download URL: spawnllm-0.1.2-py3-none-any.whl
- Upload date:
- Size: 19.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0179951083ad688580de80ea39008eb667bc366073e03c7dea14524d74e975a9
|
|
| MD5 |
1dd323190c35516c0dec5f02241f7b89
|
|
| BLAKE2b-256 |
61a0e00de1d2f12228d2cd7311b6878807618fba9676f984eef9965f47a61616
|
Provenance
The following attestation bundles were made for spawnllm-0.1.2-py3-none-any.whl:
Publisher:
release-pypi.yml on yasyf/spawnllm
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
spawnllm-0.1.2-py3-none-any.whl -
Subject digest:
0179951083ad688580de80ea39008eb667bc366073e03c7dea14524d74e975a9 - Sigstore transparency entry: 1779572864
- Sigstore integration time:
-
Permalink:
yasyf/spawnllm@154eeff33ee845c26e3c966f584dcfb43be41a1c -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/yasyf
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-pypi.yml@154eeff33ee845c26e3c966f584dcfb43be41a1c -
Trigger Event:
push
-
Statement type: