Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update docs to use Hub #481

Merged
merged 2 commits into from
Sep 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion docs/src/docs/next-steps.md
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,8 @@ kit inspect mymodel:challenger

## Tag ModelKits and Keep Your Registry Tidy

### Tag Command

Tagging is a great way to version your ModelKits as they move through the development lifecycle. For example, during development the model I'm working on currently may always be tagged as the `latest` so my team knows which is most current. At the same time the model that's operating in production for my customers may be tagged the `champion`.

However, after testing my latest model, if I find that its scores are much higher than the current champion model I may tag it `challenger` so everyone knows that this is likely to be the next model we deploy to production, replacing our current champion model.
Expand Down Expand Up @@ -293,7 +295,11 @@ mymodel challenger Rajat Finetuning_SLM 13.1 MiB sha256:f268a74f
mymodel champion Rajat Finetuning_SLM 13.1 MiB sha256:f268a74ff85a00f2a68400dfc17b045bc7c1638da7f096c7ae400ad5bdfd520c
```

However, we no longer want this ModelKit to be tagged as `challenger` since it's the `champion` now. Let's [remove](./cli/cli-reference.md#kit-remove) it from our registry to keep things clean:
### Remove Command

Sometimes you want to remove a ModelKit that you've packed and stored in the repository. The `kit remove` command comes to the rescue.

In this case, we no longer want the `challenger` ModelKit since it's a duplicate of the `champion` now. [Removing it](./cli/cli-reference.md#kit-remove) from our registry will keep things clean and clearer for other users:

```sh
kit remove mymodel:challenger
Expand Down
8 changes: 4 additions & 4 deletions docs/src/docs/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,19 @@ Bringing everything together is the Kit Command Line Interface (CLI). The Kit CL

## The Goal of KitOps

The primary goal of KitOps is to bridge the gaps between data science, software development, and operational deployment. By providing a standard pacakaging and versioning solution for AI/ML projects, KitOps drives greater speed, security, and collaboration for teams working with models.
The primary goal of KitOps is to bridge the gaps between data science, software development, and operational deployment. By providing a standard packaging and versioning solution for AI/ML projects, KitOps drives greater speed, security, and collaboration for teams working with models.

### 👩‍💻 For application developers

KitOps clears the path to use AI/ML with your existing tools and applications. No need to be an AI/ML expert, KitOps lets you concentrate on integrating AI/ML models into your applications, while Kit handles the packaging and sharing.

### 👷 For DevOps teams

ModelKits fit into your existing processes and the Kit CLI lets you pack or unpack ModelKit artifacts in the pipelines and automations you have proven over the last decade.
ModelKits fit into your existing processes and the Kit CLI lets you pack or unpack ModelKit artifacts in the pipelines and automation you have proven over the last decade.

### 👩‍🔬 For data scientists

KitOps enables you to innovate in AI/ML without the usual infrastructure distractions. It simplifies dataset and model managementand sharing, fostering closer collaboration with developers. With KitOps, you can spend more time experimenting and less time grappling with traditional software development tools.
KitOps enables you to innovate in AI/ML without the usual infrastructure distractions. It simplifies dataset and model management and sharing, fostering closer collaboration with developers. With KitOps, you can spend more time experimenting and less time grappling with traditional software development tools.

## Benefits of KitOps

Expand All @@ -39,7 +39,7 @@ KitOps is not just another tool; it's a comprehensive CLI and packaging system s
### 📊 Management of Unstructured Datasets
AI/ML projects often deal with large, unstructured datasets, such as images, videos, and audio files. KitOps simplifies the versioning and sharing of these datasets, making them as manageable as traditional code.

### 🤝 Synchronised Data and Code Versioning
### 🤝 Synchronized Data and Code Versioning
One of the core strengths of KitOps is its ability to keep data and code versions in sync. This crucial feature solves the reproducibility issues that frequently arise in AI/ML development, ensuring consistency and reliability across project stages.

### 🚀 Deployment Ready
Expand Down
47 changes: 18 additions & 29 deletions docs/src/docs/quick-start.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,8 @@ import vGaTrack from '@theme/directives/ga'

In this guide, we'll use ModelKits and the kit CLI to easily:
* Package up a model, notebook, and datasets into a single ModelKit you can share through your existing tools
* Push the ModelKit package to a public or private registry
* Push that versioned ModelKit package to a registry
* Grab only the assets you need from the ModelKit for testing, integration, local running, or deployment
* Run an LLM locally to speed app integration, testing, or experimentation

## Before we start...

Expand All @@ -25,14 +24,14 @@ Check that the Kit CLI is properly installed by using the [version command](./cl
kit version
```

You'll see information about the version of Kit you're running. If you get an error check to make sure you have [Kit installed](./cli/installation.md) and in your path.
You'll see information about the version of Kit you're running. If you get an error check to make sure you have [Kit installed and in your path](./cli/installation.md).

### 2/ Login to Your Registry

You can use the [login command](./cli/cli-reference.md#kit-login) to authenticate with any OCI v1.1-compatible container registry. Here we'll pull ModelKits from [Jozu Hub](https://jozu.ml/discover), but we'll use **GitHub Registry** to push (the Jozu Hub only supports pull, although push is being worked on now).
You can use the [login command](./cli/cli-reference.md#kit-login) to authenticate with any OCI v1.1-compatible container registry - local or remote. In this guide we'll use the [Jozu Hub](https://jozu.ml/discover) because it's free to sign-up and provides more detail on what's inside each ModelKit and whether it's signed or has provenance. You can substitute your own repository if preferred.

```sh
kit login ghcr.io
kit login jozu.ml
```

After entering your username and password, you'll see `Log in successful`. If you get an error it may be that you need an HTTP vs HTTPS (default) connection. Try the login command again but with `--plain-http`.
Expand All @@ -48,8 +47,10 @@ You can grab <a href="https://jozu.ml/discover"
location: 'docs/quick-start'
}">any of the ModelKits</a> from the Jozu Hub, but we've chosen a fine-tuned model based on Llama3.

The unpack command will unpack the ModelKit contents to the current directory by default. If you want it unpacked to a specific directory use the `-d /path/to/unpacked`.

```sh
kit unpack jozu.ml/jozu/fine-tuning:tuned
kit unpack jozu.ml/jozu/fine-tuning:latest
```

You'll see a set of messages as Kit unpacks the configuration, code, datasets, and serialized model. Now list the directory contents:
Expand All @@ -59,11 +60,11 @@ ls
```

You'll see:
* A Llama3 model
* A LoRA adapter
* A training dataset
* A README file
* A Kitfile
* A README file
* A Llama3 model in GGUF format
* A LoRA adapter in GGUF format
* A training dataset

The [Kitfile](./kitfile/kf-overview.md) is the manifest for our ModelKit, the serialized model, and a set of files or directories including the adapter, dataset, and docs. Every ModelKit has a Kitfile and you can use the info and inspect commands to view them from the CLI (there's more on this in our [Next Steps](next-steps.md) doc).

Expand All @@ -81,46 +82,34 @@ You'll see the column headings for an empty table with things like `REPOSITORY`,

Since our repository is empty we'll need use the [pack command](./cli/cli-reference.md#kit-pack) to create our ModelKit. The ModelKit in your local registry will need to be named the same as your remote registry. So the command will look like: `kit pack . -t [your registry address]/[your repository name]/mymodelkit:latest`

In my case I am pushing to the `jozubrad` repository:
In my case I am pushing to the `brad` repository on [Jozu Hub](https://jozu.ml/). You'll need to substitute the name of your own repository:

```sh
kit pack . -t ghcr.io/jozubrad/mymodelkit:latest
kit pack . -t jozu.ml/brad/quick-start:latest
```

You'll see a set of `Saved ...` messages as each piece of the ModelKit is saved to the local repository.

Checking your local registry again you should see an entry:
Check your local registry again:

```sh
kit list
```

The new entry will be named based on whatever you used in your pack command.
You should see an entry named based on whatever you used in your pack command.

### 6/ (Optional) Remove a ModelKit from a Local Repository

Let's pretend that the `pack` command we ran in the previous step contained a typo in the ModelKit's repository name causing the word "model" to be entered as "modle". The output from the `kit list` command would display the ModelKit as:
If you have a typo when packing a ModelKit you can easily remove it from your repository and try again. The [Next Steps guide includes information on how to remove ModelKits](./next-steps.md#remove-command).

```sh
ghcr.io/jozubrad/mymodlekit:latest
```

To correct this, we would `remove` the misspelled ModelKit from our local repository using the [remove command](./cli/cli-reference.md#kit-remove), being sure to provide reference the ModelKit using its mispelled name:

```sh
kit remove ghcr.io/jozubrad/mymodlekit:latest
```

Next, we would repeat the `kit pack` command in the previous step, being sure to provide the correct repository name for our ModelKit.
Once you've removed the mistaken ModelKit from the repository, you can repeat the `kit pack` command in the previous step, being sure to provide the correct repository name for your ModelKit.

### 7/ Push the ModelKit to a Remote Repository

The [push command](./cli/cli-reference.md#kit-push) will copy the newly built ModelKit from your local repository to the remote repository you logged into earlier. The naming of your ModelKit will need to be the same as what you see in your `kit list` command (REPOSITORY:TAG). You can even copy and paste it. In my case it looks like:

<!-- replace with Jozu Hub once private repos are ready -->

```sh
kit push ghcr.io/jozubrad/mymodelkit:latest
kit push jozu.ml/brad/quick-start:latest
```

### Congratulations
Expand Down