Lifeboat Cache
Tiered, compressed, persistent KV cache for vLLM, SGLang, and Lifeboat (which embeds SGLang), with a built-in dashboard to configure, monitor and observe it.
pip install "lifeboatcache[vllm]" # into the environment that runs vLLM
pip install lifeboatcache # into the environment that runs SGLang / Lifeboat
Installing registers engine plugins; nothing else is needed to start. With no config file,
Lifeboat writes KV to local disk under ~/.lifeboat_cache/kv, compresses it with fp8, and
serves the dashboard on http://127.0.0.1:9400.
Turn it on
| Engine | How |
|---|---|
| vLLM | LIFEBOAT_CACHE=1 vllm serve <model> — or explicitly --kv-transfer-config '{"kv_connector":"LifeboatConnector","kv_role":"kv_both"}' |
| SGLang | LIFEBOAT_CACHE=1 python -m sglang.launch_server --model-path <model> |
| Lifeboat | set LIFEBOAT_CACHE=1 in the Lifeboat container's environment, with lifeboatcache installed in its Python env |
What happens underneath:
-
vLLM —
LifeboatConnectoris LMCache's multiprocess connector with Lifeboat defaults: it auto-starts a local LMCache server (port 6555) whose L2 storage is the Lifeboat adapter. GPU ↔ host movement is LMCache's; everything below host RAM is Lifeboat. -
SGLang / Lifeboat — Lifeboat is a HiCache storage backend (
--hicache-storage-backend dynamic). WithLIFEBOAT_CACHE=1the plugin enables HiCache and selects the backend unless the launch already chose a storage backend. Explicit flags work too:python -m sglang.launch_server --model-path <model> --enable-hierarchical-cache \ --hicache-storage-backend dynamic \ --hicache-storage-backend-extra-config '{"backend_name":"lifeboat","module_path":"lifeboat_cache.integrations.sglang_backend","class_name":"LifeboatHiCacheStorage"}'
Storage targets and the local fallback
Targets are tried in order; the first usable one takes new writes. Each is write-probed at
startup. One that can't be reached (ONTAP/NFS export not mounted, S3 without credentials) is
skipped with the reason shown on the dashboard, and if nothing persistent is left, KV goes to
storage.fallback_local on local disk.
storage:
tiers:
- {name: ontap, type: ontap, enabled: true, mount: /mnt/kvcache, protocol: pnfs_rdma}
- {name: nfs, type: nfs, enabled: true, mount: /mnt/nfs, path: /mnt/nfs/lifeboat/kv}
- {name: s3, type: s3, enabled: true, bucket: kv-archive, region: us-east-1}
fallback_local: {enabled: true, path: ~/.lifeboat_cache/kv, capacity_gb: 50}
Persisted KV survives restarts: on startup the index is rebuilt from disk in the background.
Dashboard
http://127.0.0.1:9400 on the node (use ssh -L 9400:localhost:9400 <node> from your
laptop). It shows the cache hit rate, KV served, bytes saved by compression and the codec's
sampled reconstruction error, per-target status (circuit breaker, usage, queue), evictions,
and startup recovery. The Configure tab edits storage targets, the local fallback, the
compression codec per rung, the eviction policy and the write mode; changes are validated,
applied live, and saved to the config file (startup-bound sections are flagged "restart
required"). /metrics serves Prometheus text (also on port 9402).
To expose it beyond localhost, set dashboard.host: 0.0.0.0 and dashboard.auth_token;
open the page once with ?token=<token>.
CLI: lifeboat-cache status prints the same numbers; lifeboat-cache init writes a starter
config; lifeboat-cache server runs a standalone Lifeboat-backed LMCache server for several
vLLM instances to share.
Configuration
One YAML file, resolved as: --config / $LIFEBOAT_CACHE_CONFIG →
~/.lifeboat_cache/lifeboat.yaml → built-in defaults ($LIFEBOAT_CACHE_HOME moves the home
directory). lifeboat-cache config show prints the resolved config. Presets ship with the
package: extends: single_node_gpu.
Compression — what the numbers say
Measured on real Qwen3 KV (2,048-token prefix, see docs/):
| codec | bits/value | Qwen3-4B perplexity (base 2.297) |
|---|---|---|
| fp8 (default) | 8.0 | 2.293 |
| turboquant4, keep first/last 2 layers | 6.2 | 2.300 |
| turboquant3 | 4.0 | 824 (breaks the model) |
| oscar2 on 2,048-token chunks | 5.0 | 72 (breaks the model) |
fp8 is the default for every stored rung. The dashboard shows the sampled reconstruction error of whatever codec is live.
Metadata
Release files for lifeboatcache 0.1.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 |
|---|---|---|---|---|
| lifeboatcache-0.1.0.tar.gz | 142.9 kB | Without provenance | Details for lifeboatcache-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| lifeboatcache-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for lifeboatcache-0.1.0-py3-none-any.whl |
Total release size: 329.1 kB
Release files / lifeboatcache-0.1.0.tar.gz
| Download URL | lifeboatcache-0.1.0.tar.gz |
|---|---|
| Size | 142.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ecb9a9ba6a7d1e4049668d0202f4a28f74a398529c43d07ec2534d4d55570477
|
|
BLAKE2b-256 checksum How to use checksums |
713cf81ee4935e5510e9e03482f3d0577a4429b6d03e05d3763d1475e61826a9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.1 {"installer":{"name":"uv","version":"0.12.1","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / lifeboatcache-0.1.0-py3-none-any.whl
| Download URL | lifeboatcache-0.1.0-py3-none-any.whl |
|---|---|
| Size | 186.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6f37c3c0231a3d5d52a28ed694ed0648ac25e6ed93dbae81afc31c0dee4762b2
|
|
BLAKE2b-256 checksum How to use checksums |
3887599e17eef78480ac67cdc49a1278bc647c150fff40ad93648b42b508fbe7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.1 {"installer":{"name":"uv","version":"0.12.1","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for lifeboatcache 0.1.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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A 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.