dstack decouples the development of applications from the development of ML models by offering an ML registry. This way, one can develop ML models, push them to the registry, and then later pull these models from applications.
dstack's ML Registry supports
Here's a very simple example of how to push a model to
from sklearn import datasetsfrom sklearn import svmimport dstack as dsdigits = datasets.load_digits()clf = svm.SVC(gamma=0.001, C=100.)clf.fit(digits.data[:-1], digits.target[:-1])url = ds.push("clf_app", clf)print(url)
Now, if you click the URL, it will open the following page:
Here you can see the snippet of how to pull the model from an application or from anywhere else:
import dstack as dsmodel = ds.pull('/dstack/clf_app')
Also, here you can edit a
README.md file that will provide documentation on how to use this model.
Check out the following tutorial on how to build an application that uses a simple ML model: