{
  "schema_version": "1.0",
  "id": "T-e447b95bbd7d",
  "url": "https://gpuatlas.top/articles/T-e447b95bbd7d/",
  "title": "DeepSeek R1 蒸馏版 7B 想读长文档，上下文开多大才不容易爆显存？",
  "summary": "DeepSeek R1蒸馏7B长文需保留推理输出空间，28层缓存算例只覆盖常规16bit KV部分。",
  "language": "zh-Hans",
  "category": {
    "id": "c-02",
    "name": "推理与上下文",
    "url": "https://gpuatlas.top/categories/c-02/"
  },
  "topics": [
    {
      "id": "model-b64bc5faa8",
      "name": "DeepSeek R1",
      "kind": "model",
      "description": "完整版与蒸馏版的硬件需求不能混算。分别查看权重预算、多卡部署、量化运行及微调相关问题。",
      "url": "https://gpuatlas.top/topics/model-b64bc5faa8/"
    }
  ],
  "body_text": "DeepSeek-R1-Distill-Qwen-7B读长文，要把文档、模板、历史、思考和最终答案共同计入长度。材料接近上限时，即使输入被接受，也可能没有足够空间完成后续推理。\n\n官方配置28层、4个KV头、头维128。常规单序列16bit KV在8K约0.4375GiB、32K约1.75GiB、128K约7GiB，权重、分页元数据与缓冲不在其中。配置支持长度与设备能承载长度是两项条件。\n\n固定文件和单请求，从常见材料逐档加长，分别观察输入与生成峰值，记录实际token和输出是否完整。输入阶段失败先看处理安排与预留，生成后段失败再查总长度和活动状态。\n\n容量紧张时，先去掉无关历史，再分别比较受支持的量化或缓存方案。权重位宽不自动改变KV精度，缩短输出也不一定解决预填充峰值。调整后重跑原题，避免多个变化混在一起。\n\n可以选一份自己熟悉的材料，分别询问开头的条件、中段的推导和末尾的结论，检查答案能否引用对应证据并完成推理。若32K这一档有资源余量却总漏掉中段条件，继续扩长未必有帮助，应先整理章节或检索；若答案在思考中截断，则重新给输出留空间。",
  "published_at": null,
  "modified_at": "2026-11-26T15:17:38.690397+00:00",
  "evidence": {
    "type": "documentation_and_conditional_estimates",
    "hardware_tested": false,
    "note": "资料解释与条件估算，非硬件实测。"
  },
  "sources": [
    {
      "id": "r1-distill-7b",
      "url": "https://huggingface.co/deepseek-ai/DeepSeek-R1-Distill-Qwen-7B/raw/main/README.md",
      "retrieved_at": "2026-11-25T11:18:40.540160+00:00"
    },
    {
      "id": "r1-distill-7b-config",
      "url": "https://huggingface.co/deepseek-ai/DeepSeek-R1-Distill-Qwen-7B/resolve/main/config.json",
      "retrieved_at": "2026-11-25T11:18:40.540160+00:00"
    },
    {
      "id": "vllm-memory",
      "url": "https://raw.githubusercontent.com/vllm-project/vllm/main/docs/configuration/conserving_memory.md",
      "retrieved_at": "2026-11-25T09:52:45.997121+00:00"
    }
  ],
  "revision_note": "完善阅读结构；非硬件实测。",
  "representations": {
    "html": "https://gpuatlas.top/articles/T-e447b95bbd7d/",
    "json": "https://gpuatlas.top/data/articles/T-e447b95bbd7d.json",
    "markdown": "https://gpuatlas.top/data/articles/T-e447b95bbd7d.md"
  }
}
