Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
text-generation-inference
Commits
e114d874
Unverified
Commit
e114d874
authored
Feb 06, 2023
by
OlivierDehaene
Committed by
GitHub
Feb 06, 2023
Browse files
feat(ci): push to AML registry (#56)
parent
a0dca443
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
21 additions
and
9 deletions
+21
-9
.github/workflows/build.yaml
.github/workflows/build.yaml
+7
-0
aml/README.md
aml/README.md
+10
-3
aml/deployment.yaml
aml/deployment.yaml
+3
-3
aml/model.yaml
aml/model.yaml
+1
-3
No files found.
.github/workflows/build.yaml
View file @
e114d874
...
@@ -35,6 +35,12 @@ jobs:
...
@@ -35,6 +35,12 @@ jobs:
username
:
${{ secrets.TAILSCALE_DOCKER_USERNAME }}
username
:
${{ secrets.TAILSCALE_DOCKER_USERNAME }}
password
:
${{ secrets.TAILSCALE_DOCKER_PASSWORD }}
password
:
${{ secrets.TAILSCALE_DOCKER_PASSWORD }}
registry
:
registry.internal.huggingface.tech
registry
:
registry.internal.huggingface.tech
-
name
:
Login to Azure Container Registry
uses
:
docker/login-action@v2.1.0
with
:
username
:
${{ secrets.AZURE_DOCKER_USERNAME }}
password
:
${{ secrets.AZURE_DOCKER_PASSWORD }}
registry
:
db4c2190dd824d1f950f5d1555fbadf0.azurecr.io
-
name
:
Extract metadata (tags, labels) for Docker
-
name
:
Extract metadata (tags, labels) for Docker
id
:
meta
id
:
meta
uses
:
docker/metadata-action@v4.3.0
uses
:
docker/metadata-action@v4.3.0
...
@@ -44,6 +50,7 @@ jobs:
...
@@ -44,6 +50,7 @@ jobs:
images
:
|
images
:
|
ghcr.io/huggingface/text-generation-inference
ghcr.io/huggingface/text-generation-inference
registry.internal.huggingface.tech/api-inference/community/text-generation-inference
registry.internal.huggingface.tech/api-inference/community/text-generation-inference
db4c2190dd824d1f950f5d1555fbadf0.azurecr.io/text-generation-inference
tags
:
|
tags
:
|
type=semver,pattern={{version}}
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}.{{minor}}
...
...
aml/README.md
View file @
e114d874
```
shell
# Azure ML endpoint
docker build
.
-t
db4c2190dd824d1f950f5d1555fbadf0.azurecr.io/text-generation:0.1
docker push db4c2190dd824d1f950f5d1555fbadf0.azurecr.io/text-generation:0.1
## Create all resources
```
shell
az ml model create
-f
model.yaml
-g
HuggingFace-BLOOM-ModelPage
-w
HuggingFace
az ml model create
-f
model.yaml
-g
HuggingFace-BLOOM-ModelPage
-w
HuggingFace
az ml online-endpoint create
-f
endpoint.yaml
-g
HuggingFace-BLOOM-ModelPage
-w
HuggingFace
az ml online-endpoint create
-f
endpoint.yaml
-g
HuggingFace-BLOOM-ModelPage
-w
HuggingFace
az ml online-deployment create
-f
deployment.yaml
-g
HuggingFace-BLOOM-ModelPage
-w
HuggingFace
az ml online-deployment create
-f
deployment.yaml
-g
HuggingFace-BLOOM-ModelPage
-w
HuggingFace
```
## Update deployment
```
shell
az ml online-deployment update
-f
deployment.yaml
-g
HuggingFace-BLOOM-ModelPage
-w
HuggingFace
```
```
\ No newline at end of file
aml/deployment.yaml
View file @
e114d874
$schema
:
https://azuremlschemas.azureedge.net/latest/managedOnlineDeployment.schema.json
$schema
:
https://azuremlschemas.azureedge.net/latest/managedOnlineDeployment.schema.json
name
:
bloom-deployment
name
:
bloom-deployment
endpoint_name
:
bloom-inference
endpoint_name
:
bloom-inference
model
:
azureml:bloom:1
model
:
azureml:bloom
-safetensors
:1
model_mount_path
:
/var/azureml-model
model_mount_path
:
/var/azureml-model
environment_variables
:
environment_variables
:
HUGGINGFACE_HUB_CACH
E
:
/var/azureml-model/bloom
WEIGHTS_CACHE_OVERRID
E
:
/var/azureml-model/bloom
-safetensors
MODEL_ID
:
bigscience/bloom
MODEL_ID
:
bigscience/bloom
NUM_SHARD
:
8
NUM_SHARD
:
8
environment
:
environment
:
image
:
db4c2190dd824d1f950f5d1555fbadf0.azurecr.io/text-generation-inference:0.
3.1
image
:
db4c2190dd824d1f950f5d1555fbadf0.azurecr.io/text-generation-inference:0.
2.0
inference_config
:
inference_config
:
liveness_route
:
liveness_route
:
port
:
80
port
:
80
...
...
aml/model.yaml
View file @
e114d874
$schema
:
https://azuremlschemas.azureedge.net/latest/model.schema.json
$schema
:
https://azuremlschemas.azureedge.net/latest/model.schema.json
name
:
bloom-safetensors
name
:
bloom-safetensors
version
:
1
path
:
/data/bloom-safetensors
path
:
./bloom-safetensors
type
:
custom_model
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment