forked from GokuMohandas/Made-With-ML
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
71b3d50
commit b98bd5b
Showing
15 changed files
with
3,345 additions
and
1,947 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -108,6 +108,7 @@ touch .env | |
```bash | ||
# Inside .env | ||
GITHUB_USERNAME="CHANGE_THIS_TO_YOUR_USERNAME" # ← CHANGE THIS | ||
``` | ||
```bash | ||
source .env | ||
``` | ||
|
@@ -120,8 +121,6 @@ Now we're ready to clone the repository that has all of our code: | |
|
||
```bash | ||
git clone https://github.com/GokuMohandas/Made-With-ML.git . | ||
git remote set-url origin https://github.com/$GITHUB_USERNAME/Made-With-ML.git # <-- CHANGE THIS to your username | ||
git checkout -b dev | ||
``` | ||
|
||
### Virtual environment | ||
|
@@ -289,7 +288,6 @@ python madewithml/evaluate.py \ | |
|
||
### Inference | ||
```bash | ||
# Get run ID | ||
export EXPERIMENT_NAME="llm" | ||
export RUN_ID=$(python madewithml/predict.py get-best-run-id --experiment-name $EXPERIMENT_NAME --metric val_loss --mode ASC) | ||
python madewithml/predict.py predict \ | ||
|
@@ -485,17 +483,23 @@ We're not going to manually deploy our application every time we make a change. | |
<img src="https://madewithml.com/static/images/mlops/cicd/cicd.png"> | ||
</div> | ||
|
||
1. We'll start by adding the necessary credentials to the [`/settings/secrets/actions`](https://github.com/GokuMohandas/Made-With-ML/settings/secrets/actions) page of our GitHub repository. | ||
1. Create a new github branch to save our changes to and execute CI/CD workloads: | ||
```bash | ||
git remote set-url origin https://github.com/$GITHUB_USERNAME/Made-With-ML.git # <-- CHANGE THIS to your username | ||
git checkout -b dev | ||
``` | ||
|
||
2. We'll start by adding the necessary credentials to the [`/settings/secrets/actions`](https://github.com/GokuMohandas/Made-With-ML/settings/secrets/actions) page of our GitHub repository. | ||
|
||
``` bash | ||
export ANYSCALE_HOST=https://console.anyscale.com | ||
export ANYSCALE_CLI_TOKEN=$YOUR_CLI_TOKEN # retrieved from https://console.anyscale.com/o/madewithml/credentials | ||
``` | ||
|
||
2. Now we can make changes to our code (not on `main` branch) and push them to GitHub. But in order to push our code to GitHub, we'll need to first authenticate with our credentials before pushing to our repository: | ||
3. Now we can make changes to our code (not on `main` branch) and push them to GitHub. But in order to push our code to GitHub, we'll need to first authenticate with our credentials before pushing to our repository: | ||
|
||
```bash | ||
git config --global user.name "Your Name" # <-- CHANGE THIS to your name | ||
git config --global user.name $GITHUB_USERNAME # <-- CHANGE THIS to your username | ||
git config --global user.email [email protected] # <-- CHANGE THIS to your email | ||
git add . | ||
git commit -m "" # <-- CHANGE THIS to your message | ||
|
@@ -504,13 +508,13 @@ git push origin dev | |
|
||
Now you will be prompted to enter your username and password (personal access token). Follow these steps to get personal access token: [New GitHub personal access token](https://github.com/settings/tokens/new) → Add a name → Toggle `repo` and `workflow` → Click `Generate token` (scroll down) → Copy the token and paste it when prompted for your password. | ||
|
||
3. Now we can start a PR from this branch to our `main` branch and this will trigger the [workloads workflow](/.github/workflows/workloads.yaml). If the workflow (Anyscale Jobs) succeeds, this will produce comments with the training and evaluation results directly on the PR. | ||
4. Now we can start a PR from this branch to our `main` branch and this will trigger the [workloads workflow](/.github/workflows/workloads.yaml). If the workflow (Anyscale Jobs) succeeds, this will produce comments with the training and evaluation results directly on the PR. | ||
|
||
<div align="center"> | ||
<img src="https://madewithml.com/static/images/mlops/cicd/comments.png"> | ||
</div> | ||
|
||
4. If we like the results, we can merge the PR into the `main` branch. This will trigger the [serve workflow](/.github/workflows/serve.yaml) which will rollout our new service to production! | ||
5. If we like the results, we can merge the PR into the `main` branch. This will trigger the [serve workflow](/.github/workflows/serve.yaml) which will rollout our new service to production! | ||
|
||
### Continual learning | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.