Generating 100 Blog Posts Automatically with cm-content-factory
Hướng dẫn chi tiết về Generating 100 Blog Posts Automatically with cm-content-factory trong Vibe Coding dành cho None.
Generating 100 Blog Posts Automatically with cm-content-factory
The “blank page” is the greatest enemy of the modern digital builder. In the era of Vibe Coding, we have the tools to build applications in minutes, yet we often spend weeks struggling to describe them to the world. You’ve built a revolutionary SaaS, a sleek mobile app, or a complex developer tool, but your blog is a graveyard of “Hello World” posts and outdated feature announcements.
Scaling a content engine manually is a nightmare. Freelance writers are expensive and often miss the technical nuance of your product. Writing it yourself is a recipe for burnout. You need a way to bridge the gap between building at the speed of thought and marketing at the speed of the algorithm.
This is where cm-content-factory comes in. It isn’t just an AI writer; it is a systematic content engine designed to ingest your project’s DNA and output a high-velocity stream of 100+ SEO-optimized, brand-aligned blog posts without you ever having to leave your terminal.
The Core Concept: From “Prompting” to “Manufacturing”
Most people treat AI writing as a series of one-off prompts. This is the “artisanal” approach, and it doesn’t scale. If you want 100 posts, you can’t sit there and hit “Generate” 100 times. You need a factory.
The cm-content-factory skill operates on a Topic Queue architecture. Instead of asking the AI for “a blog post about X,” you define a strategy, seed a queue of 100 topics, and let the worker agents handle the heavy lifting.
The Anatomy of the Factory
The factory consists of four primary components:
- The Strategy Config (
content-factory.config.json): This is the “Master Blueprint.” It defines your brand voice, target audience, and the frameworks (like StoryBrand or Cialdini) that the AI must follow. - The Topics Queue: A directory (
topics-queue/) containing JSON batches of raw ideas, keywords, and titles. - The Writer Engine (
scripts/content_writer.py): The Python-based orchestration layer that manages API calls, token limits, and file I/O. - The Audit Gate: A validation step that checks every generated post for SEO requirements, technical accuracy, and “AI-slop” patterns before it hits your
src/content/folder.
Step 1: Configuring Your Content Blueprint
Before the factory starts humming, you must define the “Vibe.” This is done in the content-factory.config.json file. An intermediate setup requires more than just a “professional tone” setting; it requires a deep integration of your project context.
{
"brand_voice": {
"identity": "The Technical Architect",
"tone": "Authoritative yet accessible, high-signal, zero-fluff",
"vocabulary_constraints": ["Avoid 'delve', 'unlock', 'comprehensive'"],
"target_persona": "Mid-level software engineers and technical founders"
},
"seo_defaults": {
"min_word_count": 1200,
"max_word_count": 1600,
"internal_link_targets": ["/docs/how-it-work", "/skills/cm-debugging"],
"schema_type": "TechArticle"
},
"frameworks": ["StoryBrand", "Cialdini-Authority", "Hook-Model"],
"output_format": "Astro-Markdown"
}
By defining these constraints, you ensure that post #1 and post #100 sound like they were written by the same person. The cm-content-factory skill uses these settings to dynamically inject “System Instructions” into every generation cycle.
Step 2: Seeding the 100-Topic Queue
You don’t need to come up with 100 titles yourself. You can use the cm-brainstorm-idea skill to generate the queue. For example, if you are building a tool for Vibe Coding, your queue generation command might look like this:
cm-brainstorm-idea "Generate 100 blog post topics around 'Vibe Coding', 'AI Agents', and 'Terminal-first development' for mid-level developers."
The output is saved into topics-queue/batch-001.json. Each entry in the queue looks like this:
{
"id": "post-042",
"title": "Debugging AI Agents in the Terminal: A Guide to cm-debugging",
"keywords": ["ai agents", "debugging", "terminal-first", "cody master"],
"intent": "Educational/Tutorial",
"primary_jtbd": "Help the user reduce time spent on failed agent loops"
}
Step 3: The Execution Loop
With the configuration set and the queue seeded, you trigger the factory. In a Vibe Coding environment, this is often handled by a background script that monitors the queue and dispatches jobs to the AI.
The scripts/content_writer.py script is the heart of this operation. It doesn’t just call an LLM; it performs a multi-pass generation:
- Research Pass: The agent reads your
docs/andsrc/to find relevant code snippets for the specific topic. - Outline Pass: It generates a structured Markdown outline based on Content Mastery principles (Hook, Problem, Solution, Action).
- Drafting Pass: It writes the 1200-1600 word body, ensuring technical accuracy.
- SEO Pass: It injects metadata, alt-text placeholders for images, and internal links.
To run the factory for the first batch of 25 posts, you would use:
run_shell_command "python3 scripts/content_writer.py --batch topics-queue/batch-001.json --limit 25"
Step 4: The Interactive Audit Gate
Automatically generating 100 posts is useless if 50 of them are hallucinations. The cm-content-factory includes a “Quality Gate.” This is an automated test suite for content.
We use the test/frontend-safety.test.ts or a specialized scripts/audit-content.js to verify:
- Length: Is it between 1200 and 1600 words?
- Tone: Does it contain banned “AI-isms” (e.g., “In the fast-paced world of…”)?
- Links: Do all internal links resolve to valid pages in your Astro/VitePress site?
- Code: Do the code snippets actually compile or make sense?
# Example audit command
node scripts/audit-content.js --path src/content/blog/post-042.md
If a post fails the audit, the factory marks it as “Needs Refinement” in the queue and moves on. This ensures that your deployment pipeline only sees high-quality artifacts.
Scaling to 100: Token and Cost Management
Generating 1.5 million words (100 posts * 1500 words) consumes a significant number of tokens. To do this efficiently, cm-content-factory leverages Hugging Face Jobs or Anthropic Prompt Caching.
By caching your brand_voice and project_context (your README.md, ARCHITECTURE.md, and STYLE_GUIDES), you can reduce the cost of each subsequent post by up to 90%. The factory sends the heavy context once and then only sends the topic-specific delta for each post in the batch.
Handling Hardware Constraints
For a batch of 100, local execution might be slow. The intermediate Vibe Coder uses a “Remote Worker” pattern. You can push your topics-queue/ to a Hugging Face Space and run a GPU-accelerated worker to burn through the list in under 30 minutes.
Best Practices & Tips for High-Signal Content
- Seed with Real Code: The best blog posts for developers contain code. Ensure your
content_writer.pyhas access to yourtest/orexamples/directory. A post that explains how to use a feature using a real test case from your repo is 10x more valuable than a generic summary. - Iterative Brand Tuning: After the first 5 posts, read them. Notice any repetitive phrases? Add them to the
vocabulary_constraintsin your config. The factory gets smarter the more you restrict its “bad” habits. - The “Vibe” Check: Use the
get_screenshottool from the Pencil MCP to visualize how the post looks on your blog layout. Sometimes a 1600-word post looks like a “wall of text” if your typography isn’t tuned. - Use Content Mastery Frameworks: Don’t just write info; solve a “Job to be Done” (JTBD). Every post should start with a specific pain point (e.g., “Are your AI agents getting stuck in infinite loops?”) and end with a clear action (e.g., “Install the cm-debugging skill today”).
Practical Example: A 10-Post “Sprint”
Let’s say you want to dominate the search results for “Astro i18n automation.”
- Seed: Create
topics-queue/i18n-sprint.jsonwith topics like:- “Automating Astro i18n with custom scripts”
- “Why hardcoded strings are killing your global growth”
- “Testing i18n parity with Vitest”
- Execute:
cm-content-factory --batch i18n-sprint.json - Deploy: The posts are automatically written to
src/content/articles/en/. - Translate: Trigger
scripts/deep-translate-i18n.jsto clone those 10 posts into 5 other languages using the same factory logic.
In one hour, you’ve gone from 0 posts to 60 (10 topics * 6 languages), all maintaining your exact technical standards.
Conclusion
Automating 100 blog posts isn’t about flooding the internet with noise; it’s about removing the friction of communication. In Vibe Coding, your ability to document and market is just as programmable as your ability to code.
By using cm-content-factory, you turn content creation into a repeatable, auditable engineering process. You stop being a writer who occasionally codes and start being an architect who manufactures authority. Your blog becomes a living extension of your codebase—always up to date, always technical, and always working to bring users into your ecosystem while you sleep.
Start small. Seed 5 topics today. Tune your blueprint. By next week, your “factory” will be ready to scale to 100 and beyond.