AI WordPress Post Summarizer & Content Enrichment Agent
Integrates with:
Overview
Unlock Automated Content Enrichment with this AI Agent
This AI Agent automatically generates concise, engaging summary blocks for your WordPress posts. It fetches new or existing articles, uses OpenAI (specifically GPT-4o-mini) to create a well-formatted HTML summary, and intelligently inserts it at the top of your posts. The agent also employs an AI-driven text classifier (using Langchain and an OpenAI model) to prevent duplicate summarization if a summary already exists. It logs its activity to Google Sheets and notifies you on Slack, keeping your content fresh and your team informed. This agent acts as your AI Content Summarization specialist.
Key Features & Benefits
- Advanced AI Summarization: Leverages OpenAI's GPT-4o-mini for accurate and natural-sounding summaries, formatted as an HTML block.
- AI-Driven Classification: Uses a Langchain text classifier with an OpenAI model to detect existing summaries in posts, preventing redundancy.
- Seamless WordPress Integration: Fetches posts and updates them with the generated summary, preserving original excerpts.
- Robust Data Logging: Records details of all summarized posts (ID, title, links, summary date) in a Google Sheet for easy tracking.
- Real-time Team Notifications: Sends alerts to a designated Slack channel when a post is successfully updated with an AI summary.
- Customizable Output: The AI prompt for summary generation is designed for a specific HTML structure, which can be tailored to match your website's theme and branding.
- Flexible Trigger Options: Can be run manually, on a recurring schedule (e.g., daily, hourly), or triggered instantly via a webhook when new posts are published.
- Optimized AI Input: Converts post content from HTML to Markdown before sending to the AI, improving processing accuracy and summary quality.
Use Cases
- B2C E-commerce: Automatically generate engaging summaries for blog posts about new products or industry trends, improving SEO and reader engagement.
- B2B SaaS: Create concise AI-powered summaries for feature updates, case studies, or whitepapers published on your WordPress blog, making complex information easily digestible for busy prospects and customers.
- Content Agencies: Streamline the process of adding value-added summaries to client blog posts, increasing content quality and saving editorial time.
- Solopreneurs/Founders: Enhance your blog's user experience by providing quick takeaways for your articles, improving time-on-page and content stickiness.
Prerequisites
- An n8n instance (Cloud or self-hosted).
- OpenAI API Key with access to a model like
gpt-4o-mini
. - WordPress site with REST API enabled and credentials (Application Password recommended).
- Google Sheets API credentials (Service Account recommended). You'll need to create a Google Sheet (a template is referenced in the workflow notes for easy setup).
- Slack API credentials (OAuth2) and the ID of the channel for notifications.
Setup Instructions
- Download the n8n workflow JSON file.
- Import the workflow into your n8n instance.
- Trigger Configuration:
- Choose your preferred trigger: 'When clicking ‘Test workflow’' (manual), 'Schedule Trigger', or 'Webhook'. Enable only one and configure its connected nodes as per the sticky notes in the workflow.
- The default is the manual trigger connected to 'WordPress - Get All Posts'.
- WordPress Credentials & Configuration:
- Configure credentials for all WordPress nodes (e.g., 'WordPress - Get All Posts', 'WordPress - Get Post2').
- In the 'Wordpress - Update Post' (HTTP Request) node, replace
<your-domain.com>
with your actual WordPress domain in the URL field. - In the 'Set fields - Prepare data for Gsheets & Slack' node, replace
<your-domain.com>
in theedit_link
expression.
- OpenAI Configuration:
- In the 'OpenAI Chat Model' node (connected to 'Text Classifier'), select or create your OpenAI API credential.
- In the 'OpenAI' node (for summary generation), select or create your OpenAI API credential. Ensure the model (e.g.,
gpt-4o-mini
) is selected. - Customize the
system_prompt
in the 'OpenAI' node: specify your website's theme and adapt the "Good" and "Bad" output examples if needed. You can also adjust the HTML styling of the summary block here.
- Google Sheets Configuration:
- Configure credentials for 'Google Sheets - Get rows' and 'Google Sheets - Add Row' nodes.
- Update 'Document ID' and 'Sheet Name' in both Google Sheets nodes. It's recommended to make a copy of the Google Sheets template linked in the workflow's sticky notes and use its ID.
- Slack Configuration:
- Configure credentials for the 'Slack - Notify Channel' node.
- Set the correct 'Channel ID' for notifications.
- Review the logic in the 'If' node (checking Google Sheets) and the 'Text Classifier' node (checking post content) to ensure the conditions for skipping summarization meet your needs.
- Test the workflow with a single post first, then activate it for ongoing automation.
Want your own unique AI agent?
Talk to us - we know how to build custom AI agents for your specific needs.
Schedule a Consultation