The GitHub Action
Upload content-addressed artifacts to CAVS Hub straight from a workflow — no scripting. The Action wraps the same canonical API as the SDKs, dedups against what the Hub already stores, and exposes dedup stats as step outputs.
Drop it into any workflow.
Reference the Action by path and tag, pass the artifact fields as inputs, and provide the token as an environment secret.
Configure the upload.
| Input | Required | Description |
|---|---|---|
path | yes | File or directory to upload. Directories are expanded recursively; each file is streamed and hashed. |
project | yes | Project (an alias of repository) within the org that owns the artifact. |
name | yes | Logical artifact name, e.g. classifier. |
kind | yes | Artifact kind, e.g. model, dataset, build. |
version | yes | Version label for this upload, e.g. 1.4.0 or ${{ github.sha }}. |
Read back dedup stats.
The finalize step returns the created version plus deduplication metrics — reference them in later steps via steps.<id>.outputs.<name>.
| Output | Description |
|---|---|
artifact-id | Server-assigned id of the artifact. |
artifact-reference | The cavs:// reference for this version, e.g. cavs://acme-ai/vision-models/model/classifier:<sha>. |
version | The finalized version label. |
sha256 | Content address (oid) of the artifact's top-level object. |
logical-bytes | Total size of the artifact as presented. |
physical-bytes | Bytes actually stored after dedup. |
deduplicated-bytes | Bytes skipped because the Hub already had them. |
deduplication-ratio | Fraction of the upload served from existing objects. |
Handled safely by default.
Secrets
Store the service-account key as the CAVS_TOKEN repository or org secret and pass it via env. The Action redacts the token from logs and never prints presigned URLs or full request headers. Set CAVS_API as an env var to target a self-hosted Hub. Use least-privilege scopes — artifacts:write is enough to publish.
Telemetry
Every request carries telemetry headers so uploads are attributable: the Action sets X-CAVS-Integration: github-actions, sends X-CAVS-Integration-Version and a User-Agent, and forwards a correlation id via X-CAVS-Run-ID. Deprecation notices arrive as X-CAVS-Deprecation and surface as workflow warnings — never as failures.
Idempotency-Key, so retries return the same version instead of creating duplicates.