svlang-sdk — Zero-Build-Dependency Python SDK
Pure-Python (ctypes) bindings over the frozen svlang C11 ABI v1.1 (libsvlang_sdk_c), with zero required third-party dependencies and native Apache Arrow PyCapsule Interface zero-copy export (__arrow_c_schema__ / __arrow_c_array__).
Library Discovery
svlang_sdk locates libsvlang_sdk_c.{dylib,so,dll} automatically in priority order:
SVLANG_SDK_LIB— exact shared library file pathSVLANG_SDK_LIB_DIR— directory containing the shared library- Sibling repository build directories (
sdk/build/release/abi/c/,sdk/build/dev/abi/c/) - Standard OS library search (
ctypes.util.find_library("svlang_sdk_c")/ dynamic linker paths)
Quick Start
import pyarrow as pa
from svlang_sdk import AtomicChange, Durability, Graph, Host, Registry, abi_version
print("C ABI:", abi_version()) # (1, 1)
with Host() as host:
host.set_file(
"rtl/top.sv",
"module top(input logic [7:0] a, output logic [7:0] y); assign y = ~a; endmodule\n",
Durability.LOW,
)
host.set_file(
"pwr/top.upf",
"upf_version 3.1\ncreate_power_domain PD_TOP -include_scope\n",
Durability.HIGH,
)
with host.take_snapshot() as snap, snap.build_graph("top") as graph:
# Zero-copy Apache Arrow PyCapsule export (no pyarrow.cffi boilerplate).
arr = pa.array(graph.entities_arrow())
batch = pa.RecordBatch.from_struct_array(arr)
print(batch.num_rows, batch.schema.names)
# Immutable .svdb snapshot persistence (ABI v1.1).
graph.save_svdb("top.svdb")
summary = Graph.inspect_svdb("top.svdb")
with Graph.load_svdb("top.svdb") as loaded:
assert loaded.entity_count == summary["entity_count"]
Without pyarrow installed, ArrowEntityTable still supports pure-Python inspection:
with graph.entities_arrow() as table:
print(table.row_count, table.column_names)
rows = table.to_pylist()
Public API
- Lifecycle & Errors:
abi_version(),inspect_svdb(path),Durability,StatusCode,SdkError(.code,.message) Host:revision,set_file(path, content, durability=Durability.LOW),remove_file(path),take_snapshot()Snapshot:revision,is_cancelled,build_graph(top_module=None),lint_file(path)Graph:entity_count,find_entity(path),export_entities(...),fanin_cone(...),explain_overlay(...),apply_overlay_str(...),power_crossings(),entities_arrow(),save_svdb(path),Graph.load_svdb(path),Graph.inspect_svdb(path)ArrowEntityTable:__arrow_c_schema__(),__arrow_c_array__(requested_schema=None),row_count,column_count,column_names,column_formats,to_pylist(),close()AtomicChange:add_edit(...),preview(snapshot, ...),apply_to_host(host, ...)Registry:register_builtins(),list_plugins(),run_passes(graph)
Running Tests
PYTHONPATH=sdk/bindings/python python3 -m unittest discover -s sdk/bindings/python/tests -v
Metadata
Release files for svlang-sdk 0.7.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 |
|---|---|---|---|---|
| svlang_sdk-0.7.0.tar.gz | 18.2 kB | With provenance | Details for svlang_sdk-0.7.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| svlang_sdk-0.7.0-py3-none-any.whl | Python 3 | none | any | Details for svlang_sdk-0.7.0-py3-none-any.whl |
Total release size: 32.8 kB
Release files / svlang_sdk-0.7.0.tar.gz
| Download URL | svlang_sdk-0.7.0.tar.gz |
|---|---|
| Size | 18.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cbb02c5699c3e38541566bee93f93bfa5ca553ef8eef1ed2f0ba837fc2b33a0a
|
|
BLAKE2b-256 checksum How to use checksums |
3b9040594640d95025ebcc92d9d72f6ba7b57a404681177da5e286b26fc61ebd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 1, 2026.
Transparency logRelease files / svlang_sdk-0.7.0-py3-none-any.whl
| Download URL | svlang_sdk-0.7.0-py3-none-any.whl |
|---|---|
| Size | 14.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
328701d6cee8eca7b2fd7704e79719829958e23cf699d242fccc7958a4667b43
|
|
BLAKE2b-256 checksum How to use checksums |
85d3414872ee269e7025f196ba00ccaf43fd99bac818a880785b7a2f7d2ad1c7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 1, 2026.
Transparency logSecurity for svlang-sdk 0.7.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.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for svlang_sdk-0.7.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 1, 2026.
Transparency logA 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.