HUB
Sign inSign up
tei logo

swaleio/tei

By swaleio

•Updated 1 day ago

Hugging Face Text Embeddings Inference for Swale GPU runner tasks. Backs the tei-serve task.

Image
0

328

swaleio/tei repository overview

⁠tei

Swale-built image backing the tei-serve task definition. It runs Hugging Face's Text Embeddings Inference⁠ (TEI) server, which serves embedding, reranker and sequence-classification models over HTTP, on top of TEI's own CUDA image, adjusted for how Swale runs a task.

  • Base: TEI's cuda-<version> image, which holds a build of the server for each GPU generation (including the A100 and H100) and an entrypoint that picks the one for the GPU it finds
  • Changes: the Hub model cache moves from /data, which a task cannot write, to the task's home directory, unless HUGGINGFACE_HUB_CACHE names another; the default port is 8080 rather than 80; the image records TEI's version
  • User: non-root swale (uid 1000)
  • WORKDIR /mnt/workspace, ENTRYPOINT a wrapper that starts TEI's own entrypoint

⁠Invocation

A task definition's exec.args are the server's options: ["--model-id", "<repo id or directory>", "--hostname", "0.0.0.0", "--port", "8080"]. TEI reads its listen address from HOSTNAME when --hostname is not given, which in a container holds the container's host name, so pass it.

⁠GPU

The image starts only where nvidia-smi finds a GPU; on a CPU compute type it exits at once.

⁠Tags

Each tag is the TEI version the image packages, such as 1.10.0. A rebuild that keeps that version, to pick up a fixed base image or wrapper, adds -r1, -r2, and so on. A tag is never reused; latest follows the newest publish.

⁠Building

From the repository root:

docker build -t swaleio/tei:dev images/tei

Merging a change under images/tei publishes the image under its next tag; task definitions reference it by digest.


Built from images/tei⁠ in the swaleio/task-definitions⁠ repository. For how a task definition references an image, see the task definition reference⁠ in the Swale documentation⁠.

The Dockerfile and entrypoint are covered by the MIT License⁠. Text Embeddings Inference is Apache-2.0-licensed; its license text ships inside the image in /usr/share/licenses/text-embeddings-inference.

This image also contains software from other projects, each under its own license. The license texts its Ubuntu packages ship are inside the image, in /usr/share/doc/<package>/copyright. Source code for its GPL and LGPL components: https://launchpad.net/ubuntu/+source/<source-package>/<version>. We also provide that source code on request: see Third-party software⁠.

It also contains NVIDIA software, which is not open source. NVIDIA licenses it under the NVIDIA Deep Learning Container License⁠, which you accept by pulling or using this image; a copy is at /NGC-DL-CONTAINER-LICENSE.

Tag summary
Recent tags
Content type
Image
Digest
sha256:d0916d018…
Size
2.9 GB
Last updated
1 day ago
docker pull swaleio/tei:latest