Career
03/11/2023

I created a content creation automation for my website

If you enjoy video content, feel free to subscribe to my channel and enable notifications so you won't miss any new content! (Just in Portuguese sorry )

VIDEO IMAGE

NOTE: It is very important that you watch the video because the content is more complete with videos and the project demo. This post will be a summary of the video, but I guarantee it's worth it.

Now, let's get to the content!

https://media.giphy.com/media/v1.Y2lkPTc5MGI3NjExMncwYWUxY2NmeGoyenUxMW90bWw1cnR4YmV4bWZoM3J4Z3k1b3NlaCZlcD12MV9pbnRlcm5hbF9naWZfYnlfaWQmY3Q9Zw/dMsh6gRYJDymXSIatd/giphy.gif

Have you ever wondered if artificial intelligence could be an ally in content production? Well, I not only wondered about it, but I also created an automation that does just that!

PROJECT'S GITHUB

I know it sounds crazy, but in this article, I will share with you the incredible journey behind the development of this automation, capable of summarizing scripts and generating articles for my website.

Today, I will explain my automation, step by step, and how it saved me several hours of work. And my biggest ENEMY on this journey was my own EGO.

https://media.giphy.com/media/v1.Y2lkPTc5MGI3NjExMWhzZXdlb2luZWNnNndtemNpajBreWR6Y2k3enZ6c3Ixa24zeTQyZiZlcD12MV9pbnRlcm5hbF9naWZfYnlfaWQmY3Q9Zw/VJBd91kUU5FJtcDUvL/giphy.gif

Introduction

First, let's understand the content creation process:

When I decided to start creating content again, I had only two goals:

  1. Bring specific topics I love and could talk about for HOURS, regardless of the technology-related subject.
  2. Help and learn from people who are following me.

Before I started recording again, I decided to post more regularly on my website, which, by the way, was a bit neglected.

I know that many people consume video content, but I also know that some prefer to consume articles, or even both, haha.

So, I decided to combine the useful with the enjoyable.

My steps for creating content are:

  1. Choose a topic that genuinely interests me.
  2. Consume a lot of content on that topic.
  3. Select the best content and consume it again.
  4. Write about the best ideas in Notion in a summarized form.
  5. Organize it into a video script, including my stories.
  6. Organize ideas about what will be inside the video.
  7. Record.
  8. Edit.
  9. Publish.
  10. Do more research, now focused only on articles.
  11. Filter the best ideas.
  12. Take my video script, rewrite it into Markdown format.
  13. Done.

That's quite a lot, isn't it?

https://media.giphy.com/media/v1.Y2lkPTc5MGI3NjExbHRmanRjZTQyNzFteXcya3A5ejV5MHNwdW04NTA1YXZhd241bWVpciZlcD12MV9pbnRlcm5hbF9naWZfYnlfaWQmY3Q9Zw/If9DvbHHowI1SWKLae/giphy.gif

I will continue to do many of these things because I enjoy doing a large part of this list. But I decided to create content automation for my blog with ChatGPT, and I will explain it to you.

In the future, I want to bring more features, such as possibly creating an API to integrate with some platforms like Tabnews, dev.to, and Medium. If you have any ideas and want me to continue with this project, comment here or on YouTube, and I will compile a list of things.

https://media.giphy.com/media/v1.Y2lkPTc5MGI3NjExeGUzMHE2cnhqNnBjZTM5Zzc3ODhrOTMydnBzNjN2d3g2eXE3aDVzcCZlcD12MV9pbnRlcm5hbF9naWZfYnlfaWQmY3Q9Zw/Xoc3XpBrElaYo/giphy.gif

  • What is Automation

Automation is the use of technology to perform tasks with minimal human assistance. Automation can be used in any sector that involves

repetitive tasks. For me, the content generation part for my blog was becoming more repetitive. So, I created an automation that takes my drafts in Notion, summarizes them, formats them in Markdown, asks me if there's a YouTube video because if there is, I insert the video link, and if necessary, it translates it into multiple languages using the command line interface (CLI). YES, command line.

  • What is CLI and What is its Purpose

CLI stands for Command Line Interface. In this environment, users can type command lines for applications to perform specific tasks. It's basically opening your terminal, typing certain commands, and the bot does everything for you.

I'm used to creating buttons, user interactions, designing good interfaces, or even building responsive pages. But since I use YouTube as my laboratory, I decided that this project would also be an experiment.

I created the first version of this BOT, very simple, with Node.js in just one file, and it took less than 1 hour. When I saw it working, I was very happy.

But I wasn't satisfied... That's when I decided to raise the stakes because a simple implementation, I decided to recreate it in a language I didn't know but was eager to learn... The Go language.

At the moment, I thought... WHY NOT?

That's when I decided to take the weekend to learn the basics of the language.

Why Go?

I know, I know... You might ask me, "WHY, LORENA? The system was already ready in a few hours in a language you already know."

https://media.giphy.com/media/z1GQ9t8FxipnG/giphy-downsized-large.gif

Do you want me to be 100% honest? I'm not even sure, haha. I just took the opportunity to take a project that would be useful for me and develop it from scratch in a technology I didn't even have installed on my PC. And that's okay with me...

But what took less than 1 hour before in NODEJS took a few days in Go, all because of my EGO. I'll explain that in a moment.

Go or Golang, as it's commonly known in the community, is a programming language developed by Google in September 2007 but was only released to the public in November 2009.

The Go language was developed to address the engineering challenges faced by Google developers when using the C language. Go has the following key characteristics:

  • It's a compiled language.
  • It's statically and strongly typed.
  • It has an integrated garbage collector, preventing memory leakage issues and ensuring proper memory management.
  • It's easy to compile and package, generating binaries that can be executed directly by the operating system without the need to install any interpreter in advance.

The reality is that there are many advantages to Go, and in my research, I found that it's widely used for CLI, so I combined the useful with the enjoyable.

Could I have done it in Node? I could have, but the point here is to learn, to "challenge my brain to see things beyond the JS world."

https://media.giphy.com/media/v1.Y2lkPTc5MGI3NjExZTU5bm85Mnh4b2NpamdybWF4ZHNkeXc5ZncxMWc4YjNzb29zMjdrYiZlcD12MV9pbnRlcm5hbF9naWZfYnlfaWQmY3Q9Zw/WErBoDjwppecPzisdg/giphy.gif

Creating My First CLI in Go

(Note that the YouTube video has details on the working code at 8:56).

In terms of code, there's much room for improvement, but instead of keeping everything in a single file, I wanted to use an architecture that made more sense and break things into smaller parts.

Put Your EGO Aside

I went through several versions of this project before reaching this final stage, and my brain always sent me messages like

"THIS IS TERRIBLE," "THE ARCHITECTURE IS BAD," "PEOPLE WILL JUDGE YOU," and honestly?

If even Jesus was judged, then who am I? Haha. I decided to end this loop of thoughts in my head.

But the truth is, it was my EGO that was affected at that moment. With every video I post on YouTube, I constantly battle my EGO.

But I understood that "done is better than perfect." I'm here to show that "I'm learning." There will never be perfect code. Obviously, in my first project in a language where I have no experience, it wouldn't be perfect. But "done is better than perfect."

"A learner is self-critical and self-motivated, always trying to improve their understanding to move on to the next topic or challenge. A true learner is their own teacher and their own critic; there's no room for ego."

And if you're thinking about starting a new project or learning a new technology, honestly? Books are cheaper than ever today, and there are many free courses available.

There's no excuse for not simply learning something you want or really like.

Many programming teachers are not just paid; they might have paid courses, but you don't have to pay to learn from them. The best teachers are available on YouTube and entirely free.

Rest assured that your first code will probably be bad, but it's by getting your hands dirty that you can see growth opportunities.

So don't be ashamed of being a LEARNER; do what needs to be done, test your new projects, program in a technology you never thought of, and learn.

Until next time! https://media.giphy.com/media/mP8GermRyOFWV8PQeq/giphy.gif

What did you think of the post?
Lorena Porphirio