Pin llama-server reasoning_effort to low to fix Jinja template error

LangChain was sending reasoning_effort=thinking which Qwen3's chat
template rejects (only xhigh/medium/low are valid). low disables
thinking mode, which is appropriate for agentic tool use and saves tokens.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-09-18 07:09:11 -04:00
parent 64b20754a1
commit 4d29bb3ca4
+1
View File
@@ -39,6 +39,7 @@ if llama_url:
model=os.getenv("LLAMA_MODEL_NAME", "llama-3.1-8b-instruct"),
timeout=httpx.Timeout(LLAMA_READ_TIMEOUT, connect=10.0),
max_retries=1,
model_kwargs={"reasoning_effort": "low"},
)
else:
llama_chat = None