Python SDK for the skrun executable skill runtime.
Project description
skrun
skrun is a Python-first executable skill runtime that lets agent frameworks discover, build, install, and call local skills.
Principles
- Use short module names.
- Give each module a narrow responsibility.
- Keep UI interaction out of runtime semantics.
- Keep durable storage out of the executable skill runtime.
- Keep Python bindings at the same module boundary as Rust APIs.
- Support external agent frameworks instead of replacing their main agent loop.
- Make Rust binary skills and uv-backed Python skills first-class.
Modules
agent agent loop and execution planning
bridge legacy migration DTOs and import checks
skill skill catalog, mentions, and per-turn capability planning
tool tool trait and registry
runtime executable skill artifacts, scaffold, build, and run
cli minimal executable skill commands
run Task/Run durable execution model
chat sessions, turns, and messages
engine core composition and command execution
proto CoreCommand, CoreResponse, and CoreSnapshot protocol types
server command and JSON ingress for product shells
store repository traits and backend contracts
model providers, models, selectors, and runtime model specs
auth secrets, auth profiles, and provider access policy
event stream, trace, and telemetry event types
Executable Skills
skrun supports two local artifact kinds:
rust_binary Cargo-built executable skill, called with stdin/stdout JSON
python_uv uv-managed Python project, called with stdin/stdout JSON
Each skill directory contains an artifact.json manifest:
{
"schema_version": 1,
"kind": "rust_binary",
"id": "regex-finder",
"name": "Regex Finder",
"version": "0.1.0",
"entry": "bin/release/regex-finder",
"protocol": {
"transport": "stdio-json",
"input": "single-json-value",
"output": "single-json-value"
},
"schema": {
"input": "schema/input.json",
"output": "schema/output.json"
}
}
The initial protocol is intentionally strict:
- input is one JSON value written to stdin
- output is one JSON object written to stdout
- stderr is diagnostics
- non-zero exit is failure
- streaming is not part of the first executable skill contract
Python Package Loop
The PyPI distribution and Python import are both skrun. The Python package is
backed by the Rust skrun-native PyO3 module. Use the packaging helper so local
installs and release wheels use the same settings:
python3 -m pip install maturin
python3 python/scripts/package.py develop
python3 python/scripts/package.py smoke
python3 python/scripts/package.py build
python3 python/scripts/package.py sdist
The helper sets PYO3_PYTHON and keeps Cargo artifacts under
/tmp/skrun-python-target by default, which avoids executing Rust build
artifacts from an external macOS volume.
Python Skill API
The high-level Python API calls local executable skill artifacts through the
same Rust runtime crate used by the CLI:
import skrun
result = skrun.skill("/path/to/skill").call({"pattern": "TODO", "path": "."})
By default, skill IDs resolve under ~/.skrun/skills, or under the directory
set by SKRUN_SKILLS_DIR. The Python package requires the
skrun_native PyO3 extension for executable skill operations; it does not
maintain a separate subprocess runtime fallback.
CLI Skill Loop
The minimal CLI exists only for executable skills:
cargo run -p cli -- \
skill new --kind rust_binary --id rust-echo /tmp/rust-echo
cargo run -p cli -- \
skill build /tmp/rust-echo
cargo run -p cli -- \
skill run --input '{"ok":true}' /tmp/rust-echo
cargo run -p cli -- \
skill install-local --root /tmp/skrun-skills --overwrite /tmp/rust-echo
cargo run -p cli -- \
skill list --root /tmp/skrun-skills
Example skills live under examples/skills.
Agent Framework Examples
skrun does not replace the main agent framework. Wrap executable skills from the framework you already use:
import skrun
def regex_finder_tool(arguments: dict) -> dict:
return skrun.skill("regex-finder").call(arguments)
Dependency-light examples live under examples/frameworks for LangChain,
LangGraph, PydanticAI, and OpenAI Agents-style tool bodies.
Non-Goals For This Slice
- Do not open or migrate production databases.
- Do not duplicate the current TUI/Web implementation.
- Do not implement a main agent framework.
- Do not implement a remote marketplace UI.
- Do not implement streaming executable skills.
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 skrun-0.1.0.tar.gz.
File metadata
- Download URL: skrun-0.1.0.tar.gz
- Upload date:
- Size: 46.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
74abc8b4a4498b1090bab05ed625cec2802ef3edd38c8d9c9c398511158cf186
|
|
| MD5 |
6228cda0ee67039e11df4bf142918eec
|
|
| BLAKE2b-256 |
3a264cbd4b53c7eafcc30810454bcecbdffd51a4f76bd689686f6c586b604f11
|
Provenance
The following attestation bundles were made for skrun-0.1.0.tar.gz:
Publisher:
publish-python.yml on lhwzds/skrun
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
skrun-0.1.0.tar.gz -
Subject digest:
74abc8b4a4498b1090bab05ed625cec2802ef3edd38c8d9c9c398511158cf186 - Sigstore transparency entry: 1417242592
- Sigstore integration time:
-
Permalink:
lhwzds/skrun@db61c5750e1094e06f125170a2fdbc16d5b6c614 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/lhwzds
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-python.yml@db61c5750e1094e06f125170a2fdbc16d5b6c614 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file skrun-0.1.0-cp313-cp313-manylinux_2_34_x86_64.whl.
File metadata
- Download URL: skrun-0.1.0-cp313-cp313-manylinux_2_34_x86_64.whl
- Upload date:
- Size: 656.9 kB
- Tags: CPython 3.13, manylinux: glibc 2.34+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
925ed553ca0ffde07f41ad262d911416515d50b97219a378d5d382e917185b98
|
|
| MD5 |
716bae7b49edc99400637338a79a74ea
|
|
| BLAKE2b-256 |
611bcb362f8f010abcddaf2b4cc4ae15f7f718dfe705d1cbc8c969b05aead45d
|
Provenance
The following attestation bundles were made for skrun-0.1.0-cp313-cp313-manylinux_2_34_x86_64.whl:
Publisher:
publish-python.yml on lhwzds/skrun
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
skrun-0.1.0-cp313-cp313-manylinux_2_34_x86_64.whl -
Subject digest:
925ed553ca0ffde07f41ad262d911416515d50b97219a378d5d382e917185b98 - Sigstore transparency entry: 1417230658
- Sigstore integration time:
-
Permalink:
lhwzds/skrun@f2e16f3fc0d9f1a7e25c196d62e85faa3dd84289 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/lhwzds
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-python.yml@f2e16f3fc0d9f1a7e25c196d62e85faa3dd84289 -
Trigger Event:
workflow_dispatch
-
Statement type: