All Guides

Local Model Guide

OpenClaw + Qwen3.8-27B: Self-Hosted Model Setup

Run Alibaba’s released 27B open-weights Qwen model on your own inference server, then connect OpenClaw through its custom OpenAI-compatible provider path.

Use the released 27B model, not the Max API ID

The official repository name is Qwen/Qwen3.8-27B. It is a distinct open-weights model under Apache-2.0. The existing Qwen3.8-Max guide covers Alibaba’s much larger hosted API model and uses a different endpoint and model ID.

Start an OpenAI-compatible inference server

python -m pip install -U vllm

vllm serve Qwen/Qwen3.8-27B \
  --host 0.0.0.0 \
  --port 8000 \
  --api-key local-qwen-key \
  --reasoning-parser qwen3 \
  --enable-auto-tool-choice \
  --tool-call-parser qwen3_coder \
  --enable-prefix-caching

The weight repository is about 55.6 GB before runtime overhead. Leave room for KV cache and concurrent sessions. Check that your vLLM version explicitly supports the architecture; if not, upgrade or use a runtime named by the official model card.

Connect OpenClaw Launch

  1. Put the inference server behind HTTPS and authentication.
  2. Open the API Keys page.
  3. In Custom API Provider, enter a base such as https://qwen.example.com/v1 and the inference-server key.
  4. Save, then set the instance model ID to Qwen/Qwen3.8-27B or the exact alias returned by your server.
  5. Run a text and tool-call test before giving the model access to consequential tools.
Reachability: a hosted OpenClaw container cannot call localhost:8000 on your laptop. Use a private network path or an authenticated public HTTPS endpoint.

Direct OpenClaw configuration

If you self-host OpenClaw itself, use its documented custom OpenAI-compatible provider fields. Model IDs in OpenClaw configuration must include a provider prefix; use the provider name you define plus the exact served model ID. Because strict OpenClaw validation rejects unknown fields, start from the current custom endpoint guide or your installed version’s schema rather than pasting an unversioned JSON block.

Hardware and performance

  • Full weights: plan for more memory than the download size.
  • Quantization: use only a build supported by your runtime and evaluate tool-use quality after quantizing.
  • Context: large context consumes KV-cache memory quickly; set a realistic maximum.
  • Prefix caching: repeated OpenClaw system prompts can benefit substantially.
  • Concurrency: size for simultaneous chats and tool continuations, not a single benchmark request.

Validate agent use

Test model discovery, normal chat, structured tool calls, long tool results, and failure recovery. Multimodal support also depends on the runtime and provider adapter; seeing “image-text-to-text” on the model card does not prove every OpenAI-compatible server exposes the same image request format.

Troubleshooting

  • 404 model: query /v1/models and copy the exact returned ID.
  • Out of memory: lower context/concurrency or use an evaluated quantization.
  • Invalid config: remove unrecognized keys and validate against your installed OpenClaw version.
  • Chat works, tools fail: inspect the server chat template and tool-call response fields.

OpenClaw and Qwen3.8-27B FAQ

Can OpenClaw use Qwen3.8-27B?

Yes. Serve the model through an OpenAI-compatible runtime such as vLLM, then add that base URL, key, and model ID as a custom provider.

Is Qwen3.8-27B multimodal?

The official model repository identifies it as an image-text-to-text model. Whether images work end to end depends on the inference runtime and OpenClaw provider path you deploy.

Do I need a GPU?

Practical 27B inference generally needs substantial GPU or unified memory. CPU-only execution is possible in some runtimes but is usually too slow for an interactive agent.

Related Qwen guides

Deploy OpenClaw without server setup

Launch an always-on OpenClaw instance and connect a secure Qwen endpoint through BYOK.

Deploy OpenClaw