Draft Reddit reply suggestions with OpenAI and send them to Slack
Ready for 3.0What this workflow does
This AI workflow has 14 nodes and runs on a schedule (every day at 09:00). Along the way it connects OpenAI Chat Model and Slack.
How it runs
Trigger: On a schedule (every day at 09:00).
- Configure here (Edit Fields (Set)): sets 3 fields: subreddits, lookbackHours, maxThreads
- Build feed URLs (Code): runs custom JavaScript code
- Read subreddit RSS (RSS Read): reads an RSS feed
- Keep recent posts only (Filter): keeps only the items that match a condition
- Trim to essentials (Code): runs custom JavaScript code
- Bundle posts for the model (Aggregate): combines items into one
- Shortlist and draft replies (Basic LLM Chain): sends a prompt to an LLM, with model: Language model; output parser: Structured output
- Anything worth answering (If): checks a condition and branches into true / false
- One message per thread (Split Out): splits a list into separate items
- Report a quiet day to Slack (Slack): uses Slack
…plus 1 more step. See the full node list below.
Services it uses
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
Nodes used (12)
- Schedule Trigger
n8n-nodes-base.scheduleTrigger - Edit Fields (Set)
n8n-nodes-base.set - Code
n8n-nodes-base.code - RSS Read
n8n-nodes-base.rssFeedRead - Filter
n8n-nodes-base.filter - Aggregate
n8n-nodes-base.aggregate - Basic LLM Chain
@n8n/n8n-nodes-langchain.chainLlm - OpenAI Chat Model
@n8n/n8n-nodes-langchain.lmChatOpenAi - Structured Output Parser
@n8n/n8n-nodes-langchain.outputParserStructured - If
n8n-nodes-base.if - Split Out
n8n-nodes-base.splitOut - Slack
n8n-nodes-base.slack
From the author
Quick overview This workflow runs every morning, reads recent posts from selected subreddits via Reddit RSS feeds, uses OpenAI (via LangChain) to shortlist threads and draft helpful replies, and sends the drafts (or a “nothing worth answering” notice) to a…