> For the complete documentation index, see [llms.txt](https://docs.clore.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.clore.ai/guides/guides_v2-zh/yu-yan-mo-xing/qwen38-27b.md).

# Qwen3.8-27B（稠密 VLM，单卡）

在 Clore.ai 上部署 Qwen3.8-27B——阿里巴巴的稠密 27B 视觉语言模型，在 Q4 下可于单张 RTX 4090 上运行，在 FP8 下可于单张 RTX 5090 上运行

{% hint style="info" %}
**状态（2026年8月）：** Qwen 发布 **Qwen3.8-27B** 于 **2026年8月14日** 在 **Apache 2.0**，并在一天后提供了官方 FP8 检查点。权重： [Qwen/Qwen3.8-27B](https://huggingface.co/Qwen/Qwen3.8-27B) 以及 [Qwen/Qwen3.8-27B-FP8](https://huggingface.co/Qwen/Qwen3.8-27B-FP8)。稠密 27B， **原生视觉-语言**, **262,144 token 上下文** 可扩展到 **在 YaRN 下可达 1M**，并在 vLLM、SGLang 和 llama.cpp 中实现首日支持。
{% endhint %}

今年夏天发布的大多数模型都无法租用。GLM-5.2 的 FP8 体积是 756GB。MiniMax M3 是 854GB。Kimi K3 为 1.5TB，而且无论采用何种量化方式，都无法在 Clore.ai 上列出的任何机器上运行。Qwen3.8-27B 则是反向平衡： **27B 稠密参数，Q4 下 15.4GB，一张卡，一个容器，搞定。** 它才是这个市场真正适配的模型——在最近一次快照中，有 677 台服务器空闲着一张 24GB 或更高显存的卡。

它也不是阉割版模型。它原生支持图像和视频，并提供一个 `reasoning_effort` 调节项，而其混合注意力栈使 KV 缓存足够小，因此在消费级显卡上跑长上下文是现实可行的，而不是理论上的。

### 关键规格

| 属性    | 数值                                              |
| ----- | ----------------------------------------------- |
| 参数    | 27B（稠密）                                         |
| 架构    | 64 层，混合 Gated DeltaNet + Gated Attention，MTP    |
| 模态    | 文本、图像、视频输入 → 文本输出                               |
| 原生上下文 | 262,144 个 token                                 |
| 扩展上下文 | 1,000,000 个 token（YaRN）                         |
| 许可证   | Apache 2.0                                      |
| 发布日期  | 2026年8月14日                                      |
| 权重    | BF16 55.6GB · FP8 30.9GB · Q4\_K\_S GGUF 15.4GB |
| 主要工具链 | vLLM、SGLang、llama.cpp、Ollama                    |

### 为什么选它

* **能装下。** Q4 在单张 RTX 3090 或 4090 上 **$0.07–0.42/小时**；FP8 可在 RTX PRO 6000 或 2×24GB 卡上运行
* **Apache 2.0** ——可商用、可微调、可再分发，且没有收入门槛；这不同于 Kimi K3（带收入门槛的定制许可）或 MiniMax M3（社区许可）
* **混合注意力** ——每 4 个层块中有 3 个是 Gated DeltaNet（线性注意力），因此 KV 缓存随上下文增长的速度比标准 Transformer 慢得多。这正是 24GB 显卡上 10 万以上上下文可用的原因。
* **内置视觉** ——图表、文档、截图和小时级视频，无需单独部署 VLM
* **思考控制** — `reasoning_effort` 在 `低` / `中型` / `xhigh`，以及 `preserve_thinking` 用于在代理中跨轮次保留推理

***

## 需求

{% hint style="success" %}
**一张卡就是全部要点。** 单张 RTX 4090 在 Q4 下，就能让你以大约每天一杯咖啡的价格，拥有一个前沿级视觉语言模型。只有当你想要 FP8 质量或更长上下文时，才升级到 RTX 5090 或 RTX PRO 6000。
{% endhint %}

|         | Q4\_K\_S GGUF         | Q8 / FP8                           | BF16                          |
| ------- | --------------------- | ---------------------------------- | ----------------------------- |
| 权重      | 15.4GB                | 约 31GB                             | 55.6GB                        |
| GPU     | 1× RTX 3090/4090 24GB | 1× RTX PRO 6000 96GB，或 2× RTX 5090 | 2× RTX PRO 6000，或 4× RTX 5090 |
| 实际可用上下文 | 约 64K                 | 约 200K                             | 完整 262K                       |
| 系统内存    | 32GB                  | 64GB                               | 96GB                          |
| 磁盘      | 25GB                  | 45GB                               | 80GB                          |
| CUDA    | 12.8+                 | 12.8+                              | 12.8+                         |

{% hint style="warning" %}
**单张 RTX 5090（32GB）不足以运行 FP8。** 仅权重就有 30.9GB。你还需要给 KV 缓存和激活保留余量，所以 FP8 需要一张 96GB 显卡或两张 GPU。在单张 5090 上，运行 Q6 或 Q4 —— 见 [CUDA 与 PyTorch 兼容性](/guides/guides_v2-zh/ru-men-zhi-nan/cuda-pytorch-compatibility.md) 在 Blackwell 上合适的基础镜像。
{% endhint %}

***

## 方案 A — Ollama（最快路径）

```bash
ollama pull qwen3.8:27b
ollama run qwen3.8:27b

# OpenAI 兼容端点
ollama serve &
curl http://localhost:11434/v1/chat/completions \\
  -H "Content-Type: application/json" \\
  -d '{
    "model": "qwen3.8:27b",
    "messages": [{"role": "user", "content": "分步骤规划迁移。"}],
    "temperature": 0.7
  }'
```

默认标签是 Q4\_K\_M（约 16GB）。如果你租了一张 96GB 显卡，请使用 `qwen3.8:27b-q8_0` 。

***

## 方案 B — vLLM（生产环境）

单张 24GB 显卡，社区 INT4 AWQ 检查点：

```yaml
# docker-compose.yml
services:
  vllm:
    image: vllm/vllm-openai:latest
    ports: ["8000:8000"]
    volumes: [hf_cache:/root/.cache/huggingface]
    command: >
      --model cyankiwi/Qwen3.8-27B-AWQ-INT4
      --max-model-len 65536
      --gpu-memory-utilization 0.92
      --served-model-name qwen3.8-27b
      --enable-auto-tool-choice
      --tool-call-parser hermes
    deploy:
      resources:
        reservations:
          devices: [{driver: nvidia, count: 1, capabilities: [gpu]}]
    shm_size: "8gb"
volumes:
  hf_cache:
```

Qwen 官方只提供 BF16 和 FP8。4 位检查点都是社区构建—— `cyankiwi/Qwen3.8-27B-AWQ-INT4` 以及 `RedHatAI/Qwen3.8-27B-INT4` 是下载量最高的，且 `unsloth/Qwen3.8-27B-NVFP4` 专门针对 Blackwell 显卡。

跨两张 GPU 的 FP8：

```bash
vllm serve Qwen/Qwen3.8-27B-FP8 \\
  --tensor-parallel-size 2 \\
  --max-model-len 262144 \\
  --gpu-memory-utilization 0.90 \\
  --enable-chunked-prefill
```

视频输入需要额外一个标志：

```bash
vllm serve Qwen/Qwen3.8-27B --media-io-kwargs '{"video": {"num_frames": -1}}'
```

用 YaRN 突破原生窗口：

```bash
VLLM_ALLOW_LONG_MAX_MODEL_LEN=1 vllm serve Qwen/Qwen3.8-27B \\
  --hf-overrides '{"text_config": {"rope_parameters": {"rope_type": "yarn", "factor": 4.0, "original_max_position_embeddings": 262144}}}' \\
  --max-model-len 1000000
```

***

## 方案 C — llama.cpp / GGUF（24GB 显卡）

```bash
# Q4_K_S — 15.4GB，在 24GB 显卡上很宽松
huggingface-cli download unsloth/Qwen3.8-27B-GGUF \\
  --include "*UD-Q4_K_S*" --local-dir /workspace/qwen38

llama-server -m /workspace/qwen38/*UD-Q4_K_S*.gguf \\
  --host 0.0.0.0 --port 8080 \\
  -ngl 999 -c 65536 --flash-attn
```

同一仓库里更小的量化版本，适合更紧张的显卡： `UD-Q3_K_XL` 13.1GB， `UD-Q2_K_XL` 9.8GB， `UD-IQ2_S` 8.4GB。

***

## 推理强度

```python
from openai import OpenAI
client = OpenAI(base_url="http://localhost:8000/v1", api_key="none")

resp = client.chat.completions.create(
    model="qwen3.8-27b",
    messages=[{"role": "user", "content": "分步骤规划迁移。"}],
    extra_body={"reasoning_effort": "xhigh"},   # xhigh（默认）| medium | low
)
```

降到 `低` 用于分类、抽取和路由——这类任务的质量差异很小，而 token 费用只是其中一小部分。保留 `xhigh` 用于代理和多步代码工作。

***

## Clore.ai GPU 推荐

| 配置              | 显存    | 模式        | 上下文     | Clore.ai 成本       |
| --------------- | ----- | --------- | ------- | ----------------- |
| **1× RTX 3090** | 24GB  | Q4 GGUF   | 约 64K   | **$0.07–0.21/小时** |
| **1× RTX 4090** | 24GB  | Q4 AWQ    | 约 64K   | **$0.14–0.42/小时** |
| 1× RTX 5090     | 32GB  | Q6 GGUF   | 约 96K   | $0.25–0.77/小时     |
| 2× RTX 5090     | 64GB  | FP8，TP=2  | 约 200K  | $0.50–1.54/小时     |
| 1× RTX PRO 6000 | 96GB  | FP8       | 完整 262K | $0.92–1.38/小时     |
| 4× RTX 5090     | 128GB | BF16，TP=4 | 完整 262K | $1.00–3.08/小时     |

{% hint style="success" %}
**最佳性价比：** 一张 [RTX 4090 起价 $0.14/小时](https://clore.ai/rent-4090.html) 在 Q4 下。如果整机价格看起来偏高，记住大多数多 GPU 机器都允许 [部分租用](/guides/guides_v2-zh/ru-men-zhi-nan/partial-gpu-rental.md) ——你可以从八卡机箱里拿走一张卡。
{% endhint %}

***

## 基准

{% hint style="warning" %}
下面的数字均来自 Qwen 在 2026 年 8 月 14 日模型卡中的数据。撰写本文时，独立复现结果仍在陆续出现。
{% endhint %}

Qwen 使用 Claude Code harness 在 256K 上下文下，将 27B 与更大的模型在代码和 agent 套件（SWE-bench Pro、DeepSWE、QwenSWEBench）上进行评测。部署时真正重要的主张不是某一个单项分数：而是一个跑在单张消费级显卡上的稠密 27B，能和那些需要整机架的 MoE 模型坐在同一张桌子上讨论。把厂商表格当作起点假设，并在你自己的任务集上做基准测试——在这里这很便宜，因为 4090 跑一小时大约只要二十美分。

***

## 应用场景

* **单 GPU 编码助手** ——一个容器，一张卡，一个 OpenAI 兼容端点
* **文档和截图理解** ——原生视觉，无需单独流水线
* **视频分析** ——借助 vLLM 的帧标志，可一次性处理小时级视频
* **长上下文 RAG** ——原生 262K，且混合注意力让 KV 缓存保持可负担
* **代理工作器** — `preserve_thinking` 在工具调用之间保持推理一致
* **本地部署和离线隔离环境** ——Apache 2.0，不会向外联络
* **LoRA 微调** ——27B 稠密模型很适合 [Unsloth](/guides/guides_v2-zh/xun-lian/unsloth-finetune.md) 以及 [LLaMA-Factory](/guides/guides_v2-zh/xun-lian/llama-factory.md) 在单张 24GB 显卡上

***

## 故障排查

| 问题                        | 修复                                                                                                  |
| ------------------------- | --------------------------------------------------------------------------------------------------- |
| `没有可用的内核映像` 在 5090 上      | 旧版 CUDA 构建——请使用 cu128 镜像，见 [兼容性](/guides/guides_v2-zh/ru-men-zhi-nan/cuda-pytorch-compatibility.md) |
| 在单张 RTX 5090 上 FP8 发生 OOM | 预期：32GB 显卡上有 30.9GB 权重。请使用 Q6/Q4，或 TP=2                                                             |
| 24GB 上长上下文发生 OOM          | 将 `--max-model-len` 到 32768，或降到 `UD-Q3_K_XL`                                                        |
| YaRN 被拒绝                  | 需要较新的 vLLM/SGLang；请通过 `--hf-overrides`传入，而不是作为独立标志                                                  |
| 视频输入被忽略                   | 在 `--media-io-kwargs '{"video": {"num_frames": -1}}'` （仅 vLLM）                                      |
| 工具调用丢失                    | `--enable-auto-tool-choice --tool-call-parser hermes`                                               |
| 质量在约 600K 之后下降            | YaRN 扩展的是位置，不是理解能力——请把关键内容放在提示词末尾附近                                                                 |

***

## 下一步

* **前代：** [Qwen3.6-27B](/guides/guides_v2-zh/yu-yan-mo-xing/qwen36-27b.md) ——替代今年 4 月那版稠密 27B
* **多模态兄弟型号：** [Qwen3.5-Omni](/guides/guides_v2-zh/yu-yan-mo-xing/qwen35-omni.md) ——增加音频输入和语音输出
* **升级：** [GLM-5.2](/guides/guides_v2-zh/yu-yan-mo-xing/glm-5-2.md) 或 [Mistral Small 4](/guides/guides_v2-zh/yu-yan-mo-xing/mistral-small4.md) 当 27B 还不够时
* **服务：** [vLLM](/guides/guides_v2-zh/yu-yan-mo-xing/vllm.md) · [SGLang](/guides/guides_v2-zh/yu-yan-mo-xing/sglang.md) · [Ollama](/guides/guides_v2-zh/yu-yan-mo-xing/ollama.md)
* **微调：** [Unsloth](/guides/guides_v2-zh/xun-lian/unsloth-finetune.md)

### 链接

* [Hugging Face 上的 Qwen3.8-27B](https://huggingface.co/Qwen/Qwen3.8-27B) · [FP8](https://huggingface.co/Qwen/Qwen3.8-27B-FP8) · [GGUF](https://huggingface.co/unsloth/Qwen3.8-27B-GGUF)
* [vLLM 配置示例](https://recipes.vllm.ai/Qwen/Qwen3.8-27B) · [SGLang 代码示例](https://docs.sglang.io/cookbook/autoregressive/Qwen/Qwen3.8-27B)
* [Qwen 博客](https://qwenlm.github.io/)
* **租用 GPU：** [RTX 4090](https://clore.ai/rent-4090.html) · [RTX 5090](https://clore.ai/rent-5090.html) · [市场](https://clore.ai/marketplace)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.clore.ai/guides/guides_v2-zh/yu-yan-mo-xing/qwen38-27b.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
