Edge Compute
Templates / vLLM (OpenAI-compatible API)
CUDA 12.8SSHJupyterAPIText generation

vLLM (OpenAI-compatible API)

High-throughput LLM serving. Loads any Hugging Face model and exposes an OpenAI-compatible API protected by your rental's API key.

What's inside

  • ✓
    vLLM OpenAI-compatible server on port 8000
  • ✓
    API key = your rental's app token
  • ✓
    Model downloaded from Hugging Face on first start (set HF_TOKEN for gated models)
  • ✓
    Logs: /var/log/onstart.log

How you connect

AccessWhereAuth
SSH (root)ssh -p <port> root@clearlayer.caYour SSH key
JupyterLabhttps://r<id>-<random>.gpu.clearlayer.caToken in the link
OpenAI-compatible API (port 8000)https://r<id>-<random>-app.gpu.clearlayer.ca Authorization: Bearer <app token>

Environment variables

VariableDefault
MODEL_IDQwen/Qwen3-8B
VLLM_ARGS--max-model-len 16384 --gpu-memory-utilization 0.90
APP_TOKENrandom per rental
HF_TOKENoptional, for gated Hugging Face models

Models from the model library set these for you.

Quick start

curl
curl https://r12-abcd1234-app.gpu.clearlayer.ca/v1/chat/completions \
  -H "Authorization: Bearer <app-token>" \
  -H "Content-Type: application/json" \
  -d '{"model": "Qwen/Qwen3-8B", "messages": [{"role": "user", "content": "Hello!"}]}'
Python
from openai import OpenAI

client = OpenAI(base_url="https://r12-abcd1234-app.gpu.clearlayer.ca/v1", api_key="<app-token>")
resp = client.chat.completions.create(
    model="Qwen/Qwen3-8B",
    messages=[{"role": "user", "content": "Hello!"}],
)
print(resp.choices[0].message.content)