Installation
cargo install sceptre-cliThe CLI’s default feature set is ["ort-bundled", "download"], so this produces a
self-contained binary: a prebuilt ONNX Runtime is fetched and linked at build time, and models
download and cache at first use. No ORT_DYLIB_PATH, no separately installed
libonnxruntime.
To also expose the MCP server subcommand, add the mcp feature:
cargo install sceptre-cli --features mcpTargets with no prebuilt ONNX Runtime.
ort publishes prebuilt runtimes for a fixed target list. These have none, and the default
install fails at build time with ort-sys’s own
no prebuilt binaries available for target ...:
x86_64-apple-darwin(Intel macOS)- every
*-unknown-linux-musltarget (Alpine) armv7-unknown-linux-gnueabihfriscv64gc-**-unknown-freebsdi686-*,s390x-*,powerpc64le-*
Either bring your own libonnxruntime:
cargo install sceptre-cli --features ort-dynamicor build the pure-Rust backend and select it at runtime:
cargo install sceptre-cli --no-default-features --features tract,downloadsceptre run receipt.png --backend tractThe library ships default = [] — no backend and no download support are enabled by default.
Enable a backend feature and, typically, download:
[dependencies]sceptre = { version = "0.5", features = ["ort-bundled", "download"] }See Feature flags for every flag and when to pick it, and
Backends for the ort vs. tract tradeoff.
The MCP surface is behind the mcp cargo feature, exposed as the sceptre mcp subcommand.
Install the CLI with mcp enabled (see the CLI tab), or depend on the library with mcp plus a
backend and download:
[dependencies]sceptre = { version = "0.5", features = ["ort-bundled", "download", "mcp"] }Model download and caching
Section titled “Model download and caching”The CRAFT detector and the gen2 recognizers are first-party ONNX artifacts fetched from Hugging Face
(xberg-io/sceptre-*) on first use. Each download is verified against a pinned SHA-256 before use.
Models are cached in the standard Hugging Face hub cache — HF_HUB_CACHE → HUGGINGFACE_HUB_CACHE
→ $HF_HOME/hub → ~/.cache/huggingface/hub — so the library, the CLI, and any other Hugging Face
tooling on the machine share one cache store. Every run after the first reads the cached models with
no network access.
Verification happens as bytes download. A cache hit is not re-hashed: the cached artifact is checked for being a readable, non-empty regular file and then used directly. A hash mismatch found on a download evicts the artifact and its backing blob, so a corrupt entry self-heals on the next run rather than being served forever.