I’m working with AWS SageMaker Model Registry and have a training pipeline that creates and registers a new model package in a ModelPackageGroupName. After that, I have a separate evaluation pipeline that runs later to generate evaluation metrics.
To integrate these evaluation metrics into the model package, I currently delete the existing model package version and recreate it with the updated metrics.
The problem is:
When creating a new model package in the same ModelPackageGroupName, SageMaker automatically assigns an incremented version number (e.g., version 1, then 2, then 3).
Even if I delete the previous model package (e.g., version 2), the next created model package does not reuse that version number, but continues incrementing (next is version 3).
I want to know if there is a way to force SageMaker to reuse the same version number after deletion, so the version stays consistent (for example, delete version 2 and then recreate a version 2 package).
I’m aware of the alternative to create a model package with a fixed name using ModelPackageName instead of ModelPackageGroupName, but in that case you lose the automatic versioning feature.
Is there a best practice or recommended approach to manage model package versioning precisely in SageMaker? Or any solution to update evaluation metrics without creating a new version number?
Thanks in advance for any advice!
1 Answer 1
You can use UpdateModelPackage API to update the metadata of existing model package without re-creating it, and it doesn't cause version increment.
Comments
Explore related questions
See similar questions with these tags.