Automate Blog Creation in Brand Voice with AI n8n Workflow Template

n8n workflow template · 18 nodes · OpenAI

Automate Blog Creation in Brand Voice with AI is a free n8n workflow template that starts when you run it manually in the n8n editor and works with OpenAI and WordPress. It has 18 nodes, 6 of them AI nodes (OpenAI Chat Model, Information Extractor and Basic LLM Chain). The notes inside the workflow say: “First, we'll need to gather existing content for the brand voice we want to replicate.” To run it, you add your own credentials for OpenAI API and WordPress API.

At a glance

Trigger
Manual Trigger (When clicking ‘Test workflow’)
Nodes
18
Apps
OpenAI and WordPress
AI nodes
6
Credentials
2 types
Category
Content, SEO and social media

Apps and integrations

  • OpenAI
  • WordPress

Node types used

  • Manual Trigger
  • OpenAI Chat Model
  • Information Extractor
  • HTTP Request
  • HTML
  • Split Out
  • Limit
  • Aggregate
  • Merge
  • WordPress
  • Basic LLM Chain
  • Markdown
  • Edit Fields (Set)

How it works

The text below comes from the sticky notes inside the workflow. We removed links, code samples and anything that looks like a key or token.

1. Import Existing Content

Read more about the HTML node

First, we'll need to gather existing content for the brand voice we want to replicate. This content can be blogs, social media posts or internal documents - the idea is to use this content to "train" our AI to produce content from the provided examples. One call out is that the quality and consistency of the content is important to get the desired results.

In this demonstration, we'll grab the latest blog posts off a corporate blog to use as an example. Since, the blog articles are likely consistent because of the source and narrower focus of the medium, it'll serve well to showcase this workflow.

Q. Can I use other media than blog articles?

A. Yes! This approach can use other source materials such as PDFs, as long as they can be produces in a text format to give to the LLM.

2. Convert HTML to Markdown

Learn more about the Markdown node

Markdown is a great way to optimise the article data we're sending to the LLM because it reduces the amount of tokens required but keeps all relevant writing structure information.

Also useful to get Markdown output as a response because typically it's the format authors will write in.

3. Using AI to Analyse Article Structure and Writing Styles

Read more about the Basic LLM Chain node

Our approach is to first perform a high-level analysis of all available articles in order to replicate their content layout and writing styles. This will act as a guideline to help the AI to structure our future articles.

4. Using AI to Extract Voice Characteristics and Traits

Read more about the Information Extractor node

Second, we'll use AI to analysis the brand voice characteristics of the previous articles. This picks out the tone, style and choice of language used and identifies them into categories. These categories will be used as guidelines for the AI to keep the future article consistent in tone and voice.

5. Automate On-Brand Articles Using AI

Read more about the Information Extractor node

Finally with this approach, we can feed both content and voice guidelines into our final LLM - our content generation agent - to produce any number of on-brand articles, social media posts etc.

When it comes to assessing the output, note the AI does a pretty good job at simulating format and reusing common phrases and wording for the target article. However, this could become repetitive very quickly! Whilst AI can help speed up the process, a human touch may still be required to add a some variety.

Q. Do I need to analyse Brand Voice for every article?

A. No! I would recommend storing the results of the AI's analysis and re-use for a list of planned articles rather than generate anew every time.

6. Save Draft to Wordpress

Learn more about the Wordpress node

To close out the template, we'll simple save our generated article as a draft which could allow human team members to review and validate the article before publishing.

Setup notes

The text below comes from the sticky notes inside the workflow. We removed links, code samples and anything that looks like a key or token.

Try It Out!

This n8n template demonstrates how to use AI to generate new on-brand written content by analysing previously published content.

With such an approach, it's possible to generate a steady stream of blog article drafts quickly with high consistency with your brand and existing content.

How it works

  • In this demonstration, the n8n.io blog is used as the source of existing published content and 5 of the latest articles are imported via the HTTP node.
  • The HTML node is extract the article bodies which are then converted to markdown for our LLMs.
  • We use LLM nodes to (1) understand the article structure and writing style and (2) identify the brand voice characteristics used in the posts.
  • These are then used as guidelines in our final LLM node when generating new articles.
  • Finally, a draft is saved to Wordpress for human editors to review or use as starting point for their own articles.

How to use

  • Update Step 1 to fetch data from your desired blog or change to fetch existing content in a different way.
  • Update Step 5 to provide your new article instruction. For optimal output, theme topics relevant to your brand.

Need Help?

Join the Discord or ask in the Forum!

Nodes in this workflow

The 18 nodes in file order (sticky notes excluded). Branches and connections determine execution order in n8n:

  1. When clicking ‘Test workflow’ (Manual Trigger)
  2. OpenAI Chat Model (OpenAI Chat Model)
  3. OpenAI Chat Model1 (OpenAI Chat Model)
  4. OpenAI Chat Model2 (OpenAI Chat Model)
  5. Extract Voice Characteristics (Information Extractor)
  6. Get Blog (HTTP Request)
  7. Get Article (HTTP Request)
  8. Extract Article URLs (HTML)
  9. Split Out URLs (Split Out)
  10. Latest Articles (Limit)
  11. Extract Article Content (HTML)
  12. Combine Articles (Aggregate)
  13. Article Style & Brand Voice (Merge)
  14. Save as Draft (WordPress)
  15. Capture Existing Article Structure (Basic LLM Chain)
  16. Markdown (Markdown)
  17. Content Generation Agent (Information Extractor)
  18. New Article Instruction (Edit Fields (Set))

Credentials you need

  • OpenAI API – used by OpenAI Chat Model, OpenAI Chat Model1 and OpenAI Chat Model2
  • WordPress API – used by Save as Draft

Configure your own credentials after importing. Create each credential in n8n, then select it in the node.

How to import into n8n

  1. Download the JSON file with the button above.
  2. In n8n, open a new workflow, select the ... menu and choose Import from File. You can also paste the JSON straight into the editor canvas.
  3. Open each node that shows a warning and select or create its credential.
  4. Read the notes on the canvas, test the workflow with sample data, then activate it.

Do you need somewhere to run it? Read our guide to self-hosted n8n.

Need this customised?

We can adapt this workflow to your apps, data and process, then deploy and support it.

Contact Us