GPU Acceleration Setup
Last Updated: October 2026
How to use GPUs with a self-hosted Scrapalot: NVIDIA GPU images for the AI service and workers, dedicated GPU worker servers, GPU-backed local model engines, and NVIDIA GB10 systems (DGX Spark) as a local inference server.
Overview
Scrapalot runs fine on CPU only — the reference deployment is CPU-only and uses cloud LLM providers. A GPU helps in two independent places:
| Where | What gets faster | How |
|---|---|---|
| AI service and workers | Embeddings, cross-encoder reranking, OCR / layout models | Build the CUDA image and apply the GPU Compose override (NVIDIA only) |
| LLM inference | Chat, deep research and agents on local models | Run a GPU-backed engine — Ollama, LM Studio, vLLM or any OpenAI-compatible server — and add it as a provider |
For AMD, Intel or Apple GPUs, run the LLM engine natively on that hardware (Ollama and LM Studio support them) and connect it as a provider; the containerised CUDA image is for NVIDIA GPUs.
An NVIDIA DGX Spark or another GB10 system is an ARM64 machine whose GPU shares the system memory. It needs its own setup — see NVIDIA GB10 (DGX Spark).
NVIDIA GPU in Docker
Prerequisites
- NVIDIA GPU with a current driver (
nvidia-smiworks on the host) - NVIDIA Container Toolkit installed and the
nvidiaruntime registered with Docker (docker infolists it under Runtimes) - The CPU deployment from the Deployment Guide working first
What the GPU image changes
The default scrapalot-chat image ships CPU PyTorch on purpose. The Dockerfile takes a build argument to switch:
TORCH_VARIANT | PyTorch | Use |
|---|---|---|
cpu (default) | CPU wheels | CPU-only hosts |
gpu | torch 2.7.0 from the CUDA 12.8 (cu128) wheel index | NVIDIA hosts, including Blackwell GPUs (sm_120) and GB10 |
The same image runs scrapalot-chat, scrapalot-workers and scrapalot-workers-graph, so one build covers all three. Both variants build on x86_64 and on ARM64 (linux/arm64); after the last dependency install the build checks that torch, torchvision and torchaudio are the pinned versions and the right build (CPU or CUDA), and fails otherwise.
Build and run
The GPU override file docker-compose.gpu.yaml sets TORCH_VARIANT=gpu for the build and gives the three containers access to all GPUs:
cd scrapalot-chat/docker-scrapalot
# Build the CUDA image
docker compose -f docker-compose.yaml -f docker-compose.gpu.yaml build scrapalot-chat
# Recreate the AI containers with GPU access
docker compose -f docker-compose.yaml -f docker-compose.gpu.yaml up -d \
scrapalot-chat scrapalot-workers scrapalot-workers-graphAlways pass both files for these services on a GPU host. The base docker-compose.yaml deliberately contains no GPU reservation, because that would make docker compose up fail on hosts without the NVIDIA runtime.
With CI/CD, the AI-service deploy workflow has a gpu input that builds the CUDA image and layers the same override.
Verify
docker exec scrapalot-chat python -c \
"import torch; print(torch.__version__, torch.cuda.is_available(), torch.cuda.device_count())"
# expected: 2.7.0+cu128 True <number of GPUs>
docker exec scrapalot-chat nvidia-smiIf the version ends in +cpu, the container is still running the CPU image — rebuild with the override file and recreate the containers.
Keep bulk PDF parsing at low concurrency on GPU
Many document-processing jobs each initialising their own CUDA context at the same time can make PDF text extraction return empty results, which then shows up as documents failing with low extraction yield. Bulk parsing is CPU-bound anyway: keep document-processing concurrency low on the GPU image and use the GPU for OCR and embeddings.
Dedicated GPU Worker Server
To keep the main server CPU-only and offload heavy document work (GPU OCR, embeddings) to a separate NVIDIA machine, run only scrapalot-workers there with docker-compose.gpu-workers.yml. It uses a CUDA image built from docker-scrapalot/Dockerfile.workers (CUDA 12.1 runtime base):
# On the GPU server, from the scrapalot-chat checkout
docker build -f docker-scrapalot/Dockerfile.workers -t scrapalot-workers-cuda:latest .
cd docker-scrapalot
docker compose -f docker-compose.yaml -f docker-compose.gpu-workers.yml up -d scrapalot-workersThe remote worker connects back to the main server's services, so set in its .env:
| Variable | Points to |
|---|---|
CELERY_BROKER_URL, CELERY_RESULT_BACKEND | The main server's Redis |
POSTGRES_HOST, POSTGRES_PORT, POSTGRES_USER, POSTGRES_PASSWORD, POSTGRES_DB | The main server's pgvector |
NEO4J_URI, NEO4J_USER, NEO4J_PASSWORD | The main server's Neo4j |
Connect the two machines over a private network or VPN (for example WireGuard or Tailscale). Never expose Redis, PostgreSQL or Neo4j to the internet to make this work.
GPU-Backed Local Models
The recommended way to run local LLMs is a dedicated inference engine on the GPU machine, registered as a provider:
- Install Ollama, LM Studio or vLLM on the GPU machine and load a model.
- Make its API reachable from the Scrapalot server — the same host, the Docker network, or a private network/VPN to another machine.
- In Scrapalot, open Settings → AI Providers, add the provider (Ollama, LM Studio, vLLM or OpenAI-compatible) with its base URL, and pick the model. Enter the base URL with
/v1(http://<gpu-host>:8000/v1), except for Ollama, which takes the bare address (http://<gpu-host>:11434).
# Check reachability from the Scrapalot server first
curl http://<gpu-host>:11434/api/tags # Ollama
curl http://<gpu-host>:1234/v1/models # LM Studio
curl http://<gpu-host>:8000/v1/models # vLLMExample: a GPU machine on another network
When the GPU machine sits elsewhere (for example at an office while Scrapalot runs in the cloud), join both machines to a VPN such as Tailscale and use the GPU machine's VPN address as the provider base URL:
# On both machines
curl -fsSL https://tailscale.com/install.sh | sh
sudo tailscale up
tailscale status # note the GPU machine's 100.x.y.z address
# From the Scrapalot server
curl http://100.x.y.z:1234/v1/modelsBind the engine to the VPN interface (or use VPN ACLs) so it is not reachable from the public internet, and enable the engine's API key if it has one.
Desktop users' own GPUs
Users of the Scrapalot desktop app can use a model running on their own computer (Ollama, LM Studio, vLLM) in cloud chats: the desktop app relays the requests over its existing connection, so the full pipeline — RAG, collections, citations, history — works with a local model and no port has to be opened on the user's machine.
Built-in llama.cpp (Local AI)
The AI image also contains llama-cpp-python for running GGUF models inside the container, switched on by llm.local_ai.enabled in configs/config.yaml (LOCAL_AI_ENABLED, off by default) and tuned in the llm.advanced block:
llm:
advanced:
gpu_layers: ${LLM_GPU_LAYERS:-auto} # layers to offload (0 = CPU only)
context_size: ${LLM_CONTEXT_SIZE:-32768}
batch_size: ${LLM_BATCH_SIZE:-1024}
threads: ${LLM_THREADS:-4}
vulkan:
enabled: ${LLM_VULKAN_ENABLED:-true}
prefer_vulkan: ${LLM_VULKAN_PREFER:-false}
device_selection: ${LLM_VULKAN_DEVICE_SELECTION:-auto}The image's llama-cpp-python is a CPU build. GPU offload through it requires rebuilding llama-cpp-python with a GPU backend yourself; for GPU inference an external engine (above) is simpler and faster.
Local development (outside Docker)
For development on a workstation with an NVIDIA GPU:
conda activate scrapalot-chat
# CUDA PyTorch — same pins as the GPU image (requirements-gpu.txt)
pip install torch==2.7.0 torchvision==0.22.0 torchaudio==2.7.0 \
--index-url https://download.pytorch.org/whl/cu128 --force-reinstall
# Optional: llama-cpp-python with CUDA (build from source)
CMAKE_ARGS="-DGGML_CUDA=on" pip install llama-cpp-python --no-cache-dir --force-reinstall
# or with Vulkan (NVIDIA, AMD, Intel)
CMAKE_ARGS="-DGGML_VULKAN=on" pip install llama-cpp-python --no-cache-dir --force-reinstall
python -c "import torch; print(torch.__version__, torch.cuda.is_available())"Use --force-reinstall for PyTorch: installing requirements.txt afterwards would otherwise put the CPU build back.
Blackwell GPUs
NVIDIA Blackwell cards (RTX 50-series, RTX PRO Blackwell) in an x86_64 host need CUDA 12.8 kernels. The GPU image's torch 2.7.0+cu128 includes Blackwell (sm_120) support, so embeddings, reranking and OCR run on the GPU with the standard GPU build — no nightly PyTorch is required. Use a driver recent enough for CUDA 12.8.
This applies to discrete cards only. GB10 (DGX Spark) is also Blackwell, but an ARM64 system with compute capability 12.1 and unified memory — see the next chapter.
NVIDIA GB10 (DGX Spark)
NVIDIA DGX Spark and the GB10 systems sold by NVIDIA's partners are compact Grace Blackwell machines whose GPU can use up to 128 GB of memory. For Scrapalot they are a local inference server: they hold models that no single consumer GPU fits, and every engine NVIDIA supports on them speaks the OpenAI API that Scrapalot already uses. They are not a drop-in Blackwell card, though, and the Blackwell GPUs notes above do not carry over.
NVIDIA's own references are the DGX Spark User Guide (hardware, DGX OS, release notes, known issues) and the DGX Spark playbooks — step-by-step recipes and the source of truth for engine images and flags, also on GitHub.
How GB10 differs from a Blackwell card
| Blackwell card (RTX 50, RTX PRO) | GB10 (DGX Spark) | |
|---|---|---|
| CPU | Your x86_64 host | 20-core ARM64 (10× Cortex-X925 + 10× Cortex-A725) |
| CUDA compute capability | 12.0 (sm_120) | 12.1 (sm_121) |
| GPU memory | Dedicated VRAM | Unified: 128 GB (64 GB on the smaller model) of LPDDR5x shared by CPU and GPU; 273 GB/s on the 128 GB model |
| Software | Your distribution, driver and CUDA | DGX OS 7 (Ubuntu 24.04) with the 580 driver branch, CUDA 13, Docker and the NVIDIA Container Toolkit preinstalled |
nvidia-smi memory | Used / total VRAM | Memory-Usage: Not Supported (N/A in --query-gpu): there is no separate framebuffer |
| Container images | linux/amd64 | linux/arm64 |
The release notes list the current DGX OS, driver and CUDA versions. They apply to the DGX Spark Founders Edition; GB10 systems from other manufacturers can receive updates later and through their own update tools.
What follows from this for Scrapalot:
- Images must be ARM64. An x86_64 image fails on the Spark with
exec format error. NGC containers, the official vLLM and SGLang images and llama.cpp built from source are ARM64. - There is one memory pool. The model's weights and KV cache, the OS, the display reservation and every other container share the same memory, so an engine's memory fraction (vLLM
--gpu-memory-utilization) is a share of all of it. - Scrapalot's images build on ARM64 too. The AI image builds natively on the Spark in both variants — the CUDA one installs PyTorch's ARM64 CUDA 12.8 wheels, whose
sm_120kernels GB10 runs through CUDA's minor-version compatibility — and every other image of the stack is multi-architecture. So Scrapalot can run on the Spark next to the models (Scrapalot on the Spark itself), though a separate Scrapalot server keeps the two from competing for one memory pool.
Recommended layout
The Spark answers chat, runs the agents and deep research, and extracts entities for the knowledge graph. Embeddings, reranking and the built-in OCR stay in the AI service: the default models are small enough for a CPU, and changing the embedding model means re-processing the whole library.
Prepare the Spark
Update DGX OS from the DGX Dashboard, or manually — recent releases improved out-of-memory handling on unified memory:
bashsudo apt update && sudo apt dist-upgrade sudo fwupdmgr refresh && sudo fwupdmgr upgrade sudo rebootUse Docker without
sudoand check that containers see the GPU:bashsudo usermod -aG docker $USER && newgrp docker docker run --rm --gpus=all nvcr.io/nvidia/cuda:13.0.1-devel-ubuntu24.04 nvidia-smiRunning headless? The display reserves 2 GB of memory by default. In UEFI (hold
EscorDelat power-on) set Advanced → Advanced Menu → Display Reserved Memory to Auto, which reserves 0.5 GB without a display.Join the tailnet as in Example: a GPU machine on another network, and note the Spark's address with
tailscale ip -4.Keep the supplied 240 W power adapter. Another adapter can reduce performance, prevent boot or shut the system down under load.
Choose an inference engine
| Engine | On the Spark | Provider type in Scrapalot | Base URL |
|---|---|---|---|
llama.cpp (llama-server) | Built from source for GB10 (below) | OpenAI-compatible | http://<spark>:30000/v1 |
| vLLM | NVIDIA's recipe container per model (vLLM playbook) | OpenAI-compatible (with an API key) or vLLM (without one) | http://<spark>:8000/v1 |
| SGLang | lmsysorg/sglang:latest-cu130 (SGLang playbook) | OpenAI-compatible | http://<spark>:30000/v1 |
| TensorRT-LLM | nvcr.io/nvidia/tensorrt-llm/release, trtllm-serve (playbook) | OpenAI-compatible | http://<spark>:8355/v1 |
| NVIDIA NIM | A NIM with a DGX Spark profile, NGC API key (NIM playbook) | OpenAI-compatible | http://<spark>:8000/v1 |
| Ollama | curl -fsSL https://ollama.com/install.sh | sh | Ollama | http://<spark>:11434 (no /v1) |
LM Studio (llmster) | lms server start (LM Studio playbook) | LM Studio | http://<spark>:1234/v1 |
The ports are the ones NVIDIA's playbooks use; any free port works.
- llama.cpp runs GGUF models at any quantization from one binary, with few moving parts. It is the setup Scrapalot is tested against on GB10.
- vLLM gives the best throughput when several requests run at once (chat plus graph extraction), serves NVFP4 checkpoints and caches shared prompt prefixes. NVIDIA publishes a tested image and flag set per model and memory size.
- SGLang reuses the KV cache of shared prefixes automatically (RadixAttention), which suits multi-turn chat and RAG prompts.
- Ollama and LM Studio are the quickest start, once their defaults (bind address, context length) are raised.
- NIM and TensorRT-LLM are NVIDIA's optimized serving stacks. Not every NIM has a DGX Spark variant — check the NIM support matrix before pulling one.
llama.cpp
Build llama-server with CUDA for the GB10 architecture (121a-real):
sudo apt install -y git clang cmake libcurl4-openssl-dev libssl-dev
git clone https://github.com/ggml-org/llama.cpp ~/llama.cpp && cd ~/llama.cpp
cmake -B build -DGGML_NATIVE=ON -DGGML_CUDA=ON -DGGML_CURL=ON -DGGML_RPC=ON \
-DCMAKE_CUDA_ARCHITECTURES=121a-real
cmake --build build --config Release --target llama-server -jServe a GGUF model sized for Scrapalot:
export LLAMA_API_KEY="$(openssl rand -hex 24)" # the key Scrapalot's provider sends
./build/bin/llama-server \
-hf <org>/<model>-GGUF:<quant> \
--host 0.0.0.0 --port 30000 \
-np 4 -c 131072 # 4 parallel requests × 32k tokens-np 4 -c 131072splits a 131k-token context into four slots of 32k. The server log printsn_ctxfor every slot; keep it at 32k or more (see Sizing for Scrapalot).LLAMA_API_KEY(or--api-key) closes the endpoint to anyone without the key.- Jinja chat templates are on by default, so the per-request thinking switch Scrapalot sends reaches the model. Leave reasoning enabled on the server.
- With an MTP-enabled GGUF,
--spec-type draft-mtp --spec-draft-n-max 3adds speculative decoding for faster generation.
To keep the server up across reboots, run it as a systemd service with a downloaded model file (-m) rather than a Hugging Face reference:
# /etc/systemd/system/llama-server.service
[Unit]
Description=llama.cpp server for Scrapalot
After=network-online.target tailscaled.service
Wants=network-online.target
[Service]
User=<user>
Environment=LLAMA_API_KEY=<key>
ExecStart=/home/<user>/llama.cpp/build/bin/llama-server -m /home/<user>/models/<model>.gguf --host 0.0.0.0 --port 30000 -np 4 -c 131072
Restart=on-failure
[Install]
WantedBy=multi-user.targetsudo systemctl daemon-reload && sudo systemctl enable --now llama-servervLLM
Start from NVIDIA's vLLM playbook or the Local AI Inference Recipes: each recipe pins an image, a checkpoint (often NVFP4) and kernel flags that only work together, for the 64 GB and the 128 GB Spark separately. Keep those, then check the settings that matter to Scrapalot:
| Setting | For Scrapalot |
|---|---|
--host 0.0.0.0, --api-key <key> | NVIDIA's launch scripts bind 127.0.0.1 for SSH tunnels; the Scrapalot server needs the tailnet address, and the key keeps the API closed |
--max-model-len | At least 32768 |
--max-num-seqs | The requests you want in flight at once: chat turns plus graph-extraction jobs |
--enable-prefix-caching | Scrapalot repeats long system prompts; a cached prefix cuts the time to the first token |
--enable-auto-tool-choice, --tool-call-parser, --reasoning-parser | Keep the recipe's values: Scrapalot's agents call tools, and the reasoning parser keeps the model's thinking out of the answer |
--gpu-memory-utilization | A share of the whole unified memory. NVIDIA's Spark recipes use 0.6–0.8; leave room for the OS |
Use the OpenAI-compatible provider type for a vLLM server started with --api-key: the vLLM type does not send the key on every request path.
Ollama and LM Studio
Ollama listens only on 127.0.0.1 and uses a 4096-token context by default. Scrapalot does not set the context per request, so with the default a long agent prompt is cut to fit. Change both before connecting it:
curl -fsSL https://ollama.com/install.sh | sh
sudo systemctl edit ollama.service[Service]
Environment="OLLAMA_HOST=0.0.0.0:11434"
Environment="OLLAMA_CONTEXT_LENGTH=32768"
Environment="OLLAMA_NUM_PARALLEL=4"sudo systemctl daemon-reload && sudo systemctl restart ollama
ollama pull <model>Ollama has no API key: keep it reachable only over the tailnet (Tailscale ACLs or a host firewall).
LM Studio runs headless on the Spark as llmster (NVIDIA's playbook targets the 128 GB model). Load the model with a context long enough for Scrapalot:
lms server start --bind 0.0.0.0 --port 1234
lms get <model>
lms load <model> --context-length 32768Connect Scrapalot
Test the endpoint from inside the AI container, where Scrapalot's requests start:
bashdocker exec scrapalot-chat curl -s http://<spark-tailscale-ip>:30000/v1/models \ -H "Authorization: Bearer <key>"As a chat model: Settings → AI Providers, add the provider with the type and base URL from the engine table and the engine's key, then pick the model in chat.
As the system model (administrators): Settings → General → System AI Agent Provider — provider type, model name, API endpoint (the same base URL) and, for the OpenAI-compatible type, the engine's key. It runs Scrapalot's own agents (routing, planning, extraction) and the backend's quick tasks. Optional fields below it:
- Synthesis / answer model — a separate model for the user-facing answer, so a fast tool-caller can run the agents and a stronger model can write.
- Image vision model and OCR model — figure descriptions and scanned pages, if the Spark serves a vision-capable model.
Use the Spark's Tailscale address (100.x.y.z) or a DNS name. Scrapalot treats LAN addresses (10.x, 172.16–31.x, 192.168.x, localhost, *.local) as the user's own computer: while that user's desktop app is connected, chat requests to such an address go through the desktop instead of the server.
Plan for the Spark being off. With a failover model in the system configuration (its fallback entry, set through the settings API — the settings screen does not edit it yet), the agents switch to it when the Spark refuses the connection, skipping the Spark for AGENT_FAILOVER_UNREACHABLE_SKIP_SECONDS (60 s by default), and when no first token arrives within AGENT_FAILOVER_FIRST_TOKEN_SECONDS (90 s) — both are environment variables of the AI service. The backend's quick tasks — titles, descriptions, translations — have no failover and fail while the Spark is unreachable.
Scrapalot on the Spark itself
The whole stack can run on one Spark next to its inference engine — a self-contained setup that needs no other server. Build the AI image on the Spark itself (it builds for the machine's own architecture) with the GPU override, as on any NVIDIA host:
cd scrapalot-chat/docker-scrapalot
docker compose -f docker-compose.yaml -f docker-compose.gpu.yaml build scrapalot-chat
docker compose -f docker-compose.yaml -f docker-compose.gpu.yaml up -d- The CUDA variant downloads PyTorch's ARM64 CUDA wheel (about 2.8 GB), which carries its own CUDA libraries; the Spark's driver runs them. The finished image is about 14 GB (the CPU one about 4 GB).
- Embeddings, reranking and OCR can then use the GB10 GPU. PyTorch may warn that capability 12.1 is above the range it was built for — see Troubleshooting GB10.
- Scrapalot's containers and the model share one memory pool. Give the containers explicit limits (
CHAT_MEMORY,WORKERS_MEMORY,NEO4J_MEMORY, … in.env) and leave the engine only what remains — for vLLM, a--gpu-memory-utilizationwell below NVIDIA's single-purpose recipes. - Set
USER_CPUSETandBATCH_CPUSETfor 20 cores; the defaults assume 8. - Point the providers at the engine by the Spark's Tailscale address (
http://100.x.y.z:30000/v1), as from a separate server: inside a container,localhostis the container itself, and the engine must listen on that address rather than only on127.0.0.1.
Sizing for Scrapalot
- At least 32k tokens of context per request. One agentic turn sends around 20k tokens of prompt — instructions, tool definitions and retrieved passages. A smaller window cuts the prompt or fails the request.
- Several parallel slots. Chat, deep research and knowledge-graph extraction share the engine. With four slots, a chat answer can run while a book is being indexed instead of queuing behind it.
- Thinking models are fine. On the OpenAI-compatible and vLLM types Scrapalot switches thinking off per request for routing and structured roles (
chat_template_kwargs: {"enable_thinking": false}) and leaves it on for answers. Do not disable it globally on the server. - Time to the first token. A long prompt the engine has not cached takes seconds to read: a ~19k-token agent prompt measured about 15 s cold and under a second once cached, so prefix caching pays off. Scrapalot waits up to 90 s for the first token before it fails over.
- Model choice. Generation is limited by memory bandwidth (273 GB/s): every token reads all active weights. Mixture-of-experts models with few active parameters (
A3B,A9Bin the name) at 4-bit — NVFP4 on vLLM or TensorRT-LLM,Q4_K-class GGUF on llama.cpp — answer far faster than a dense model of the same size, while prompt reading is compute-bound and fast on GB10. One measured setup — a large MoE GGUF on llama.cpp with four 32k slots — generates about 30 tokens per second. The playbooks name tested models for each memory size.
Unified memory in practice
nvidia-smilists per-process memory but reportsMemory-Usage: Not Supported, and--query-gpu=memory.*returnsN/A. Watch memory withfree -h, plainnvidia-smi, or the DGX Dashboard (ssh -L 11000:localhost:11000 <user>@<spark>, thenhttp://localhost:11000).CUDA's
cudaMemGetInforeports less than can actually be allocated (it does not count memory the kernel could free by swapping), and some engines size their caches from it.If a model fails to load out of memory while
free -hstill shows room, flush the page cache and start the engine again:bashsudo sh -c 'sync; echo 3 > /proc/sys/vm/drop_caches'Two engines (or two models) on one Spark split the same pool: give each an explicit share — for vLLM,
--gpu-memory-utilizationvalues that add up to well under 1.0.
More from the DGX Spark playbooks
The playbooks cover far more than serving one model. The ones that fit a Scrapalot deployment:
- Faster answers with speculative decoding — MTP heads or a small draft model propose tokens that the main model only verifies: llama.cpp
--spec-type draft-mtp, vLLM--speculative-config, TensorRT-LLM EAGLE-3 (speculative decoding playbook). - NVFP4 checkpoints — Blackwell's 4-bit floating-point format takes about 3.5× less memory than FP16 with accuracy close to FP8. NVIDIA publishes NVFP4 versions of many models, and the NVFP4 quantization playbook makes your own with Model Optimizer.
- Two models side by side — 128 GB holds a fast tool-calling model for the System AI Agent Provider and a larger one as the Synthesis / answer model, the way the multi-agent chatbot playbook runs several models at once.
- Larger models on several Sparks — two to four Sparks linked through their ConnectX-7 ports (200 Gb/s each) serve one model together (connect multiple Sparks, vLLM cluster). Scrapalot sees one endpoint on the head node.
- Images in documents — a vision-language model on the Spark (Live VLM WebUI shows one running) can serve as Scrapalot's image vision and OCR model once its provider lists it as a vision model.
- Knowledge graphs — txt2kg extracts triples with a local LLM into a graph database (ArangoDB or Neo4j), the job Scrapalot's graph workers do. Its note applies here too: reasoning models need structured output for extraction.
- Fine-tuning — Unsloth, LLaMA Factory and NeMo tune a model on the Spark itself; serve the result like any other model.
- Remote administration — NVIDIA Sync manages SSH and tunnels from a laptop, the DGX Dashboard applies updates and shows GPU and memory use, and the Tailscale playbook covers remote access.
Troubleshooting GB10
| Symptom | Cause | Fix |
|---|---|---|
exec format error, or a warning that the image platform linux/amd64 does not match the host | An x86_64 image on ARM64 | Use an ARM64 image (NGC, official vLLM / SGLang images) or build it on the Spark |
| PyTorch warns that the GPU's CUDA capability 12.1 is outside the range it was built for | The CUDA 12.8 wheels carry sm_120 kernels | Expected on GB10: sm_120 kernels run on 12.1 through CUDA's minor-version compatibility |
torch variant mismatch when building Scrapalot's AI image | A later install replaced torch, torchvision or torchaudio with another version or build | The message names the package; check what changed in requirements.txt |
| llama.cpp build errors about the GPU architecture | Wrong CMAKE_CUDA_ARCHITECTURES | -DCMAKE_CUDA_ARCHITECTURES=121a-real |
Memory-Usage: Not Supported / N/A | Unified memory has no framebuffer | Expected — use free -h or the DGX Dashboard |
Out of memory although free -h shows room | The page cache was not released | Flush it (above) and restart the engine |
A test request returns empty content with finish_reason: length | A thinking model spent max_tokens on reasoning | Raise max_tokens in your test; Scrapalot handles this itself |
| Answers ignore most of the retrieved text | Ollama's default 4096-token context | Set OLLAMA_CONTEXT_LENGTH to 32768 or more |
| Answers start late, then come from the failover model | No first token within 90 s: all slots busy, or a long uncached prompt | More slots, prefix caching, a faster model, or a higher AGENT_FAILOVER_FIRST_TOKEN_SECONDS |
401 Unauthorized from the engine | No key sent, or the vLLM provider type with a keyed server | Use the OpenAI-compatible type with the engine's key |
| Titles and descriptions fail while chat still works | The Spark is unreachable and the backend's quick tasks have no failover | Check tailscale status on both machines and the engine |
| Lower performance or shutdowns under load | A power adapter other than the supplied one | Use the supplied 240 W adapter |
Troubleshooting
could not select device driver "nvidia" The NVIDIA Container Toolkit is missing or Docker was not restarted after installing it. Check docker info | grep -i runtimes.
torch.cuda.is_available() is False in the container
- The image is the CPU variant (
+cpuin the version) — rebuild withdocker-compose.gpu.yaml - The container was started without the override file — recreate it with both
-ffiles nvidia-smifails inside the container — driver/toolkit problem on the host
GPU out of memory Several containers share the GPUs (the reservation is not exclusive). Lower worker concurrency, use smaller embedding/reranker models, or give the LLM engine its own GPU.
Cannot reach a remote GPU engine Test with curl from the Scrapalot server (see above), check the VPN status on both machines and the GPU machine's firewall, and make sure the engine listens on an address other than 127.0.0.1.
Monitoring
nvidia-smi -l 1
nvidia-smi --query-gpu=name,temperature.gpu,utilization.gpu,memory.used,memory.total --format=csvOn GB10 the memory fields read N/A; see Unified memory in practice.
Next Steps
- Model Management - Providers and local models
- Deployment Guide - Services and configuration
- Cloud Infrastructure - TLS, proxy and CI/CD