#27956 [Bug]: Ollama reasoning_content always null — /api/generate doesn't return thinking field
## Describe the bug
When using Ollama with thinker models (Qwen3, DeepSeek-R1 variants), `reasoning_content` is always `null` in the LiteLLM response even though the model generates extensive internal reasoning. This means any downstream observability (Langfuse, etc.) loses the reasoning chain entirely.
## Environment
- LiteLLM version: 1.83.10 - Provider: Ollama (self-hosted) - Models affected: qwen3-vl:8b, qwen3.6:27b (and any Qwen3/DeepSeek-R1 variant via Ollama)
## Root cause
`litellm/llms/ollama/completion/transformation.py` always calls `/api/generate`:
```python # line ~488 url = f"{api_base}/api/generate" ```
`transform_response` then reads:
```python response_text = response_json.get("response", "") reasoning_content, content = _parse_content_for_reasoning(response_text) ```
The `/api/generate` endpoint does **not** return a `thinking` field. Its response looks like:
```json {"response": "4.", "context": [...]} ```
In contrast, `/api/chat` **does** return thinking as a separate field:
```json {"message": {"content": "4.", "thinking": "The user asked what 2+2 is..."}} ```
`_parse_content_for_reasoning` looks for `<think>` XML tags in the response string. Qwen3 …