Use an open-source LLM (via HuggingFace)
n8n template #1980Summary
Use templateThis workflow demonstrates how to connect an open-source model to a Basic LLM node. The workflow is triggered when a new manual chat message appears. The message is then run through a Language Model Chain that is set up to process text with a specific prompt to guide the model's responses. Note that open-source LLMs with a small number of parameters require slightly different prompting with more guidance to the model. You can change the default Mistral-7B-Instruct-v0.1 model to any other LLM supported by HuggingFace. You can also connect other nodes, such as Ollama. Note that to use this template, you need to be on n8n version 1.19.4 or later.
How to set it up
- Open template #1980 on n8n.io and click Use for free, or copy the template JSON and paste it onto an empty canvas in n8n.
- Create a credential under Credentials → Add credential: Hugging Face Inference Model. Then open each of those nodes and pick the credential.
- Click Execute workflow and step through each node's output to confirm the data looks right.
- Toggle the workflow to Active so its trigger runs on its own.
Hand off to your agent
Prompt
Help me set up the n8n workflow "Use an open-source LLM (via HuggingFace)" (https://n8n.io/workflows/1980). It uses: Basic LLM Chain, Hugging Face Inference Model. Import the template JSON into my n8n instance, list every credential I need to create, and walk me through testing it.
Paste into Claude Code and it will do the rest.
Apps and nodes
Basic LLM ChainHugging Face Inference Model
Questions
Yes. n8n Team published it free on n8n.io as a verified creator, and it has 37K views. It runs on n8n Cloud or a self-hosted n8n instance.
Hugging Face Inference Model. The other 1 node are built into n8n.
Similar workflows
NameViews
- Chat with PDF docs using AI (quoting sources)95K
- Respond to WhatsApp Messages with AI Like a Pro!91K
- ⚡AI-Powered YouTube Video Summarization & Analysis80K
- Chat with local LLMs using n8n and Ollama78K
- Personalize marketing emails using customer data and AI72K
- Gmail AI Auto-Responder: Create Draft Replies to incoming emails55K
- AI Automated HR Workflow for CV Analysis and Candidate Evaluation51K
- Host Your Own AI Deep Research Agent with n8n, Apify and OpenAI o348K