wfc-client
Tier-1 sugar for writing Workflow Canvas (wfc) methods.
wfc-client is the opt-in ergonomic way to write a wfc method. The
canonical interface is the Tier-2 env-var + file contract — wfc-client
is a thin wrapper over it with one small dependency, axiom-annotations,
whose markers narrate wfc.run(). It never installs wfc, pandas, or a
scientific stack into your environment, and it never copies, reads, or
serializes your data bytes: it is a metadata recorder.
import wfc_client as wfc
@wfc.method
def qc(ctx):
clean_path = ctx.workdir / "clean.csv"
# ... write your file with whatever library you like ...
ctx.save_artifact("clean", clean_path)
ctx.log_metric("kept_rows", 100)
if __name__ == "__main__":
wfc.run()
The ctx surface
| Member | Purpose |
|---|---|
ctx.input(slot) |
Resolved input paths (list[Path]) for an input slot. |
ctx.params |
Parsed params dict. |
ctx.workdir |
Scratch dir at WFC_RUN_DIR/_workdir/ (auto-created). |
ctx.run_dir |
WFC_RUN_DIR (advanced). |
ctx.save_artifact(name, path) |
Record that path is the declared output name. Path only. |
ctx.log_metric(name, value) |
Record a scalar metric. |
At wfc.run() exit, wfc-client writes one _wfc_results.json manifest
of {outputs, metrics} with run-dir-relative paths. The host reads it.
Exactly one @wfc.method per method module is required.
Metadata
Release files for wfc-client 0.2.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 | |
|---|---|---|---|
| wfc_client-0.2.0.tar.gz | 6.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| wfc_client-0.2.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 14.2 kB
Release files / wfc_client-0.2.0.tar.gz
| Download URL | wfc_client-0.2.0.tar.gz |
|---|---|
| Size | 6.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3d4e602333cdddbbea175fb52d77ace4928cccb4428c51e6708e549f2e72249c
|
|
BLAKE2b-256 checksum How to use checksums |
27df38771c98f79df115d525999d471823d1be67d142f66815c37b95e13883b9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.2 CPython/3.10.9 Windows/10
|
Release files / wfc_client-0.2.0-py3-none-any.whl
| Download URL | wfc_client-0.2.0-py3-none-any.whl |
|---|---|
| Size | 7.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
43d4ffa2681a4ae1e748ac96efb40222176124eabda2e5c4442a9c8101f71c07
|
|
BLAKE2b-256 checksum How to use checksums |
715607f5fce9893c6fdc72113bbec8103b4c56fc9982742da9bfb2f783ba2478
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.8.2 CPython/3.10.9 Windows/10
|