TrueLoop Compute client with Envelope V2 assessment
Project description
swc-runtime — TrueLoop Compute client
This is the thin, standard-library client for the hosted TrueLoop runtime. The private update law remains server-side. Runtime calls keep the substrate-agnostic start → measure → step → end contract; Envelope V2 separately describes the application, substrate, hardware timing, coupling structure, and evidence boundary.
Install
python -m pip install swc-runtime
For a local/manual installation, download the reviewed client bundle, verify
HASHES.sha256, and install its wheel:
python -m pip install ./swc_runtime/dist/swc_runtime-*-py3-none-any.whl
For source-only manual use, place the bundled swc/ folder beside your code.
Runtime quickstart
from swc import SWCOptimizer
opt = SWCOptimizer(license_key="EVAL-...", n=len(x0), mode="regulation", target=target)
x = opt.start(x0)
for _ in range(rounds):
x = opt.step(measure(x), target=target)
opt.end()
The legacy jacobian= constructor argument is reserved and deprecated. The hosted runtime never consumed it, and this client no longer transmits it. Supplying it emits a nonfatal warning and does not change hosted execution or install a new controller.
Envelope V2
assess_envelope() returns the complete structured report. check_envelope() still returns only "USE", "MARGINAL", or "DECLINE" for legacy callers.
from swc import SWCOptimizer, EnvelopeProfile
opt = SWCOptimizer(license_key="EVAL-...", n=4096, mode="regulation")
profile = EnvelopeProfile(
application="photonic.mesh.regulation",
substrate="photonic",
mode="regulation",
n_controls=4096,
n_measurements=4096,
measurement={
"shape": "vector", "parallel": True, "direction_rich": True,
"action_consistent": True, "objective_observable": True,
"semantics": "full_vector_residual", "noise_sigma": 0.02,
},
plant={
"drifting": True, "drift_per_round": 0.01, "locally_monotone": True,
"retainable_configuration": True, "target_type": "vector_setpoint",
},
coupling={
"present": True, "structure": "banded", "bandwidth": 3,
"normalized_mass": 0.3, "conditioning_known": False,
},
hardware={"parallel_readout": True, "physical_hardware": False},
baseline={"type": "unknown", "tuned": False, "model_access": "none",
"demonstrated_performance": "unknown"},
budget={"measurements_per_round": 1, "total_measurements": 300,
"rounds": 300},
evidence_profile="photonic.mesh.regulation.banded.v1",
)
report = opt.assess_envelope(profile)
assert report["verdict"] == "USE"
assert report["decision_scope"] == "pilot"
Legacy Regime requests remain accepted:
from swc import Regime
verdict = opt.check_envelope(Regime(drifting=True, coupled_plant=True,
have_calibration=False,
per_channel_error=True))
Unknown coupling structure is MARGINAL, not an automatic decline. Absence of calibration alone never triggers DECLINE.
Evidence boundary
The mesh scaling evidence uses a simulated nonlinear photonic-mesh plant with the live production TrueLoop runtime. Exact registered cells are M=0.3 at n=64, 256, 512, 1024, and 4096, plus M=0.7 only at n=256, with ±3 banding, measurement noise sigma 0.02, drift sigma 0.01 radians per round, three seeds, and 300 rounds.
Physical photonic-hardware transfer remains unverified. The n=4096, M=0.7 combination was not tested. Discrete cells are not a continuous performance guarantee.
Full docs: https://trueloopcompute.com/docs/envelope
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 swc_runtime-0.3.0.tar.gz.
File metadata
- Download URL: swc_runtime-0.3.0.tar.gz
- Upload date:
- Size: 5.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
022653e2127b4fd30c95fbe86805caff8b582492b0543a6ebf8d9103c271b444
|
|
| MD5 |
6490e022608c92b37ef13fa13462c0fb
|
|
| BLAKE2b-256 |
fad1c6a84b0253997b6d540d5dda7367de96a7b130f02bb6a0eafc5427d8c7b2
|
Provenance
The following attestation bundles were made for swc_runtime-0.3.0.tar.gz:
Publisher:
publish-client.yml on MatthewLeibel/Neotech
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
swc_runtime-0.3.0.tar.gz -
Subject digest:
022653e2127b4fd30c95fbe86805caff8b582492b0543a6ebf8d9103c271b444 - Sigstore transparency entry: 2187698081
- Sigstore integration time:
-
Permalink:
MatthewLeibel/Neotech@cc321450c21a3e95ec006f435d0d4d0b5496f70b -
Branch / Tag:
refs/tags/client-v0.3.0 - Owner: https://github.com/MatthewLeibel
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-client.yml@cc321450c21a3e95ec006f435d0d4d0b5496f70b -
Trigger Event:
push
-
Statement type:
File details
Details for the file swc_runtime-0.3.0-py3-none-any.whl.
File metadata
- Download URL: swc_runtime-0.3.0-py3-none-any.whl
- Upload date:
- Size: 6.7 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 |
8eb902ed9c0f97a60254c74f6b6c34619d849176a1ee7487f2ee09b26b8cddc6
|
|
| MD5 |
660c2f07bff3b544cd901813ce1336f6
|
|
| BLAKE2b-256 |
b40cd7eb9677228e34cb24041fee1732f4f9bab1d8d93d33d2f68eaa35f3844a
|
Provenance
The following attestation bundles were made for swc_runtime-0.3.0-py3-none-any.whl:
Publisher:
publish-client.yml on MatthewLeibel/Neotech
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
swc_runtime-0.3.0-py3-none-any.whl -
Subject digest:
8eb902ed9c0f97a60254c74f6b6c34619d849176a1ee7487f2ee09b26b8cddc6 - Sigstore transparency entry: 2187698089
- Sigstore integration time:
-
Permalink:
MatthewLeibel/Neotech@cc321450c21a3e95ec006f435d0d4d0b5496f70b -
Branch / Tag:
refs/tags/client-v0.3.0 - Owner: https://github.com/MatthewLeibel
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-client.yml@cc321450c21a3e95ec006f435d0d4d0b5496f70b -
Trigger Event:
push
-
Statement type: