How we turned a workshop on AI content generation into a multi-agent pipeline that researches keywords, builds content strategies, and generates production-ready articles, with humans in the loop where it matters.
The Workshop That Started It All
We recently attended a workshop on SEO-Optimised AI Content Generation run by Dr Sam Donegan from MLAI. The session was part of MLAI's series on practical AI applications for business, and it was one of the most useful workshops we've attended.
Dr Sam's premise is straightforward: most businesses know they need content. They know SEO matters. But the gap between "we should blog more" and actually publishing consistent, high-quality, search-optimised content is enormous. His solution is what we call a content factory, a pipeline of AI agents that handle the heavy lifting of research, strategy, and generation.
The approach stuck with us because it wasn't just "throw GPT at a keyword and hope for the best." It was systematic. Data-driven. And most importantly, it treated content generation as an engineering problem: inputs, processing, outputs, feedback loops.
How the Pipeline Works
The content factory is built as a sequence of specialised AI agents. Each agent has a specific job, specific inputs, and hands off to the next agent in the chain.
Agent 1: The Researcher
The first agent doesn't write a single word. Its job is discovery. Given your domain and a list of competitors, it:
- Scrapes competitor sitemaps to understand what content already exists in your space
- Queries the DataForSEO API for keyword ideas, related keywords, and what your competitors rank for
- Analyses SERP results for target keywords to understand what Google currently rewards
- Ranks opportunities by search volume, keyword difficulty, and search intent (informational, commercial, transactional)
This is the part that grounds the entire pipeline in reality. Without real data, you're guessing. With DataForSEO feeding actual search volumes and difficulty scores, you're making informed decisions about where to invest your content effort.
The output is a ranked list of keyword opportunities: gaps where search demand exists and competition is beatable, grounded in real data rather than guesswork.
Agent 2: The Strategist
The strategist takes the research output and makes editorial decisions:
- Selects the best topic based on the balance of volume, difficulty, and relevance
- Generates an article outline with H1, H2s, and a content structure
- Creates SEO metadata including meta title (under 60 characters), meta description (under 160 characters), and target keyword list
- Scrapes the top-ranking content for the selected keyword to understand what "good" looks like
- Builds a content brief that captures all the research context the writer will need
This is where the magic happens. The strategist builds a complete brief that would normally take a content marketer hours to assemble.
Agent 3: The Writer
The writer agent receives the full content brief, including the keyword research, the competitor analysis, the SERP context, and the outline, then generates a complete article. In our implementation, the output is production-ready code: a React component with Tailwind CSS styling that drops directly into a Next.js site.
But the real sophistication is in the SEO and AEO optimisation baked into the writing prompt:
- JSON-LD structured data including Article schema, FAQ schema, BreadcrumbList, and HowTo schema where relevant
- A "Key Facts" summary card at the top, designed to be extracted by AI search engines (Perplexity, ChatGPT, Google AI Overviews)
- FAQ sections with 6+ items, with questions matched to common search queries
- Direct answers in the opening paragraph. The first sentence answers the primary query
- Semantic HTML with proper use of
<article>,<section>,<aside>for machine readability
This dual optimisation for both traditional SEO and answer engine optimisation (AEO) is what makes the output genuinely useful in 2026, where an increasing share of search traffic flows through AI-powered interfaces.
Agent 4: The Image Generator
Every article needs visuals. A separate agent extracts image requirements from the generated article and creates them using AI image generation (Gemini). Hero images, section illustrations, and diagrams are all generated and injected automatically.
Agent 5: The Publisher
The final agent takes the complete package, including article code, images, and SEO configuration, then pushes it to GitHub as a branch, ready for review and merge.
We Took It Further
Dr Sam's workshop gave us the conceptual framework and the initial tooling. But we wanted to make it practical for ongoing use, something we could run repeatedly rather than a one-off demo.
Custom UI
We built a full web interface for the content factory. The backend is a FastAPI Python application, and the frontend is a TypeScript single-page app. The UI gives you:
- Live pipeline logs so you can watch each agent work in real time
- Article preview with rendered HTML and images before you publish
- Code output to copy the generated React component directly
- Export management to save, review, and compare generated articles
Multiple Profiles
Different businesses need different content strategies. We added a profile system so you can save configurations for different brands:
- Brand name, industry, target audience
- Competitor list and seed keywords
- Article categories and design guidelines
- Site architecture context
Switch between profiles and you're running the factory for a completely different business. We tested it on a pet photography studio, our own AI platform products, and a financial services client. Same pipeline, different inputs, relevant outputs each time.
Human-Controlled Keyword Selection
This is the change that matters most. Rather than letting the AI pick the keyword autonomously, the research agent returns a ranked list of opportunities and the human picks which one to pursue.
You see the keyword, the monthly search volume, the difficulty score, the search intent. You choose. Then the pipeline continues with your selection.
This single interaction point keeps you in control of your content strategy while letting the agents handle the execution.
A Quick Demo
Here's what a typical session looks like:
1. Finding Keyword Opportunities
Enter your domain and competitors. Add seed keywords that describe your space. Hit "Run Research."
The researcher agent goes to work, scraping sitemaps, querying DataForSEO, and analysing SERPs. A few minutes later, you have a ranked list of 25 keyword opportunities with volume, difficulty, and intent data.
2. Creating a Content Strategy
Pick the keyword that aligns with your business goals. The strategist agent takes over, scraping competitor content for that keyword, analysing what currently ranks, and building an outline and content brief.
3. Generating the Content
One click starts the writer. It receives the full brief, all that research context, the competitor analysis, and the SEO requirements, then generates a complete article. Production-ready code with structured data, FAQ schema, accessibility attributes, and responsive design.
4. Publishing to Your Site
Review the preview. Check the code. If it looks good, the publisher pushes it as a GitHub PR. Review, merge, deploy. Your new SEO-optimised article is live.
The SEO Tactics We Used (Yes, on This Article)
This article practices what it preaches. Here's what we've applied:
- Target keyword in H1 and URL slug. "Building an Agentic SEO Content Factory" contains our primary keywords
- Key Facts summary card, structured for AI snippet extraction (the box at the top)
- FAQ section below with 8 questions matching search queries around AI content factories
- Direct answer in the opening paragraph. The intro tells you what this is about immediately
- Semantic heading hierarchy. H1 for the title, H2 for sections, H3 for subsections, no skipping
- Internal and external links, linking to MLAI, DataForSEO, and our own platform
- Meta title under 60 characters, optimised for SERP display
- Meta description under 160 characters, crafted for click-through
- Structured data including Article schema and FAQ schema (in the published version)
- Long-form depth with comprehensive treatment rather than thin content. Search engines reward thoroughness
- AEO optimisation. The Key Facts card and FAQ section are specifically designed for AI search engines to extract and cite
The meta irony is deliberate. If you're writing about SEO content generation, you'd better be doing it well yourself.
The Ethics Question
Let's talk about the elephant in the room.
We don't agree with slop generation. We don't think the internet needs more AI-generated garbage filling search results with thin, repetitive, keyword-stuffed nonsense. The "dead internet" concern is real, and anyone building content automation tools has a responsibility to think about what they're contributing.
Here's where we land: the value is in the research and strategy, and humans need to stay in the loop.
The DataForSEO data is genuinely useful. Knowing that a keyword has 2,400 monthly searches and a difficulty score of 35 is real intelligence that helps you make better content decisions. The competitor analysis, understanding what currently ranks and why, is research that would take hours to do manually.
The content brief that the strategist produces is, honestly, better than what most content marketers write. It synthesises research, competitor context, and SEO requirements into a coherent plan.
But the generation step? That's where human judgement needs to stay involved. A generated article is a draft. It needs your voice, your expertise, your perspective, your stories. The factory gives you a running start, a strong foundation to build on.
Our approach is: automate the research, keep humans in the strategy, use AI for the first draft, and always edit before publishing. The large amount of human-in-the-loop between strategy and generation is what separates a content factory from a slop factory.
The Tech Stack
For those who want to build their own:
| Component | Technology |
|---|---|
| Backend | Python, FastAPI, uvicorn |
| Frontend | TypeScript, Vite (vanilla, no framework) |
| Research API | DataForSEO Labs API v3 |
| Strategy Agent | Gemini 3 Flash |
| Writer Agent | GPT-5.2 |
| Image Generation | Gemini 3 Pro Image (Nano Banana) |
| Publishing | GitHub API (branch + PR creation) |
| Deployment | Railway (Docker) |
The agents are Python classes that inherit from a base agent. Each has a run() method, accepts structured input, and returns structured output. The pipeline orchestrates them sequentially, streaming logs to the frontend via the API.
Frequently Asked Questions
- What is an agentic SEO content factory?
- It's a pipeline of specialised AI agents that handle content research, strategy, writing, and publishing. Each agent has a specific role, and they work in sequence to produce SEO-optimised articles from competitor and keyword data.
- How is this different from just using ChatGPT to write articles?
- ChatGPT writes from its training data. A content factory starts with real SEO data, including actual search volumes, competitor rankings, and keyword difficulty scores, then builds content strategy around that data before any writing begins.
- What is AEO (Answer Engine Optimisation)?
- AEO optimises content for AI search engines like Google AI Overviews, Perplexity, and ChatGPT search. It involves structured data, summary cards, FAQ sections, and direct-answer formatting that makes it easy for AI systems to extract and cite your content.
- Do I need the DataForSEO API?
- The pipeline is significantly more useful with real keyword data. DataForSEO provides search volume, keyword difficulty, competitor organic keywords, and SERP analysis. Without it, you're making content decisions without data.
- Can I use this for any industry?
- Yes. The profile system allows you to configure different brands, competitors, and industries. We've tested it on pet photography, AI platforms, and financial services. The pipeline adapts to whatever domain you feed it.
- Does this replace content writers?
- No. It replaces the research and first-draft phase. The generated content needs human editing, voice, expertise, and fact-checking before publishing. Think of it as a very capable research assistant, not a replacement for editorial judgement.
- How long does the full pipeline take?
- Research takes 2-3 minutes (scraping and API calls). Strategy takes about a minute. Writing takes 1-2 minutes. Total: roughly 5 minutes for a complete first draft with SEO metadata, structured data, and images.
- Is the generated content good enough to publish directly?
- We wouldn't recommend it. The output is a strong first draft with solid structure, SEO optimisation, and factual content. But it needs your perspective, your stories, and your editorial voice before it should go live.
Ready to Build Your Own Content Factory?
If you're a business that needs consistent, high-quality, SEO-optimised content, and you're tired of the gap between "we should blog more" and actually doing it, we can help.
We build custom content pipelines tailored to your brand, your industry, and your content strategy. Real keyword data. Real competitor analysis. Human-in-the-loop at every stage that matters.
DM me on LinkedIn to start the conversation.
This article was researched by AI agents, drafted by a human with AI assistance, and edited by a human. We practice what we preach.
Workshop credit: Dr Sam Donegan, MLAI, SEO-Optimised AI Content Generation