Claude CLI v2.1.154 Breaks Local vLLM — One-Line Patch Fixes It

Claude CLI v2.1.154 introduced support for workflows, but in doing so it added three new API message roles (ctx, msg, and system) that broke compatibility with local vLLM servers. The fix is a one-line change to vLLM's Anthropic protocol definitions.
The Problem
Claude CLI versions ≥2.1.154 now send messages with roles beyond user and assistant. vLLM's Anthropic API endpoint only accepted the original two roles, causing requests from the CLI to fail when pointing to a local vLLM instance.
The One-Line Patch
The patch updates the role field in vllm/entrypoints/anthropic/protocol.py to allow the new roles:
--- a/vllm/entrypoints/anthropic/protocol.py
+++ b/vllm/entrypoints/anthropic/protocol.py
@@ -65,7 +65,7 @@ class AnthropicContentBlock(BaseModel):
class AnthropicMessage(BaseModel):
"""Message structure"""
- role: Literal["user", "assistant"]
+ role: Literal["user", "assistant", "ctx", "msg", "system"]That's it. After applying this change, you can use the latest Claude CLI workflows with vLLM-based local models like MiniMax-M2.7 (the only model tested by the author).
If you run a local Anthropic-compatible endpoint on vLLM, apply this patch to keep working with Claude CLI ≥2.1.154.
📖 Read the full source: r/LocalLLaMA
👀 See Also

WhatsApp on OpenClaw: Save Yourself 2 Hours by Updating to 5.7 First
Setting up WhatsApp on OpenClaw requires Baileys library, 24/7 uptime, and version 5.7+ to avoid ghost chats, TUI degradation, and double-send bugs.

Workaround for Claude Mobile App Microphone Feedback Loop Error
A Reddit user shares a working workaround for the microphone feedback loop error in the Claude mobile app: installing the web version as a standalone Progressive Web App via Google Chrome, which bypasses the issue and provides access to different Claude models.

Negation Prompting Is Weak: Instead, Explicitly Describe the Desired Behavior
A Reddit analysis shows that telling Claude "don't be wordy" or "don't moralize" barely works. Instead, use positive instructions like "respond in 1-2 sentences" or "give me a direct answer, treat caveats as optional." Also, ending with "thanks!" warms the tone.
A sub-agent reply is not a completion receipt: orchestrator verification checklist
OpenClaw's sessions_spawn is non-blocking—a reply doesn't mean done. Use yield and Task Flow, and reconcile child state to avoid false success.