Part 64: I, for one, welcome our new AI blogger overlords

Robot writing blog posts

As I now have GPT4All perfectly suitable for writing fascinating stories about everything, why not to utilize it even more? Please welcome the new spin-off website, What's up, home? Generative AI Edition. A cronjob running on my What's up, home? environment will run itself every morning 7am Finnish time, generate a fresh new story based on active Zabbix alerts, and post it to the new website over Drupal API.

Why,  oh why?

Just because I can. And, just because all this stupid play can be useful elsewhere. Imagine if you ask the little AI to write in a more formal manner, or filter alerts for you, or do anything that is actually useful in the business world, and soon enough you have Robin next to you (assuming you are Batman).


For the alert gathering and storywriting part, look at my recent blog entry. For posting to Drupal, it's just Python's requests library.

data = {
       "data": {
       "type": "node--article",
       {"title": str(blogtitle),
         "body": { "value": str(response1), 
                   "format": "plain_text" 
headers = {'Content-type':'application/vnd.api+json',
r ="",data=json.dumps(data),headers=headers,auth=('myuser','mypassword'))

if r.status_code == 201:
   print ("Success")
   print ("Fail")

Finally, I just have a cronjob scheduled to run every day at 7am.

0 7 * * * /path/to/my/script --title "Generate a blog post title based on the following Zabbix alerts" --question "Create an ongoing story based on the following Zabbix alerts" --title "Generate a title for a blog post based on following Zabbix alerts"

And it's done! Thanks to extremely rich toolset available for free for this kind of purposes makes AI really easy.

Future plans

I fear that with the same prompt used every morning things will get repetitive really soon. I'll let it run for now like that, but to make things more interesting, soon I'll try what happens if I ask GPT4All to generate a prompt for itself, and use that prompt to generate the story.

Add new comment

Restricted HTML

  • Allowed HTML tags: <a href hreflang> <em> <strong> <cite> <blockquote cite> <code> <ul type> <ol start type> <li> <dl> <dt> <dd> <h2 id> <h3 id> <h4 id> <h5 id> <h6 id>
  • Lines and paragraphs break automatically.
  • Web page addresses and email addresses turn into links automatically.
Buy me a coffee

Like these posts? Support the project and Buy me a coffee