Implementation:SeldonIO Seldon core Seldon Model Unload
| Property | Value |
|---|---|
| Implementation Name | Seldon_Model_Unload |
| Type | External Tool Doc |
| Overview | Concrete CLI tool for unloading models and managing model lifecycle in Seldon Core 2. |
| Implements Principle | SeldonIO_Seldon_core_Model_Lifecycle_Management |
| Workflow | Model_Deployment |
| Domains | MLOps, Kubernetes |
| Source | docs-gb/cli/seldon_model_unload.md:L1-20
|
| External Dependencies | seldon CLI, kubectl |
| Last Updated | 2026-02-13 00:00 GMT |
Description
The seldon model unload command removes a model from the Seldon Core 2 scheduler, triggering the inference server to unload the model from memory and free associated resources. This is the primary tool for decommissioning models and managing server capacity. For rolling updates (deploying a new version of an existing model), the seldon model load command is used instead with an updated Model CRD, and the scheduler handles the version transition automatically.
The equivalent operation via kubectl is kubectl delete model <name>, which removes the Model custom resource and triggers the same unload process through the Kubernetes operator.
Code Reference
Source: docs-gb/cli/seldon_model_unload.md:L1-20
CLI Signature:
seldon model unload <modelName> [--scheduler-host string]
Alternatives:
# Unload via kubectl
kubectl delete model <name>
# Rolling update (load new version, scheduler transitions automatically)
seldon model load -f <updated.yaml>
Key Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
modelName |
string (positional) | (required) | Name of the model to unload from the inference server |
-f / --file-path |
string | (none) | Model manifest file path (alternative to positional name for unload-by-file) |
--scheduler-host |
string | "0.0.0.0:9004" |
Address of the Seldon scheduler gRPC endpoint |
--force |
boolean | false | Force the unload operation in control plane mode |
-h / --help |
boolean | false | Display help information for the command |
I/O Contract
Inputs
| Input | Type | Description |
|---|---|---|
| Model name | string | The name of a currently deployed Seldon Core 2 model to unload |
| Updated model YAML (for rolling update) | File path | A Model CRD with updated storageUri pointing to the new model version
|
Outputs
| Output | Type | Description |
|---|---|---|
| Unload confirmation | JSON | Empty JSON {} on successful unload from the scheduler
|
| Traffic shift (rolling update) | Scheduler event | Traffic gradually shifted to the new model version, old version drained and unloaded |
Usage Examples
Basic Model Unload
# Unload a model by name
seldon model unload iris
Unload via kubectl
# Delete the Model custom resource
kubectl delete model iris
Rolling Update to New Version
# Update the storageUri in the YAML to point to v2 artifact
# samples/models/sklearn1-v2.yaml:
# storageUri: "gs://seldon-models/mlserver/iris/v2"
# Resubmit the updated manifest
seldon model load -f samples/models/sklearn1-v2.yaml
# Wait for the new version to be ready
seldon model status iris -w ModelAvailable
# Verify inference works with the new version
seldon model infer iris \
'{"inputs": [{"name": "predict", "shape": [1, 4], "datatype": "FP32", "data": [[5.1, 3.5, 1.4, 0.2]]}]}'
Full Lifecycle Workflow
# Step 1: Deploy initial model
seldon model load -f samples/models/sklearn1.yaml
seldon model status iris -w ModelAvailable
# Step 2: Run inference
seldon model infer iris \
'{"inputs": [{"name": "predict", "shape": [1, 4], "datatype": "FP32", "data": [[5.1, 3.5, 1.4, 0.2]]}]}'
# Step 3: Deploy updated model (rolling update)
seldon model load -f samples/models/sklearn1-v2.yaml
seldon model status iris -w ModelAvailable
# Step 4: Verify new version
seldon model infer iris \
'{"inputs": [{"name": "predict", "shape": [1, 4], "datatype": "FP32", "data": [[5.1, 3.5, 1.4, 0.2]]}]}'
# Step 5: Decommission when no longer needed
seldon model unload iris
Knowledge Sources
- Repository: https://github.com/SeldonIO/seldon-core
- Documentation: https://docs.seldon.io/projects/seldon-core/en/v2/
Related Pages
- SeldonIO_Seldon_core_Seldon_Model_Unload implements SeldonIO_Seldon_core_Model_Lifecycle_Management
- SeldonIO_Seldon_core_Seldon_Model_Load is reused for rolling updates by SeldonIO_Seldon_core_Seldon_Model_Unload
- SeldonIO_Seldon_core_Seldon_Model_Status verifies updates after SeldonIO_Seldon_core_Seldon_Model_Unload
- SeldonIO_Seldon_core_Seldon_Model_Infer validates new versions after SeldonIO_Seldon_core_Seldon_Model_Unload
- Environment:SeldonIO_Seldon_core_Kubernetes_Cluster_Environment
- Heuristic:SeldonIO_Seldon_core_Model_Load_Timeout_Tip