Cache-DiT is a PyTorch inference engine for DiT models, with caching, parallel processing, quantization, and CPU offloading. It is for running diffusion-model pipelines with support for systems and hardware such as Diffusers, SGLang Diffusion, vLLM-Omni, ComfyUI, NVIDIA GPUs, Ascend NPUs, and AMD GPUs.
Borrowing it
Nothing to install: this file belongs to vipshop/cache-dit. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/vipshop/cache-dit/main/.agents/skills/cache-dit-model-integration/SKILL.mdgit clone --depth 1 https://github.com/vipshop/cache-ditWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/vipshop/cache-dit/cache-dit-model-integration)<a href="https://agentmods.dev/skills/vipshop/cache-dit/cache-dit-model-integration"><img src="https://agentmods.dev/badge/skills/vipshop/cache-dit/cache-dit-model-integration/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/vipshop/cache-dit/cache-dit-model-integration"><img src="https://agentmods.dev/badge/skills/vipshop/cache-dit/cache-dit-model-integration.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector warn
SkillSpector: 2 findings, up to medium
These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →
- medium Prompt Injection · line 333 Subtle instructions detected that may alter agent decision-making or introduce hidden biases.Fix: Review content for implicit steering or bias. Ensure instructions are explicit and align with the skill's stated purpose.
- medium Prompt Injection · line 478 Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.Fix: Remove the large whitespace padding (blank-line blocks or long space runs) and review any content hidden below or to the right of it. Keep skill files compact and reviewable so no instructions can be
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00243 | $0.15853 |
| Opus 5.5 | $0.00097 | $0.06341 |
| Sonnet 5.5 | $0.00049 | $0.03171 |
| Haiku 4.5 | $0.00024 | $0.01585 |
Grade A, and why
cache-dit-model-integration scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured today.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 652 lines — stays where its author put it; the contents beside it link to each section on GitHub.
ROUTE FIRST — what is the user actually asking for?
Pick one route before reading anything else; the rest of this file is only route 2.
- Benchmarking / acceptance of an ALREADY-supported model — the model runs (
cdit.generatehas an example, cache/CP/TP already work) and the user wants speed + PSNR/SSIM numbers: "跑一遍全量测试矩阵", "4 卡验收", "量化掉多少精度", "和 bf16 比加速比" → read./references/perf_matrix.md. It owns the row list, command templates, the layout mapping / preflight, and Tier A (1/2 GPUs, default) vs the on-request Tier B (4 GPUs) / Tier C (8 GPUs) extensions (hybrid CP+TP included). Do NOT open Tier B/C unless the user explicitly asks to extend to 4/8 cards. The GATE CHECK, the Hard rules and the §0.6 checklist below do not apply to this route. 量化类型与配置语义(fp8/int8/int4/nvfp4、svdq PTQ vs DQ、precision plan、regional、per_tensor_fallback、observer)以cache-dit-quantization为准;本 route 只负责跑矩阵、 出加速比与 PSNR/SSIM,不负责解释量化后端行为。 - Integrating a NEW model — no
BlockAdapter, no CLI example, new pipeline/transformer code → continue with the GATE CHECK and §0 below. - A measured speedup looks wrong, or choosing which optimizations can pay off before
benchmarking → read
./references/perf_analysis.md(FLOPs budget: attention vs GEMM share). - The model is audio-only (TTS / text-to-audio: it returns a waveform, not frames) → read
./references/audio.mdbefore the Cache chapter. It covers the latent layout and duration semantics, the CP obstacles specific to audio (dataclass return, per-rank RoPE, replicated text, duration mask), the wav output path in the CLI, and the audio metrics + their noise floor — the image PSNR/SSIM gates below do not transfer. The rest of this file (GATE CHECK, phases) still applies — only route 1 skips them.
Related skills(跨 skill 路由)
模型接完只是第一步;下面这些场景不要在本文里找答案:
| 触发场景 | 去读 |
|---|---|
量化相关的模型测试与精度归因:--quantize-type 选哪个、precision plan / regional / per_tensor_fallback、svdq 选 PTQ 还是 DQ、observer 怎么定位掉精度的层、"量化掉多少精度"该归因到哪条路径 |
cache-dit-quantization |
| 模型里要新增或改动 CUDA 算子、算子注册与构建、从 nunchaku 等上游移植 kernel | cache-dit-custom-kernel(迁移方法论在其 references/operator-migration.md) |
| 发版本、构建 cu13 wheel、索引与安装验收 | cache-dit-build-release |
| 只要 CUDA/PTX 细节、CUTLASS/CuTe C++ 模板、CuTe DSL Python、NCU 驱动的 kernel 优化 | cuda-cpp-kernel / cutlass-cpp-kernel / cute-dsl-kernel / cuda-auto-tune |
What ships with it
18 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- references/attention.md 5.6 KB
- references/audio.md 32 KB
- references/cache.md 28 KB
- references/cli.md 2.7 KB
- references/cp.md 50 KB
- references/custom_models.md 32 KB
- references/install.md 1.6 KB
- references/loader.md 14 KB
- references/model_download.md 8.0 KB
- references/modular_pipeline.md 29 KB
- references/perf_analysis.md 6.7 KB
- references/perf_chart_example.png 235 KB
- references/perf_matrix.md 40 KB
- references/rfc_pending_models.md 103 KB
- references/tep.md 3.7 KB
- references/testing.md 12 KB
- references/tp.md 30 KB
- references/vaep.md 2.1 KB
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- today Changed · +16 lines ea12d8f6bd31
- 6d ago Changed 25108209f042
- 7d ago Changed · +54 lines · +161 tokens per session e5eee0e935e9
- 8d ago Changed · +35 lines e452d7ce7518
- 9d ago Changed · +2 lines 2130b4d97ace
- 10d ago Changed · +2 lines 7987cf0d0240
- 14d ago Changed · +3 lines 26751e612e9a
- 15d ago Changed · +5 lines 9505d7a435e7
- 17d ago Changed · +10 lines 1aaca3e86ac5
- 2mo ago First seen · 525 lines · 82 tokens per session scan A 79835fd69363
cache-dit-model-integration is a skill published in the GitHub repository vipshop/cache-dit (1,300 stars, last pushed today), licensed Apache-2.0. It adds 243 tokens to every session and 15,853 once invoked, about $0.0010 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
cache-dit-model-integration compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| cache-dit-model-integrationvipshop/cache-dit | Skill | 1.3k | today | Apache-2.0 | A | 243 | Claude Code |
| agent-platform-model-registrygoogle/skills | Skill | 22k | yesterday | Apache-2.0 | A | 60 | Claude Code, Codex |
| foundry-config-setupmicrosoft/agent-framework | Skill | 15k | yesterday | MIT | A | 65 | Claude Code, Codex |
| google-cloud-solution-agentic-analytics-spark-knowledge-cataloggoogle/skills | Skill | 22k | yesterday | Apache-2.0 | A | 132 | Claude Code, Codex |
| training-checkwanshuiyin/Auto-claude-code-research-in-sleep | Skill | 19k | 3d ago | MIT | A | 35 | Claude Code |
| nemo-automodel-launcher-configNVIDIA/skills | Skill | 3.9k | yesterday | Apache-2.0 | A | 30 | Claude Code |
| finetuningmicrosoft/skills | Skill | 3.2k | yesterday | MIT | A | 132 | Claude Code |