runpod
Start here when the Runpod lane is unclear: picks the skill for a task (runpod-mcp and the journey playbooks it routes to, such as runpod-serverless-deploy, runpod-pod-deploy, runpod-pod-doctor and runpod-cost-audit; runpodctl, runpod-flash, runpod-companion-clis, runpod-usage, runpod-templates, runpod-build-template, runpod-migrate) and indexes two dozen end-to-end worked examples (golden paths). Use it before any multi-step or provisioning task, even when the lane is clear, to check for a matching golden path; for the Runpod MCP tools, runpod-mcp owns the answer contract, connection and tool rules.
- License 许可
- Apache-2.0
- 最近更新
- 2026-11-12
- Stars
- ★ 49
- Forks
- 10
01 前言 Front Matter
- name
- runpod
- license
- Apache-2.0
- metadata
- { "author": "runpod", "version": "2.1.0", "concepts": [ "runpod-platform", "pod", "serverless-endpoint", "template", "network-volume", "hub-repo" ] }
- description
- Start here when the Runpod lane is unclear: picks the skill for a task (runpod-mcp and the journey playbooks it routes to, such as runpod-serverless-deploy, runpod-pod-deploy, runpod-pod-doctor and runpod-cost-audit; runpodctl, runpod-flash, runpod-companion-clis, runpod-usage, runpod-templates, runpod-build-template, runpod-migrate) and indexes two dozen end-to-end worked examples (golden paths). Use it before any multi-step or provisioning task, even when the lane is clear, to check for a matching golden path; for the Runpod MCP tools, runpod-mcp owns the answer contract, connection and tool rules.
02 资源文件 86
- 参考文档evals/comfyui-pinned-api.eval.md1.9 KB
- 参考文档evals/concurrent-handler.eval.md933 B
- 参考文档evals/consult-golden-path-first.eval.md4.8 KB
- 参考文档evals/hub-authoring-route.eval.md895 B
- 参考文档evals/load-balancer-endpoint.eval.md1.4 KB
- 参考文档evals/mcp-vs-runpodctl-tiebreak.eval.md1.5 KB
- 参考文档evals/multi-region-volume-sync.eval.md1.1 KB
- 参考文档evals/no-unchecked-absence-claims.eval.md1.8 KB
- 参考文档evals/prefer-prebuilt.eval.md1.1 KB
- 参考文档evals/public-endpoint-call.eval.md1.1 KB
- 参考文档evals/route-hub-capabilities.eval.md2.2 KB
- 参考文档evals/route-serverless-observability.eval.md2.8 KB
- 参考文档evals/route-service-vs-endpoint.eval.md1.1 KB
- 参考文档evals/route-template-repair.eval.md1.5 KB
- 参考文档evals/route-templates.eval.md1.2 KB
- 参考文档evals/serverless-streaming.eval.md1.0 KB
- 参考文档evals/serverless-webhook.eval.md972 B
- 参考文档evals/storage-tier-choice.eval.md1.1 KB
- 参考文档evals/template-authoring-route.eval.md1.0 KB
- 参考文档golden-paths/01-ollama-pod/README.md13.1 KB
- 参考文档golden-paths/01-ollama-pod/skill.json1.4 KB
- 参考文档golden-paths/02-comfyui-pod/README.md6.9 KB
- 参考文档golden-paths/02-comfyui-pod/skill.json2.4 KB
- 参考文档golden-paths/02-comfyui-pod/variant-a-from-scratch.md6.0 KB
- 参考文档golden-paths/02-comfyui-pod/variant-b-prebuilt.md6.8 KB
- 参考文档golden-paths/02-comfyui-pod/variant-c-pinned-api.md9.6 KB
- 参考文档golden-paths/03-whisper-endpoint/README.md6.4 KB
- 参考文档golden-paths/03-whisper-endpoint/skill.json2.0 KB
- 参考文档golden-paths/03-whisper-endpoint/variant-a-hub.md6.5 KB
- 参考文档golden-paths/03-whisper-endpoint/variant-b-flash.md6.5 KB
- 参考文档golden-paths/04-finetune-pod.md14.0 KB
- 参考文档golden-paths/05-model-to-endpoint-pipeline.md11.5 KB
- 参考文档golden-paths/06-dev-pod.md12.6 KB
- 参考文档golden-paths/07-network-volume-handoff.md11.1 KB
- 参考文档golden-paths/08-finetune-to-serverless.md15.9 KB
- 参考文档golden-paths/09-custom-serverless-dev-loop/README.md19.1 KB
- 其他golden-paths/09-custom-serverless-dev-loop/template/Dockerfile1.7 KB
- 脚本golden-paths/09-custom-serverless-dev-loop/template/handler.py3.5 KB
- 参考文档golden-paths/09-custom-serverless-dev-loop/template/requirements.txt500 B
- 脚本golden-paths/09-custom-serverless-dev-loop/template/start.sh1.5 KB
- 参考文档golden-paths/10-multi-region-ha-serverless.md23.7 KB
- 参考文档golden-paths/11-public-endpoints.md11.1 KB
- 参考文档golden-paths/12-serverless-streaming.md9.1 KB
- 参考文档golden-paths/13-autoscaling-tuning.md16.2 KB
- 参考文档golden-paths/14-load-balancing-endpoint.md17.3 KB
- 参考文档golden-paths/15-monitor-and-debug.md27.4 KB
- 参考文档golden-paths/16-serverless-webhooks.md10.1 KB
- 参考文档golden-paths/17-serverless-websocket.md20.5 KB
- 参考文档golden-paths/18-concurrent-handler.md11.9 KB
- 参考文档golden-paths/19-three-region-same-file.md18.1 KB
- 参考文档golden-paths/20-model-caching-endpoint.md11.5 KB
- 参考文档golden-paths/21-storage-tiers.md5.8 KB
- 参考文档golden-paths/22-minimal-pod-image/README.md5.4 KB
- 其他golden-paths/22-minimal-pod-image/template/Dockerfile803 B
- 脚本golden-paths/22-minimal-pod-image/template/start.sh805 B
- 参考文档golden-paths/23-minimal-queue-image/README.md5.4 KB
- 其他golden-paths/23-minimal-queue-image/template/Dockerfile436 B
- 脚本golden-paths/23-minimal-queue-image/template/handler.py321 B
- 参考文档golden-paths/23-minimal-queue-image/template/requirements.txt7 B
- 参考文档golden-paths/25-bake-vs-mount/README.md6.7 KB
- 其他golden-paths/25-bake-vs-mount/template/Dockerfile796 B
- 脚本golden-paths/25-bake-vs-mount/template/start.sh426 B
- 参考文档golden-paths/26-template-project/README.md6.7 KB
- 其他golden-paths/26-template-project/template/.dockerignore78 B
- 脚本golden-paths/26-template-project/template/app.py2.1 KB
- 脚本golden-paths/26-template-project/template/check_http.py956 B
- 其他golden-paths/26-template-project/template/Dockerfile.http738 B
- 其他golden-paths/26-template-project/template/Dockerfile.queue649 B
- 脚本golden-paths/26-template-project/template/handler.py368 B
- 其他golden-paths/26-template-project/template/pytorch/.dockerignore50 B
- 脚本golden-paths/26-template-project/template/pytorch/check_lifecycle.py3.9 KB
- 其他golden-paths/26-template-project/template/pytorch/Dockerfile510 B
- 脚本golden-paths/26-template-project/template/pytorch/test_verify.py3.6 KB
- 脚本golden-paths/26-template-project/template/pytorch/verify.py1.9 KB
- 参考文档golden-paths/26-template-project/template/README.md4.7 KB
- 参考文档golden-paths/26-template-project/template/requirements.txt83 B
- 脚本golden-paths/26-template-project/template/test_app.py3.8 KB
- 参考文档golden-paths/26-template-project/template/test_input.json27 B
- 脚本golden-paths/26-template-project/template/workload.py576 B
- 参考文档golden-paths/26-template-project/variant-load-balanced.md3.8 KB
- 参考文档golden-paths/26-template-project/variant-pod.md3.5 KB
- 参考文档golden-paths/26-template-project/variant-pytorch.md6.4 KB
- 参考文档golden-paths/26-template-project/variant-queue.md3.4 KB
- 参考文档golden-paths/27-vllm-pod-to-endpoint.md7.6 KB
- 参考文档golden-paths/README.md14.0 KB
- 参考文档golden-paths/skill.schema.json2.9 KB
03 SKILL.md 正文
Runpod (router)
The entrypoint for the Runpod skills. This skill does no work itself: it picks the lane
and points at the golden path or journey skill that
carries the procedure. For a multi-step or provisioning task, check the worked examples
first and let the matching one pick the lane; otherwise read the matching skill's
SKILL.md next.
Who owns what (one home per rule; the others link to it):
| Topic | Owner |
|---|---|
| Lane choice, MCP-vs-runpodctl matrix, golden-path index | this skill |
| MCP answer contract, MCP connection and auth, MCP tool-use rules, journey routing | runpod-mcp (load it before the first Runpod MCP tool call) |
| Credentials for every lane, tool updates, control-plane check | getting-started.md |
| Deployment loop (prefer prebuilt, plan, verify, teardown) | development-loop.md |
| CUDA floor, Secure vs Community Cloud | gpu-selection.md (steps 3 and 5) |
The lanes
| Lane | Use it for |
|---|---|
| runpod-mcp | Manage infra (pods, endpoints, jobs, templates, volumes, registries, catalog, billing) via structured tool calls — when the Runpod MCP tools are connected in this session. It routes on to the journey skill for the task. |
| runpodctl | Manage the same infra from a terminal/CI/script, including Hub browse/deploy, file transfer (send/receive, network-volume upload/download), SSH keys, doctor setup, and model cache. |
| runpod-flash | Write Python that runs on Runpod serverless with the Runpod SDK — runpod.App with @app.queue/@app.api/@app.task, rp flash dev, rp flash deploy; also maintains or migrates legacy runpod-flash projects. Code-first, not infra management. |
| runpod-companion-clis | Prerequisite artifacts: download a model (hf), build/push an image (docker), repos/releases (gh), other S3 tools against a network volume (aws; runpodctl v3.1.0+ network-volume upload/download is the default for moving files). |
| runpod-usage | Understand how Runpod works before acting — pods vs serverless, building a container, storage, GPU selection, gotchas. Knowledge only. |
| runpod-templates | Official prebuilt pod templates (ComfyUI, PyTorch, …): is there one for this workload, and what does its image ship — ports, paths, autostart, readiness, what's missing on first boot. Reference + routing hub; deploy via runpod-mcp/runpodctl. |
| runpod-build-template | Create or improve a template project from a request, local code, or GitHub: documented Dockerfile, app-specific files, and Pod/queue/load-balanced deployment handoff. |
| runpod-migrate | Move existing code off the GraphQL API or REST v1 onto REST v2 — inventory which parts use which version, rewrite call sites, flag breaking changes. Edits the user's code; does not manage infra. |
These skills are a snapshot; the tools are the source of truth
Every lane wraps something that ships on its own release train and moves faster than this repo. So route with these skills, but take capability and syntax from the tool in front of you:
| Lane | Ask it directly |
|---|---|
| runpodctl | runpodctl --help, runpodctl <resource> <action> --help, runpodctl version. For failure shapes, run a command wrong on purpose and read the JSON |
| runpod-mcp | your client's tool list (/mcp in Claude Code); rules in runpod-mcp |
| runpod-flash | rp --help, rp flash <command> --help, pip show runpod, and the dev/deploy output |
| runpod-companion-clis | that CLI's own --help (hf, gh, docker, aws) |
| runpod-templates | runpodctl template list --type official, template get <id> (its readme is authoritative) |
| REST v2 | the live spec at https://api.runpod.io/v2/openapi.json |
Never tell a user a tool cannot do something without checking first. A missing capability
is the claim most likely to be out of date here, and it is the one a reader has no reason to
reverify — it has already gone stale twice (runpodctl v2.9.0 added serverless health, v2.10.0
added pod logs/serverless logs). If a limit still holds, name the version it holds for
rather than saying "cannot".
Before the first command
- Update the CLI you are about to use (
runpodctl update,rp update; the MCP needs no step). runpodctl before v2.12.0 accepts--stop-after/--terminate-after, which the backend never enforced, so pods kept billing past the deadline. - Check the control plane before infra work:
runpodctl usersucceeds, or/mcpshowsrunpodConnected. If neither works, help the user set up rather than limping on. - MCP OAuth first, a key only when a task needs one: get
RUNPOD_API_KEY(rp loginwith a human at an interactive terminal, elseexport) at the first CLI-only step; with no user in the loop, use the key from the start. Companion CLIs use their own credentials, neverRUNPOD_API_KEY.
Details, install commands and the per-lane key table:
getting-started.md.
How to route
0. Does a worked example already cover this? For anything beyond a single call, check the golden-paths index before picking a lane — a matching path already names the lane(s), the flags, the ordering, and the traps, so routing becomes reading rather than re-deriving. Check it when any of these is true:
- the task needs more than one resource (image + template + endpoint, pod + volume, multi-region, …) or more than one lane
- it provisions something billable, or the user's ask is shaped like "get X running / deployed / working"
- it involves storage, networking, autoscaling, streaming, or debugging a live resource — the areas where the non-obvious ordering is the whole difficulty
- you are about to write a multi-step plan for it
Skip step 0 for a single read or a single CRUD call ("list my pods", "stop pod X", "what GPUs are available") — go straight to the lane. A matching golden path outranks this router's lane table for workflow selection. Its commands do not establish that a capability is CLI-only: choose the execution lane from the live tool surface and the capability matrix below, while preserving the path's ordering and verification steps.
For an explicit request to create or optimize a Dockerfile/template project, match path 26 before generic deployment examples; GP26 is an authoring specification with local checks, not a live-verified deployment. An existing prebuilt does not replace the requested deliverable.
- Conceptual question, or an unmade design choice (serverless vs pod? which GPU? bake the model or mount a volume?) → read runpod-usage first, then continue with the answer.
- Author or improve a template project / Dockerfile, including converting local code or a GitHub repository, or prepare its Hub listing files → runpod-build-template. It delegates build/push mechanics and infrastructure work to their existing lanes. Registering an already-built image as a reusable template ("make a template from my image") and browsing/deploying an existing Hub listing use the infrastructure lanes below; registration needs no new Dockerfile.
- Run a common workload on a pod, or fix a template pod ("run ComfyUI / PyTorch dev box", won't boot, missing models) → runpod-templates — check for an official prebuilt before planning any install, and let it route repairs.
- Write/iterate/ship your own code on Runpod GPUs using its code-first workflow → runpod-flash.
- Produce an artifact (download a model, build+push an image, create a repo release, sync data to a volume) → runpod-companion-clis.
- Migrate existing code between Runpod API versions — "move us to REST v2", "which Runpod API is this repo on?", "what breaks if we upgrade?" → runpod-migrate. (Calling the API to do something is a different job; that is the infra lanes below.)
- Manage infrastructure (create/list/update/delete pods, endpoints,
templates, volumes; list GPUs/data centers; run a serverless job; billing):
- A capability only the CLI has (the runpodctl rows of the matrix below) → runpodctl.
- Otherwise, if the Runpod MCP tools are connected in this session
(
create-pod,list-endpoints, … are available) → runpod-mcp. - Otherwise (shell-only agent, no MCP) → runpodctl.
runpod-mcp vs runpodctl (the overlap)
Both drive the same Runpod API, so they overlap on infra CRUD. Choose by capability first, environment second:
- MCP wins on convenience for simple, structured operations — reads and basic CRUD — when its tools are connected (typed params, no shell quoting).
- runpodctl takes over when an operation needs a capability MCP lacks — even if MCP is connected — and is the only option for a shell-only agent or when the user wants a reproducible command.
Capability matrix (pick the preferred lane per operation):
| Operation | Preferred lane | Why |
|---|---|---|
| List/get anything; start/stop/restart/delete a pod; simple CRUD on endpoints, templates, volumes, registries; catalog; billing | runpod-mcp if connected, else runpodctl | Simple structured ops — MCP is typed and convenient |
| Create a simple pod (one image + one GPU) | runpod-mcp if connected, else runpodctl | Both handle it |
| Create a pod from a template, a CPU pod, or both together | runpod-mcp if connected, else runpodctl | MCP's create-pod takes templateId and, for CPU, a cpu object in place of gpu; template + CPU in one create live-verified 2026-10-29. runpodctl v3 sends the same v2 create, so it is no fallback. Field semantics: runpod-mcp pod creates |
| Create a pod with a multi-GPU priority list | neither: one GPU type per create | v2 create-pod takes one gpu.id, and runpodctl rejects a comma list in --gpu-id (only one gpu id is supported; checked through v3.0.1). Pick one type from the stock read; on a capacity error, retry with the next |
| Browse or deploy an existing Hub listing | runpod-mcp if connected and it exposes the requested operation, else runpodctl | Check the live tool surface; Hub is not a reason by itself to switch to the CLI |
File transfer (send/receive, network-volume upload/download), SSH keys/info, doctor setup, model cache |
runpodctl | MCP has no tool for these |
Invoke a serverless job (run/runsync/status/stream) |
runpod-mcp if connected, else runpodctl | Both lanes have first-class job commands now (runpodctl serverless run/status/health, v2.9.0+); MCP is typed, and only MCP streams a job's incremental output (stream-job) |
| Read pod or worker logs | either — runpod-mcp if connected, else runpodctl | Both lanes read them: MCP stream-pod-logs/stream-worker-logs return parsed frames; runpodctl pod logs/serverless logs emit json lines and --follow (v2.10.0+) |
Rule of thumb: default to MCP for the easy stuff, hand off to runpodctl the moment an op needs a flag/feature MCP doesn't expose.
Deploying a workload (the golden loop)
For any "get <X> running on Runpod" task, follow
development-loop.md: decide pod vs
serverless → provision → set up (only if from-scratch) → verify → deliver → cost-guard +
teardown. Its binding rules, in one line each: prefer a prebuilt
template / Hub worker unless the user asked for a custom template project; pin the CUDA
floor on every GPU create (--min-cuda-version 12.8 / gpu.minCudaVersion: "12.8", 13.0 only for a CUDA-13 image; without it an
image can land on a host too old for it and die at startup or silently run on CPU;
why); default to
Secure Cloud; cache vs network volume is a latency call (download time is not billed, but a cache miss
holds the worker start, so the job queues and the endpoint looks idle); stock picks the data
center, the network volume follows (read per-data-center GPU stock, create the volume once
where the GPU is, and on a stock refusal keep it: retry once there or let the user choose;
why); and verify with a real
request from outside before delivering — "Running"/"ready" does not mean serving.
It branches to two sub-loops:
- Service you open at a URL (Ollama, ComfyUI, dev box) →
runpod-usage/reference/pod-workflows.md(ports + env + volume at creation, SSH-exec install, bind0.0.0.0, poll the proxy URL). Execute in the runpodctl lane. - Request/response API that scales to zero (Whisper, inference) →
runpod-usage/reference/endpoint-workflows.md(Hub worker vs flash vs custom image; invoke/run//runsync; poll job status).
Worked examples (golden paths)
This is step 0 of routing, not an appendix. Two dozen end-to-end scenarios live in
./golden-paths/README.md, each with a status header
(live-verified with a date, spec-checked, or legacy; check it before trusting a path), the
real commands and observed output, plus a Gotchas and a Cost & cleanup section, which is
the part that is expensive to rediscover.
Match the task to a row below and open that path before you plan or call anything. A partial match is still worth opening: the closest path's ordering and gotchas usually transfer even when the model, GPU, or region does not. Only fall through to the lane tables above when nothing here is close.
| Want to… | Golden path |
|---|---|
| Run a server (Ollama/ComfyUI) on a pod at a URL | 01, 02 |
| Deploy a serverless model endpoint (Hub / flash / custom image) | 03, 05 |
| Serve an LLM with vLLM (Pod, load-balancing or Hub queue endpoint) | 27 — vLLM Pod → endpoint; procedure in runpod-vllm |
| Install vLLM or ComfyUI privately on a Pod you already run (pinned, loopback, API-driven) | vLLM: runpod-vllm existing-pod; ComfyUI: 02 Variant C |
| Serve a HuggingFace model without baking it in or a volume (host-cached) | 20 — model caching (--model-reference) |
| Call a ready hosted model (no deploy) | 11 — Public Endpoints |
| Fine-tune, then serve the result | 04, 08 |
| Interactive dev box (SSH / VS Code) | 06 |
| Move data pod → volume → serverless | 07 |
| Custom serverless when flash isn't enough (dual-mode image dev loop) | 09 |
| Create or improve a complete template project from code, a repo or an app request | 26 — project authoring |
| Build a minimal image for a target (pod vs serverless queue) | 22 (pod), 23 (queue); concepts in building-images |
| Decide what to bake into the image vs mount on a network volume | 25 — bake vs mount |
| Pick a network-volume storage tier (standard vs high-performance) | 21 — storage tiers |
| High availability / multi-region serverless (multi-volume + data sync) | 10, 19 (3-region) |
Stream output incrementally (/stream) |
12 |
| Tune autoscaling / raise per-worker throughput | 13 (autoscaling), 18 (concurrency) |
| Load-balancing / HTTP-server or WebSocket worker | 14 (LB), 17 (WebSocket) |
| Get notified on job completion (push, not poll) | 16 — webhooks |
| Check health / debug a failing endpoint | 15 — monitor & debug |
Multi-lane tasks
Sequence is always understand → produce artifacts → manage infra → verify, because infra can only reference artifacts that already exist. Keep each step in one lane, and switch lanes at credential boundaries.
Example — "deploy openai/gpt-oss-20b to a serverless endpoint":
- runpod-usage — serverless vs pod, GPU tier for 20B, bake vs mount vs cache.
- runpod-companion-clis —
hf download …,docker build --platform=linux/amd64 …,docker push. - runpod-mcp or runpodctl — create the endpoint referencing the image + GPU pool.
- Same infra lane — invoke the endpoint / check status to verify.
04 同仓库更多 Skills
runpod-vllm
Serve a Hugging Face model with vLLM on Runpod (Hub worker-vllm queue endpoint, load-balancing endpoint on a vllm/vllm-openai image, or a Pod), sized, CUDA-pinned and verified with a real OpenAI client. Use for any "deploy/serve/test this LLM with vLLM" request or a vLLM deployment that will not boot; defer to runpod-serverless-deploy for non-vLLM engines and runpod-endpoint-ops for an endpoint that already works.
runpodctl
Runpod CLI for managing GPU/CPU workloads from the terminal — pods, serverless endpoints, templates, network volumes, Hub deploys, models, SSH, and file transfer (send/receive, network-volume upload/download). Use for terminal/CI/scripting, SSH setup, `doctor`, or when the Runpod MCP tools are not connected; prefer runpod-mcp for structured tool calls in an MCP-enabled session.
runpod-usage
Explain Runpod architecture and design choices: Pods versus Serverless, GPU/VRAM, image construction, storage, networking, and workload development. For creating or improving a complete template project use runpod-build-template; execute infrastructure with runpodctl/runpod-mcp and code-first work with runpod-flash.
runpod-templates
Find, use, and troubleshoot official Runpod Pod templates, including ComfyUI workflow model metadata repair. For creating or optimizing Dockerfiles and application template projects use runpod-build-template; deploy through runpod-mcp or runpodctl.
runpod-serverless-deploy
Bring any source (a HuggingFace repo, a ComfyUI workflow, a Hub release, a custom container image, a GGUF repo, a Civitai asset, or a community template) to a proven Runpod Serverless endpoint: pick the engine for the modality and model format, size the GPU from the model's real metadata, provision, warm, prove it with one real job, and hand back the URL with what it bills. Deploys an existing source through the Runpod MCP tools; code-first Python deploys (the Flash dev loop) are out of scope. Use when the user wants a model or worker served on Runpod Serverless, whatever the modality: text generation, speech-to-text or text-to-speech, image or video generation, embeddings, document processing, or their own handler image. For an LLM served with vLLM (Hub worker-vllm, a vllm/vllm-openai image, or a vLLM Pod), defer to runpod-vllm.
runpod-pod-doctor
Diagnose a Runpod Pod that is unreachable, GPU-blind or stuck, and perform a recovery action only when the user authorizes one. Use when an existing Pod misbehaves, through the Runpod MCP tools: its proxy URL answers 502, CUDA is not available inside the container, a restarted Pod has no GPU, the user wants a Pod's logs read, an account-wide check for stuck Pods, or the stop-versus-terminate decision for a Pod they already have. Read-only until the user asks for an action.