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
f9d0ec37
Unverified
Commit
f9d0ec37
authored
Jan 23, 2023
by
OlivierDehaene
Committed by
GitHub
Jan 23, 2023
Browse files
feat(docker): Make the image compatible with api-inference (#29)
parent
1f570d18
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
4 deletions
+5
-4
Dockerfile
Dockerfile
+3
-3
aml/deployment.yaml
aml/deployment.yaml
+1
-1
router/src/server.rs
router/src/server.rs
+1
-0
No files found.
Dockerfile
View file @
f9d0ec37
...
@@ -26,10 +26,10 @@ FROM nvidia/cuda:11.8.0-devel-ubuntu22.04
...
@@ -26,10 +26,10 @@ FROM nvidia/cuda:11.8.0-devel-ubuntu22.04
ENV
LANG=C.UTF-8 \
ENV
LANG=C.UTF-8 \
LC_ALL=C.UTF-8 \
LC_ALL=C.UTF-8 \
DEBIAN_FRONTEND=noninteractive \
DEBIAN_FRONTEND=noninteractive \
MODEL_BASE_PATH=/
var/azureml-model
\
MODEL_BASE_PATH=/
data
\
MODEL_
NAME
=bigscience/bloom \
MODEL_
ID
=bigscience/bloom
-560m
\
QUANTIZE=false \
QUANTIZE=false \
NUM_GPUS=
8
\
NUM_GPUS=
1
\
SAFETENSORS_FAST_GPU=1 \
SAFETENSORS_FAST_GPU=1 \
CUDA_VISIBLE_DEVICES=0,1,2,3,4,5,6,7 \
CUDA_VISIBLE_DEVICES=0,1,2,3,4,5,6,7 \
NCCL_ASYNC_ERROR_HANDLING=1 \
NCCL_ASYNC_ERROR_HANDLING=1 \
...
...
aml/deployment.yaml
View file @
f9d0ec37
...
@@ -5,7 +5,7 @@ model: azureml:bloom:1
...
@@ -5,7 +5,7 @@ model: azureml:bloom:1
model_mount_path
:
/var/azureml-model
model_mount_path
:
/var/azureml-model
environment_variables
:
environment_variables
:
MODEL_BASE_PATH
:
/var/azureml-model/bloom
MODEL_BASE_PATH
:
/var/azureml-model/bloom
MODEL_
NAME
:
bigscience/bloom
MODEL_
ID
:
bigscience/bloom
NUM_GPUS
:
8
NUM_GPUS
:
8
environment
:
environment
:
image
:
db4c2190dd824d1f950f5d1555fbadf0.azurecr.io/text-generation-inference:0.3.1
image
:
db4c2190dd824d1f950f5d1555fbadf0.azurecr.io/text-generation-inference:0.3.1
...
...
router/src/server.rs
View file @
f9d0ec37
...
@@ -197,6 +197,7 @@ pub async fn run(
...
@@ -197,6 +197,7 @@ pub async fn run(
let
app
=
Router
::
new
()
let
app
=
Router
::
new
()
.route
(
"/generate"
,
post
(
generate
))
.route
(
"/generate"
,
post
(
generate
))
.layer
(
Extension
(
shared_state
.clone
()))
.layer
(
Extension
(
shared_state
.clone
()))
.route
(
"/"
,
get
(
health
))
.route
(
"/health"
,
get
(
health
))
.route
(
"/health"
,
get
(
health
))
.layer
(
Extension
(
shared_state
.clone
()));
.layer
(
Extension
(
shared_state
.clone
()));
...
...
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