Skip to content

Commit

Permalink
Fix typos, and other small changes in the Model Management Get Starte…
Browse files Browse the repository at this point in the history
…d pages (#5000)

* Fix typos, and other small changes

* Remove id from admon
  • Loading branch information
tapadipti authored Nov 24, 2023
1 parent f6da4fe commit ea75244
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 28 deletions.
35 changes: 18 additions & 17 deletions content/docs/start/model-management/model-cicd.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,21 +17,21 @@ If you are using the example repository, the models are already versioned on a
publicly readable DVC remote so you can access the model from there and use it.
If you are instead using your own repository you need to set up your own DVC
remote and push the data (including models) there. Have a look at our
[Data management guide](/doc/start/data-management/data-versioning#configuring-a-remote)
[Data Management guide](/doc/start/data-management/data-versioning#configuring-a-remote)
to see how this is done.

## Downloading models

It is useful to download model artifacts for example for local testing or for
use in CICD workflows. With models versioned by DVC this can be done easily by
using the Studio UI.
using the DVC Studio UI.

Go to the detailed view of your model, select the desired model version under
the "Version info" and then click on the "Access model" button.

Studio will present you with several ways of downloading models - with the CLI,
in Python code and directly from your web browser. You can see all the web
browser download steps here:
DVC Studio will present you with several ways of downloading models - with the
CLI, in Python code and directly from your web browser. You can see all the
steps to download the model from the web browser here:

<video width="99%" height="540" autoplay loop muted>
<source src="/img/mr-studio-download-model.webm" type="video/webm">
Expand All @@ -54,21 +54,22 @@ $ dvc artifacts get https://github.com/<user>/example-get-started-experiments po
```

Here you just need to replace `<user>` with your GitHub user. This will download
the latest version of the `pool-segmentation` model from the DVC Remote
the latest version of the `pool-segmentation` model from the DVC remote
associated with the Git repository in the URL. You can also specify a different
artifact version or a model registry stage. See the `dvc artifacts get`
documentation for all options.

If you don't have a Studio account at all, you can still use `dvc artifacts get`
to download models, but you will need to provide the correct Git and DVC Remote
credentials manually. You can see more details in the
If you don't have a DVC Studio account at all, you can still use
`dvc artifacts get` to download models, but you will need to provide the correct
Git and DVC remote credentials manually. You can see more details in the
[documentation](/doc/command-reference/artifacts/get#description).

## Connecting model registry actions to your CICD

As we [noted](/docs/start/model-management/model-registry#GTO-tip) in the model
registry chapter, all DVC model registry actions are captured in your Git
repository as Git tags with a specific format.
As we noted in the
[model registry chapter](/doc/start/model-management/model-registry), all DVC
model registry actions are captured in your Git repository as Git tags with a
specific format.

This also means that we can create CICD actions in our Git repository which will
be triggered whenever versions are registered or stages are assigned.
Expand Down Expand Up @@ -176,17 +177,17 @@ GitHub repository as a
[secret](https://docs.github.com/en/actions/security-guides/using-secrets-in-github-actions)
to manage authentication with the
[DVC remote storage](https://dvc.org/doc/user-guide/data-management/remote-storage#remote-storage).
This way we only need to keep the Studio token saved on GitHub and let Studio
manage the specific storage credentials for us.
This way we only need to keep the DVC Studio token saved on GitHub and let
Studio manage the specific storage credentials for us.

Finally, `github.server_url` and `github.repository` are
[default environmental variables in GitHub](https://docs.github.com/en/actions/learn-github-actions/contexts#github-context)
which together form the URL of our repository on GitHub. We could of course also
specify the URL manually.

If you don't use Studio, you can still use `dvc artifacts get` but you will need
to keep your remote storage credentials on GitHub and use them to configure DVC
in the CICD workflow. You will also need to checkout the repository in the
If you don't use DVC Studio, you can still use `dvc artifacts get` but you will
need to keep your remote storage credentials on GitHub and use them to configure
DVC in the CICD workflow. You will also need to checkout the repository in the
workflow. You can see more details in the
[documentation](/doc/command-reference/artifacts/get#description).

Expand Down
22 changes: 11 additions & 11 deletions content/docs/start/model-management/model-registry.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ up a model registry where we can discover, share, deploy and audit all our
models and which will serve as the single source of truth for our model
management.

<admon type="tip" id="GTO-tip">
<admon type="tip">

Behind the scenes, DVC Studio uses a command line tool called
[GTO](<(/doc/gto)>) for most model registry actions.
Behind the scenes, DVC Studio uses a command line tool called [GTO](/doc/gto)
for most model registry actions.

With GTO you can also set up the model registry locally without DVC Studio. You
can see how this is done in the expandable "Under the hood" sections in this
Expand All @@ -37,7 +37,7 @@ to set it up locally.

To then perform the model registry actions in this guide, follow
[these steps](/doc/studio/user-guide/experiments/create-a-project#connect-to-a-git-repository-and-add-a-project)
to sign in to DVC Studio, connect it to your GitHub account and add your forked
to sign in to DVC Studio, connect it to your Git account and add your forked
repository as a DVC Studio project.

</details>
Expand Down Expand Up @@ -102,12 +102,12 @@ registry.

Now we just need to run the Python script which includes this code to cache and
register the model. If you are
[following](/docs/start/model-management/model-registry#follow-along-instructions)
[following](/doc/start/model-management/model-registry#follow-along-instructions)
our example repository then this has already been done and we can continue to
the next section.

If you are building your own repository, you will need to run the script and
push the result to your Git remote (GitHub) yourself.
push the result to your Git remote (e.g., GitHub) yourself.

<details id="push-click-to-see-other-ways-to-add-models">

Expand Down Expand Up @@ -163,9 +163,9 @@ in your Git repository!
It also allows you to use GTO directly instead of the DVC Studio UI to manage
your model lifecycle. That can be useful for example if you want to trigger
certain model registry actions programmatically. You can learn more about the
details of GTO in its [documentation](/docs/gto).
details of GTO in its [documentation](/doc/gto).

If you don't have a Studio account at all, you will have to manage a model
If you don't have a DVC Studio account at all, you will have to manage a model
registry separately for each Git repository however.

</details>
Expand Down Expand Up @@ -253,7 +253,7 @@ and denote that it is no longer in the "dev" stage. First, assign the model
version to the "prod" stage just like we did with the "dev" stage in the
previous section.
Now, to remove the "dev" stage from our model version 1.0.0 and it assigned only
Now, to remove the "dev" stage from our model version 1.0.0 and assign it only
to "prod", follow these steps:
<video width="99%" height="540" autoplay loop muted>
Expand All @@ -265,7 +265,7 @@ from the registry entirely. To see how, have a look at the
[documentation](/doc/studio/user-guide/model-registry/remove-a-model-or-its-details).
The detailed view of our model in the registry should now match what we see
[in our example](<(https://studio.iterative.ai/team/Iterative/models/b3P4bcYIrGYdzyjqzsf9Xw==/pool-segmentation/v1.0.0)>).
[in our example](https://studio.iterative.ai/team/Iterative/models/b3P4bcYIrGYdzyjqzsf9Xw==/pool-segmentation/v1.0.0).
<details id="under-the-hood-removing-stages">
Expand All @@ -287,7 +287,7 @@ you should see something like this:
![Model history](/img/mr-model-history.png)
As we noted
[above](/docs/start/model-management/model-registry#under-the-hood-model-registry),
[above](/doc/start/model-management/model-registry#under-the-hood-model-registry),
DVC uses special Git tags to keep track of model registry actions, so all of
this history is actually stored directly in your Git repository. DVC Studio can
parse these tags and show them to us in a user-friendly way.
Expand Down

0 comments on commit ea75244

Please sign in to comment.