How I built an end-to-end content pipeline that turns a single research topic into a fully drafted, SEO-optimized, brand-aligned blog post in under 5 minutes.
Customers buying functional food products increasingly want to understand the science behind what they're eating. For We Are The New Farmers, that meant a growing demand for high-quality, scientifically backed content about spirulina: its health benefits, its functional properties, and its role in specific conditions.
The problem was capacity. Writing a single well-researched post meant finding credible sources, synthesizing them into an outline, drafting in our brand voice, and optimizing for the right keywords. At 60 to 90 minutes per post, building a meaningful content library would take months of manual work. We needed a different approach.
"The constraint wasn't ideas or knowledge. It was the time cost of translating research into publish-ready content at any reasonable volume."
An automated pipeline that takes a single topic as input and returns a fully drafted, Shopify-ready blog post as output. The system handles research aggregation, source management, SEO integration, and brand voice alignment without any manual steps between input and draft review.
The output is better than what I was producing manually. Posts are more thoroughly sourced, more consistently structured, and already formatted with HTML tags for direct paste into Shopify's blog interface. One afternoon of running the pipeline generated enough content to cover the rest of the year.
How It Works
The only required input is a topic. I used ChatGPT to convert raw SEO keywords into richer, more specific research prompts that yield better downstream content.
The query refiner takes the input and generates five distinct search queries to ensure comprehensive coverage of the topic from multiple research angles.
The five queries are passed via HTTP request to OpenRouter, which routes them to the best available model for deep research. The agent returns a structured summary and a list of primary sources used.
Every research request automatically creates a new record in Airtable storing the topic, the OpenRouter summary, and all citations. This doubles as a reusable knowledge base for future agents and content workflows.
The writing agent converts the research summary into a New Farmers blog post. Its system prompt contains full content structure guidelines, HTML formatting rules for Shopify, brand voice samples, product integration instructions, scientific accuracy requirements, and SEO keyword logic. The agent autonomously selects the most relevant keywords and flags them in the output for human review.
The workflow creates a new Google Doc titled after the blog post, containing the full draft formatted for direct paste into Shopify. Human review remains the final step before publishing.
Tools and Stack
A full walkthrough of the pipeline from topic input to finished Google Doc output.