Post

model weights are kubernetes artifacts now

Large model delivery is not just a storage problem anymore. It is becoming a Kubernetes supply chain problem, with cold starts, caching, digest identity, signatures, and rollback all tied together.

model weights are kubernetes artifacts now

The uncomfortable part of running inference on Kubernetes is not always the GPU.

Sometimes it is the model bytes.

You can tune the autoscaler, keep the serving runtime lean, and make the pod spec look clean enough to frame. Then the replica starts and spends the next several minutes dragging a giant model out of object storage like production is a group chat waiting for one person to upload a video.

That was annoying when models were small.

For large language models, it is architecture.

The model is no longer a blob that happens to arrive before the server starts. It is part of the release. It has identity. It has provenance. It has cache behavior. It has integrity risk. It has rollback semantics. It affects startup latency, node pressure, network cost, and whether scale-to-zero is a real operating model or just a nice slide.

the autoscaler discovering the model is 140 GB

That is why the next boring platform question is surprisingly important:

Should model weights be treated more like container images?

I think the answer is yes.

Not because OCI is fashionable. Not because every artifact needs to cosplay as a container. Because Kubernetes already has a lot of hard-won machinery for distributing, caching, identifying, mounting, and governing immutable artifacts. Large model delivery is starting to need exactly that machinery.

the download path became the bottleneck

For a long time, model delivery looked simple enough.

Point the serving platform at S3, GCS, Hugging Face, a PVC, or some internal object store. Let an init container or bootstrap script fetch the model. Start the runtime after the files land on disk.

That pattern is easy to understand. It is also easy to underestimate.

The serving runtime is not really ready until the model is present. If the model is tens or hundreds of gigabytes, startup is dominated by delivery. If each replica repeats the same download, warm scale-out is not warm. If the delivery path has weak cache semantics, the autoscaler can schedule pods faster than the platform can safely feed them.

The July 2026 KServe study makes this concrete. It compared object-store downloads, modelcar sidecars, OCI fetch paths, and native Kubernetes image volumes for artifacts sized like 1B, 7B, and 70B fp16 model weights. The headline is hard to ignore: for a 70B-class artifact, node-cached OCI delivery made warm replica addition take seconds, while object-store re-download took tens of minutes.

That is not a small optimization.

That is the difference between “we can scale this service” and “we can schedule pods that wait sadly.”

The first cold pull can still be expensive. OCI does not magically delete physics. Container runtimes may write blobs and unpack layers in ways that cost more on the first pull. But once the artifact is local, the platform has something object-store bootstrap scripts often do not: a cache path the node and runtime already understand.

kserve modelcars show the practical shape

KServe’s Modelcars feature is a useful signal because it is not a thought experiment.

The model is packaged as an OCI image. The InferenceService points at an oci:// storage URI. KServe adds a sidecar that exposes the model content to the runtime, using the image as the delivery unit instead of copying everything through the traditional storage initializer path.

There are rough edges, of course. This is still infrastructure, not fairy dust. Teams need to enable the feature, build the model image correctly, push it to a registry, choose tags and pull policies carefully, and understand the runtime behavior.

But the shape is right.

Registries already know how to distribute large immutable artifacts. Nodes already know how to cache pulled content. Kubernetes operators already understand image references, pull secrets, policies, and rollout behavior. Platform teams already have opinions about registries, mirrors, vulnerability scanning, signatures, and admission control.

Modelcars take advantage of that muscle memory.

They also make one mistake more obvious: using latest for model delivery is just as sloppy as using latest for application images. If the model affects production behavior, the reference needs to be specific. Better yet, it needs to be digest-pinned.

Tags are names.

Digests are identity.

That difference matters when the model is the product.

image volumes make the idea more native

Kubernetes Image Volumes are another important piece of the story.

The feature came from KEP-4639 and graduated to beta in Kubernetes 1.33. The basic idea is straightforward: a pod can mount an OCI artifact as a read-only volume. That separates “run this container” from “mount this artifact”, which is exactly the split model serving needs.

Model weights are not always part of the serving runtime image. In fact, they often should not be. The runtime changes at one cadence. The model changes at another. The model may be huge. The runtime may be small. Rebuilding the whole application image every time the weights move is not always the cleanest contract.

Image volumes let Kubernetes treat the model as a mounted artifact instead of pretending it is either application code or an opaque download.

That unlocks a cleaner deployment vocabulary:

  • serving runtime image
  • model artifact reference
  • model artifact digest
  • pull policy
  • read-only mount
  • node cache behavior
  • rollout and rollback tied to explicit artifact identity

This is the kind of boring vocabulary platform teams can govern.

It is also the vocabulary incident responders need. When a bad model reaches production, people should not have to reconstruct which bootstrap script downloaded which file from which bucket at which moment. They should be able to ask: what model artifact was deployed, what digest was it, where did it come from, who approved it, and how do we roll it back?

performance is the easy sell

The performance argument will get most teams interested first.

Cold starts hurt. Large model pulls hurt. Duplicate downloads hurt. Scale-to-zero sounds great until the first request after idle waits behind a model transfer that feels less like elasticity and more like a loading screen from 2007.

OCI delivery helps because cache semantics are part of the platform’s existing behavior. A node that already has the artifact can add replicas without paying the full transfer cost again. A registry mirror can be closer to the cluster. A pre-pull strategy can be made explicit. The artifact can be promoted through environments in the same general way images are promoted.

That is useful.

But performance is not the deeper reason to care.

The deeper reason is identity.

If the delivery path is “download whatever lives behind this object URL”, the deployment has a weaker relationship to the bytes that actually arrive. You can add checks, and you should. But the default object-store bootstrap pattern does not give Kubernetes the same native reference-to-content relationship it gets from image digests.

That matters for audits. It matters for rollback. It matters for debugging. It matters when a model hub changes content. It matters when a bucket object gets replaced. It matters when a team says “we deployed model v4” and nobody can prove what v4 was.

The platform should not have to take the model’s identity on vibes.

supply chain rules apply to weights too

Software supply chain work has spent years teaching teams to care about images, dependencies, SBOMs, signatures, provenance, and runtime verification.

Then AI arrived and many teams immediately started downloading hundred-gigabyte artifacts from wherever the research workflow left them.

That is not sustainable.

Model weights are executable influence over production behavior. They may not be binaries in the traditional sense, but they can change decisions, outputs, security posture, cost, latency, and user experience. If a compromised base image deserves attention, a compromised model artifact deserves attention too.

OpenSSF Model Signing points in the right direction. Its project goal is to support signing and verification for ML models across model formats and sizes, including workflows where the team training the model is not the same team deploying it. That separation is normal now. It is also exactly where supply chain trust gets messy.

The KServe study also highlights this integrity gap. For object-store and hub URI schemes, admission-time verification may not observe the bytes that later arrive in the serving pod. Their proposed serving-time design uses digest pinning and model-signing enforcement in the storage initializer.

That is the right mental model:

Do not just trust the reference.

Bind the reference to the bytes.

Then verify the binding close enough to use that it actually means something.

rollback should be boring

A model rollback should feel like an image rollback.

That sentence sounds obvious until you look at how many model deployments are still wired together with buckets, mutable paths, one-off scripts, and tribal knowledge.

If a new model creates bad outputs, burns too much GPU memory, breaks latency targets, or fails a compliance review, the rollback path should not be “find the old object path and hope the file is still there.”

It should be an explicit artifact reference.

The deployment should say what changed. The registry or artifact store should still have the previous version. The serving configuration should make the model version visible. The issue, incident, or release note should name the digest. The platform should be able to redeploy the prior artifact without rebuilding the whole world.

This is where treating weights as release artifacts pays off. It gives teams a shared operating model:

  • build the artifact
  • sign the artifact
  • push the artifact
  • promote the artifact
  • deploy the artifact by digest
  • verify the artifact at use
  • roll back the artifact when needed

That flow is not glamorous.

Good.

Glamour is rarely what you want from rollback.

the rollback plan should not require archaeology

what i would change first

If I were responsible for a Kubernetes inference platform, I would not start with a grand migration.

I would start with inventory.

Which models are deployed? Where are the weights stored? Which references are mutable? Which deployments pin digests? Which paths download from object storage at startup? Which ones rely on node cache? Which ones re-download on scale-out? Which ones can prove artifact integrity? Which ones have a tested rollback path?

Then I would measure cold and warm startup separately.

A platform that only reports “pod started in X minutes” is hiding the interesting part. Break out scheduling time, image pull time, model delivery time, runtime initialization time, and readiness time. Then test the boring cases: first replica on a fresh node, second replica on a warm node, restart after eviction, scale from zero, scale from one to N.

After that, I would pick one large model and move it to an OCI-based path.

Not every model needs this immediately. Small artifacts and low-change internal models may be fine where they are. But the first model that is large enough to distort autoscaling deserves the full treatment: digest-pinned OCI artifact, documented cache behavior, signature verification where practical, and a rollback runbook.

Finally, I would make object-store delivery explicit.

Object storage is not bad. It is useful infrastructure. But if the serving path downloads from S3, GCS, or a hub at startup, the deployment should document how integrity is checked, whether the reference is mutable, how the file is cached, how re-downloads behave, and how rollback works.

“It downloads the model” is not a production contract.

the punchline

The model is not just data anymore.

At small scale, that sentence may sound dramatic. At large scale, it is just operationally true.

When model weights are big enough to dominate startup, expensive enough to affect scaling policy, important enough to change user-visible behavior, and sensitive enough to require provenance, they stop being a side file. They become part of the release.

Kubernetes teams already know how to operate releases. They know images, registries, digests, pull policies, rollouts, cache behavior, admission checks, runtime verification, and rollback. The AI platform should reuse that discipline instead of inventing a parallel world where giant blobs arrive by hope.

Package the model like an artifact.

Pin it like an artifact.

Verify it like an artifact.

Roll it back like an artifact.

Once a model is large enough to page the platform team, it is not a blob anymore.

It is a release artifact.

references

To test my projects, I use Railway. If you want $20 USD to get started, use this link.

This post is licensed under CC BY 4.0 by the author.