Experiment
Local AI Lab 002: First n8n to Ollama Workflow
Sending real content from n8n to a locally hosted Ollama model and receiving a structured AI summary.
Question
Send content from n8n to a locally hosted Ollama model and receive an AI-generated summary.
Hypothesis
If n8n sends properly formatted JSON to Ollama, then a local model should be able to return a structured response that can be reused inside an automation workflow.
Setup
- n8n running on the home server
- Ollama serving
qwen2.5:3b - HTTP Request node configured to call the Ollama API
- Test content passed from n8n into the request body
Steps
Manual Trigger
↓
Set / Input Content
↓
HTTP Request
↓
Ollama
↓
qwen2.5:3b
↓
Structured Response
Result
n8n successfully passed content to Ollama running qwen2.5:3b on the home server.
The model returned a structured response containing:
- Summary
- Key takeaways
- Action items
- Follow-up questions
What Worked
- Separating instructions from the content body made the prompt easier to manage.
- Sending JSON directly to Ollama produced reusable output for workflow steps.
- The local model was sufficient for summarization and simple structure.
What Failed
- Invalid JSON caused by multiline content.
- Incorrect body format when using Form-Data instead of JSON.
- Boolean type mismatch for the
streamparameter.
Lessons Learned
- APIs often require strict JSON formatting.
- Data types matter. A string like
"false"is not the same as a booleanfalse. - Building prompts from separate instruction and content fields creates more maintainable workflows.
- Streaming responses can be useful for real-time output, but they are harder to process in automation workflows.
Next Experiment
Configure the workflow to return a single JSON response and automatically save the generated output into a Markdown note.