hf-cloud-serving-image-selection
What it does
This skill chooses the correct serving container for a model before it is deployed to SageMaker. It is for people hosting open models who want to avoid health check failures caused by a wrong image.
When to use it
- βWhen you want to deploy a language, embedding or reranker model to a SageMaker endpoint.
- βWhen you need to find the current image address for a serving container.
- βWhen a deployment fails its health check and you suspect the serving image.
Skill link
https://github.com/huggingface/skills/blob/main/skills/hf-cloud-serving-image-selection/SKILL.mdCopy it and paste it into your AI (Claude, ChatGPT or Cursor), asking it to follow the instructions.
How to use
The easiest way: copy the message and paste it into your AI. It reads the skill and follows the instructions.
Ready-to-paste message
For Claude Code, Codex or Cursor: run it in your project folder and the skill gets installed.
Download the SKILL.md and drop it into your agentβs skills folder.
Example of what to ask your AI
βPick the right serving image for this embedding model on SageMaker and give me its current address.β
5 new skills a week. 1 minute to read.
How it works
The AI compares the serving images that fit the model type and prefers Hugging Face images unless there is a verified reason not to. It looks up the current image address in AWS's published catalog of containers.
Technical content (original SKILL.md)
Original text by the author, straight from GitHub.
Serving Image Selection
The serving container is the single thing most likely to break a SageMaker deployment that "looked correct on paper". Wrong container, stale tag, or the wrong AMI β all produce the same opaque Failed to pass health check error.
Rule zero: HuggingFace images always win
When both a HuggingFace-curated family (huggingface-vllm, huggingface-vllm-omni, huggingface-sglang, tei, huggingface-pytorch-inference) and a generic family (vllm, vllm-omni, sglang, djl-inference) can serve the model, the HuggingFace one is mandatory, not preferred. The only valid reasons to use a generic image:
- Verified incompatibility β the model needs an architecture/modality/feature no available HuggingFace tag supports, confirmed against the catalog (not assumed).
- No HuggingFace tag exists in the target region and mirroring is not an option.
- The HuggingFace image is in "Known-broken images" below.
A newer version number on the generic repo is not a reason. The AWS vllm repo often publishes a higher vLLM version than huggingface-vllm; an older-but-compatible huggingface-vllm tag still wins. "Latest vLLM" is not a requirement anyone stated β compatibility with the model is. If you fall back, record in the deployment log which of the three reasons applied.
Where image URIs come from
Primary source: AWS's official Deep Learning Containers catalog.
URL: https://aws.github.io/deep-learning-containers/reference/available_images/
This page is AWS-maintained and lists every image family with example URIs, tags, CUDA versions, Python versions, and platform (SageMaker vs EC2/ECS/EKS). When picking a URI for a deployment, read it from this page directly β copy the example URL, substitute <region> with the user's region, and pass it to deploy.py --image-uri.
The example URLs use 763104351884 as the account ID for most regions. A few regions use different accounts (e.g. eu-south-1 uses 692866216735). Check the Region Availability page when in doubt.
Exception: none currently. Every image family used by this workflow is now on the AWS catalog page (TEI was added in late 2026). If you encounter a new family that isn't there, mirror it via mirror_image.py and pass the resulting URI directly.
Quick decision
| Model | Container family | How to get the URI |
|---|---|---|
| HuggingFace text-generation LLM (Llama, Qwen, Mistral, etc.) | HuggingFace vLLM | AWS catalog β "HuggingFace vLLM Inference" (ECR repo huggingface-vllm) |
| Same as above, multimodal | HuggingFace vLLM-Omni | AWS catalog β "HuggingFace vLLM-Omni Inference" (ECR repo huggingface-vllm-omni) |
| HuggingFace embeddings | TEI | AWS catalog β "HuggingFace Text Embeddings Inference" |
Encoder / cross-encoder rerankers (BERT-family *ForSequenceClassification) |
TEI | Same as embeddings |
| Generative rerankers (causal-LM, e.g. Qwen3-Reranker) | HuggingFace vLLM | Same as text-generation LLMs β not TEI, see "Rerankers: TEI or vLLM?" |
| Text-to-image / diffusion (Stable Diffusion, FLUX) | DJL Inference | AWS catalog β "DJL Inference" β not HF Inference Toolkit, see "Known-broken images" |
| HuggingFace classifiers, NER, QA, summarization | HF Inference Toolkit (CPU) | AWS catalog β "HuggingFace PyTorch Inference"; GPU tags currently broken β see "Known-broken images" |
| User specifically wants SGLang | HuggingFace SGLang | AWS catalog β "HuggingFace SGLang Inference" |
No compatible huggingface-vllm tag (verified incompatibility or region gap β see "Rule zero") |
vLLM (AWS) | AWS catalog β "vLLM" section β fallback only, never for version freshness |
| User specifically wants DJL-LMI | DJL Inference | AWS catalog β "DJL Inference" |
| Amazon Nova | SageMaker JumpStart | Use JumpStart, not raw endpoint creation |
| Custom inference code | BYOC | User provides URI |
HuggingFace-curated DLCs are mandatory when one is compatible (see "Rule zero"). huggingface-vllm is layered directly on the AWS vLLM DLC β identical SM_VLLM_* env contract and the same cu130 AMI rule β and adds current transformers, current huggingface_hub + hf_xet (avoids the XET-CDN 403 download failures older images hit), and HF performance defaults. It is also what SageMaker SDK v3 auto-routes to. The AWS vllm image is a compatibility escape hatch only; it usually shows a higher vLLM
FAQ
Why does it prefer Hugging Face images?
The skill makes them the default, because they are built for Hugging Face models.
Is a newer version of a generic image a reason to switch?
No. A newer version number alone is not a reason, since compatibility with the model is what matters.
Where do the image addresses come from?
They come from AWS's published Deep Learning Containers catalog.
Details
Original description by the author
Pick the right serving container for a SageMaker model deployment and find its current image URI. Use this skill whenever about to deploy a model to a SageMaker endpoint and an image URI needs to be chosen β including when the user says "deploy this LLM", "host this HuggingFace model", "serve this fine-tuned model", "deploy this embedding model", "host a reranker", "serve a sentence-transformers model", or when about to hardcode any container URI in deployment code. HuggingFace-curated Deep Learning Containers are ALWAYS preferred: HuggingFace vLLM (LLMs and generative rerankers), HuggingFace
repo: huggingface/skills
Popularity
- GitHub stars
- 11k
- Ranking position
- #11771
- License
- Apache-2.0
- Updated
- 10/30/2026
Comments
- β¦
More skills from this repository
hf-cli
11kHelps your agent use the Hugging Face command line tool to download, upload and manage models, datasets, Spaces, repos and the local cache.
hf-cloud-aws-context-discovery
11kHelps your agent find your AWS profile, region and account details before any cloud work, so it does not guess which account to use.
hf-cloud-python-env-setup
11kHelps your agent set up a clean Python environment with a suitable Python version and current libraries before running SageMaker or AWS automation.
hf-cloud-sagemaker-deployment-planner
11kHelps your agent plan how to deploy a model to Amazon SageMaker, choosing real-time, serverless, async or batch hosting with sensible defaults.
Similar skills
openclaw-update
394kHelps your agent update an existing OpenClaw Gateway, choosing the update method that fits how it was installed and keeping your session working.
diagnose-gateway
394kHelps your agent find out why your OpenClaw Gateway is failing by checking settings, channels, and ports without changing anything.
crabbox-apps
394kHelps your agent open and run an app on a temporary cloud machine, then show its view in your chat side panel.