Skippy's Private LLM: How I Solved OpenClaw's Ollama Sub-Agent Timeout by Calling Ollama Directly

OpenClaw's sub-agent system has a persistent timeout issue when using Ollama models. The Node.js event loop blocks during generation, sub-agents hang for 60+ seconds, and produce zero tokens. Multiple GitHub issues confirm it: #23827, #27883, #41871, #79032, #63736 — all report the same pattern: direct curl works, sub-agents don't.
The fix described by Skippy, an OpenClaw COO's AI assistant, is to skip the sub-agent system entirely. Instead, run a second Ollama instance on port 11435, decoupled from the main chat instance on port 11434. The main instance handles normal chat and tools; the second instance is a dedicated worker for heavy analysis (like reviewing a 432-line Python classifier). The AI calls it via a raw curl or a Python wrapper — no gateway involvement, no event loop blocking, no GPU contention.
python3 analyze.py \
--file /tmp/review_prompt.txt \
--out /tmp/review.md \
--system "You are a deep code reviewer." \
--timeout 1200 \
--max-tokens 32768 \
--temperature 0.3Workflow: write the review prompt + full source code to a temp file, then execute the Python script. The 27B model runs on port 11435, using ~17.7 GB VRAM on a Mac Studio M2 Ultra, while the main chat uses the 35B model on port 11434 (~19.8 GB VRAM). Skippy reports the fix works reliably — no more timeouts.
This is a pragmatic workaround for anyone hitting the Ollama sub-agent timeout bug in OpenClaw, especially if you have enough VRAM to run two model instances.
📖 Read the full source: r/openclaw
👀 See Also

Save on Claude Code Bills by Routing Planning Tokens to Cheaper Models
A user cut $40 in overage fees by splitting Claude Code workflows: planning steps go to Haiku 3.5, actual edits and decisions stay on Opus/Sonnet. A 30-line wrapper handles routing; setup took ~2 hours.

OpenClaw LLM Timeout Fix for Cold Model Loading
A Reddit user identified and fixed a specific timeout issue in OpenClaw where cold-loaded local LLMs would fail after about 60 seconds, even with higher general timeouts set. The solution involves adjusting the embedded-runner LLM idle timeout configuration.

How a /loop Command Burned $6,000 in Claude API Overnight
A developer's unattended /loop command running every 30 minutes on claude-opus-4-7 consumed $6,000 in one night due to prompt caching expiration and growing context — a cautionary tale for AI agent automation.

OpenClaw Crash Loop Debugging: A 5-Point Checklist
A Reddit post from r/openclaw provides a five-step checklist for quickly diagnosing crash loops in OpenClaw agents or gateways, focusing on failure shape, host pressure, provider latency, config diffs, and alert setup.