📱

Get Our Mobile App

Take your business learning on the go!

Download on the App StoreGet it on Google Play

I Used N8N to Automate a $10M/yr AI Influencer - Here's How (AI Influencer Toolkit Tutorial 🥚)

RoboNuggets•26:07

Transcription

This influencer has 2.3 million followers and makes over $10 million a year. But here's the twist. She [music] is not real. Neither is this person or that one or these ones. And yet, they're earning real money through brand sponsorships and revenue, affiliate deals, and are so successful that the agency that made her got acquired for $125 million.

Now, if you really think about it, is it really that surprising? There are characters out there with more fame and higher valuations than most living people. The difference now is with AI, anyone, even you, can create your own. So, in this video, I'll show you exactly how to build an AI system that runs your own virtual [music] influencer. And all you need to do is give it an image of your character, choose their setting or outfit if you want, how many posts you want to schedule, and the system generates and schedules your content automatically.

>> So, I'm actually obsessed with this fit. [music] Got this brown dress from Nano Fashion, and it seriously makes me feel like I'm starring in my own Paris movie. So, I know you guys have been asking about my laboo. Look at this little fluffy guy. Who says cosplay can't be everyday fashion? All right, besties. You know the LA kick is everywhere, so obviously I had to try it. >> This burger looks insane. You know you want to bite it, right? >> What's one thing about making the movie you never told anyone?

And the great thing is we're using no code tools, so anyone can learn this. So if you watch till the end, you'll walk away with a full blueprint to manage your own AI influencer on autopilot. Let's get started.

Hey, if you're new here, my name is Jay. I spent a decade in creative and marketing work and half a decade leading data teams and now founded my AI agency and also RoboNuggets, our education arm where we have several hundred members, all AI practitioners across the globe. And here our mission is to make creating with AI easy to learn regardless what your background is with a wealth of AI lessons that most people will join for, but most members stay because of the community that we have built.

So, as mentioned, this influencer Michaela was made by this creative agency called BRD. She has millions of followers on socials and has been around since 2016, actually. So, even before AI blew up, digital influencers like her were already a thing. And if you just read through some of the comments of her fans here, it's clear that they know she's fictional, but it doesn't matter so much to them because they enjoy her content. So, in a way, it's similar to how people know Mickey Mouse is fictional, but people still watch his stuff and buy his merch.

But the thing is, back then to create something like Michaela, you'll need to know how to use expensive 3D modeling software like Cinema 4D. But now with AI, literally anyone can create characters like these. And that's what I'll teach you today. Because if you have this AI system, it's pretty much all you need to create and post content for your character as many times as you want and on autopilot.

In this system, we built it in N8N, which in case you're new, N8N is a no code automation tool similar to Zapier or Make.com. And the great thing about N8N is if you need a shortcut and are a bit more advanced, if you're part of the community, you can just download this template, import it into N8N, and that will create the system for you from scratch. But if you're a beginner, don't worry because I'll be walking you through how to build this system step by step as well.

So, just in case you don't have a character yet, I have three quick tips for you to get you started. And the first one is to create your character, you can just head to ChachiPT or Google Gemini and give it a structured prompt like this, which you can take a screenshot of and just use it as a basis for the structure of what you want your character to look like. And that can give you a starting image for your character. But what's key is once you have that image, you'll actually need more images of that same character so that you have multiple reference images that you can use.

So what I usually recommend is to go to this link called key.ai, which is a tool that we'll discuss more in depth later. But if you go to their Creamedit model here in this URL, you can just upload the image of your character, give it a prompt like this. And what's great about Cream here is that you can set the image resolution to 4K and you can get a lot of images in just one click. And when you run that, that will give you several images of your character, which you can just select from and take screenshots of.

And another thing that you can do is if you head to key.AI's V3 implementation in this URL, you can select image to video and upload your reference character here. And if you give it a prompt like this where the character stands in a wellet studio and rotates 360°, what you'll now get is a video of your character where they are rotating. And for example, if you need a video or image where you need to show their side profile, then you can just pause there and take a screenshot of this image.

Now to build the automation itself for you to get started. You can just sign up at N8N through this link where you can get a free trial. And when you are in your N8N dashboard, just go ahead and create a workflow here. And the first step we'll add is going to be our trigger, which for this system is going to be an N8N form. And when you add that form, you can just double click it. And this will take you to N8N's setup design for each and every node where here in the left is where you'll find inputs from previous nodes. This area in the middle contains the setup for the node that you are configuring. And here on the right would display all of the information coming from this node. And this form figure is quite simple. It's sort of like setting up a Google form really. So here you can just give it a title, a form description. And just to illustrate one, let's add a form element here and call it as the character image and change this element type into file. We can disable multiple files for this one and set this as required. And when we execute this step, what that will open is going to be a form that later on you can send to yourself or to your clients in order to trigger this automation.

So there's only one field here now. So, what we'll do is just enrich this form in order to have all the fields that we need. So, now we've edited this completely. And what we have here is a place to upload the setting of where your character will be. And we set this as optional. An optional image for an item that your character will be interacting with, a field for how many images you need and how many videos as well. A free text field for your creative direction, and this is where you can put your script or basically what you want your AI character to do. And finally, a field for the aspect ratio. So either a vertical post or a horizontal post is what we can get.

So in order to test this out, we'll just execute this step. And you can see it's listening for a test form submission now. So we'll just go ahead and fill this up. And for the images, what we'll do is upload the image of Michaela for the character, an image of Paris for the setting, and we'll have her wear this dress. For this one, we'll do two images and one video to illustrate. And we'll just give it a simple direction here around the character wearing the dress in this setting. And she also talks to the camera about how she loves it and how she got it from this brand. We'll select 9 by 6 to get vertical posts. And once we hit submit, when that's submitted, we can go back to N8N. And you can see here in the output those three images. And if you go to the schema, you'll find here the inputs that you made in those fields.

So now for this first step, what we'll need to do is to get those images ready for our AI agent. And the way you do that is through this node called extract from file, specifically this action for moving the file to base 64 string. And if you look at the inputs here, if we go to the binary tab, what we just need to do is to change this input binary field name into character image because that's what we named this field. And if we click execute this step, the output from this node is this pretty long piece of data, which actually translates to this character image that we provided NN earlier. So if we preview this, you'll remember that was the image of Michaela that we sent. And this node is just translating that into raw data.

So now we'll just need to do that for the two other images. So what you can do is just highlight this and click Ctrl D twice. We map this to the initial form node. Same as what we did last time. And if we just organize this, open the second one. This one now is for our setting image which is this one. So if we click execute step again, go to schema here. Basically this data is what this image looks like when it is parsed to become a base 64 string is what they call it. Same here with the third extract from file node. So let's just change this to the third image which is going to be item image. And if we execute that that now translates this image into raw data as well.

So now these three will just need to merge them into one node again. So if you just look for the merge node, change the number of inputs to a tree and then link this one by one to the inputs here. And if we open this and just click execute step, what it's now going to do is pass all of those raw data into this merge node. And if you go to the table view, you'll find here those three images translated into raw data which you can validate has been properly passed because it says here that is now passing three items.

Now in order for our AI models to use them, we actually need to upload them to a URL. And you'll see how that works in a bit. But basically to do this, you just need to find this HTTP request node which is one of the most common nodes in N10 because it's the main way by which we can call on third party tools from within this platform. And what we're going to do here is just change this method to post because we'll be posting a request into this URL which you can type here. And you can see this service is called key AI. And in case you're new, key.AI is an AI model aggregator. You can see here they have several models available. And their service essentially lets us access these models much easier and often much cheaper as well. So we'll use this to generate the images and videos as well. But at least for this instance, what we'll use them for is their file upload capability, which just lets us upload images into their servers or their computers. so that we can have those URLs that we need later on.

So to do that, this is the URL that you need to post your request to and the request will send will be contained in this body section where you will basically need to add two parameters and this is just as per KI's documentation. The first one will be type as B 64 data taking note of the capitalization there and the second one is upload path. So now the value for this if you go to schema you can just drag this data in here. And for the upload path I believe you can just decide what this is but in terms of what we tested we just put in documents/uploads in there. And there's a third parameter apparently. So file name with a capital N. And then this can be any file name that you want. It just needs to be unique. So what we did here is to just find a unique value in our input section. And the one that can work in this case is if you go to variables in context you just drag this dollar now value because that includes the time stamp for this specific second. and just use that as the file name. This is mainly the file name in KI's servers anyway. So, it's not really something that we'll be using, but we just need it to be unique.

So, now if you execute this step, it'll likely error because we have not yet set up our credentials, which is the main way by which you can prove that you have the rights to access KI. So, to do that, just go to generic credential type here. Click on header off and create a new credential. Rename this as something memorable. For the name, type in authorization, making sure to type this out exactly or it will error. And then under value, change this to expression so that you can see what you are typing and type in bearer space. And you're going to paste your API key in here, which you can get from this link after you sign up at key.AI. So once you have that, it will look something like this. And just click on save. Make sure that credential is selected. And now we can re-execute this step. And if you set it up correctly, it will say here that the file has been uploaded successfully and those files are now living in these URLs in their servers or computers. And there you go. That is step one already done.

So the next thing that you want is going to be this aggregate node. And what you just need to put here is this download URL. And once you execute this step, what it will just do is aggregate these three items and group them into one. And this is necessary so that we can feed this corpus of URLs into our AI agent which is going to be the next node that we will configure. So once you have that selected just change this to define below because for these AI agents first you need to define your user prompt. So if you change this to expression and click on this expand so that you can see I'll just type in the expression I already made here and just to go through it this user prompt is sort of like what you would say to chat GPT but the only difference in N8N is that we have these green values which are dynamic values and what we're basically doing here is we are getting the values coming from the form that we just submitted in terms of how many images that we want for example and you can see here that in reality for this specific execution since we said two that is what is shown in the result here. We also have the aspect ratio as well as the creative direction that we gave. Now, if we scroll down, you can see we have our image references here. And here at the bottom is the character brief. So now this character brief is quite specific to Michaela. So obviously if you have a different character, you can just edit this. But to make it easy, what I've done is create this GPT which you can just find in the GPD app store or in our community. And you can even provide a sample Instagram feed or even a set of photos just so that this GPT can be guided on the style that you want. And what this will do is just give you a character beef that you can copy into this section.

So apart from the user prompt, you also want to add in a system message or system guideline. And what this section will do is guide your AI agent on what it needs to do with that request that you just submitted it. So if you change this to expression again so that we can expand it, we can just paste this system prompt that I made earlier. And just to go through it, this aligns to the agent framework of system guidelines which is part of what we teach in the robonets community where basically we give this agent an ask several guidelines on its role, what the output count is, constraints including some specific guidelines for how to craft an image prompt and also the video prompts which you will see in a bit. And then the E will be for examples. So here we just provided a good example of what the output should be. We also gave it some bad examples in here. And the N will be the notation or the structure of what we want. So we just provide that notation also here which again you will see once we run this agent and finally tools which are the tools that your AI agent has access to and this one I'll discuss in just a minute.

Now if you execute this step this will likely error still because it says here that it doesn't have a chat model connected yet. So to set that up just click this chat model. Lots of familiar names here in the AI space. I usually show open AAI because this is the most common. And here under credential just click on create new credential. And you'll see it's going to ask for an API key which you can just get through this link by open AAI. And once you have that pasted, you can just click on save. Make sure that's connected. And for this one, the model that I recommend would be GPD4.1. So we can just leave it as that. Now for the tool, the only thing that I recommend to add here is this think tool. And you don't need to change anything here. What that just allows your agent to do is to think about its output before responding to you to make sure that your complex user prompt has been adhered to. And then the last thing that you want here is a structured output parser. And I'll explain what that is. But for that to appear, if you just click on this AI agent again, you want to toggle this require specific output as on. And this extra branch will appear where you can click on that and click on the structured output parser. And if you change this to define using JSON schema, what this is is it's going to basically guide your AI agent on the output that you need it to provide you. And JSON by the way stands for JavaScript objectation. Basically, it's just a format. So whenever you see these brackets and braces where it is cleanly structured like this, that is what JSON is. So we can just delete this section and just paste in the output that we need here. And here you can just see that we are requesting for a title, a caption, the type of post, what the image prompt and video prompt is.

So if we go back and just run this AI agent, what it's now doing is it's activating OpenAI in order to think about its output. And near the end, it will activate the structured output parser in order to make sure that that output aderes to what you want. So when that has finished, you can see it pass an output in here. If we open this under schema, you'll find that it has created three posts for us or at least three structured prompts for posts where this one is an image. Second one is another image and the third one is going to be a video which is why we have an image and video prompt in here.

So now the last node for this part is going to be a split out node where we can just drag this posts field. And when we execute that step, what this now does is it just ungroups this one item into three or however many posts your AI agent generated. And the reason why we need these separated is because for the next step, we'll be passing these one by one into our image and video models. But now that step two is done, we can just move this up so it would look the same as what we had in the beginning. And with the final workflow here, you'll see that we are now going to get our outputs or images/v videos that are ready to post.

To start this off, what we just need to have that I recommend is this edit fields node. And we're just going to ready the elements that our AI model will be using. So if you add a field, type it in as image prompt for the first one and add in four more so that you have image 1 to three as well as the aspect ratio. What we'll now do is drag our first image from the aggregate node into this first field, the second field, and the third field. Just so that we have those reference images that we uploaded earlier in our form neatly summarized in here. And then finally for the aspect ratio you will remember that we have inputed that in our very first form node. So just drag it in there. What I also recommend is just change this item into first if in case it errors for you. And once you've done that you can just execute this step. And what that did is to just ready these elements for us to pass into our AI model which we'll be doing next.

So you can just type in and search for the HTTP request node. Change this method to post because we'll be posting a request which we'll be sending to key AI again in this URL. Make sure your credential is selected here. And under the body section, you can just specify the body using a raw JSON format. And if you change this expression and expand it so that we can see, I just paste it in the structure that KI accepts. And here you can see that we are using Google's nanobanana image model. We are passing our prompt. And here in the result, if you shuffle through this, you'll find the three image prompts that we are about to use. And here in the bottom, you'll see that we also summarize the image URLs. Because what Nano Banana will do is look at the images that you uploaded in the form and use them to be integrated in the final image that it will create. You can see that this is red because I just pasted this in and the node it references doesn't exist. So we can just fix that by dragging the aspect ratio here and copying it here in this section within the double quotes. So that is looking good.

So once we execute this step once you get a status of success or 200, what that basically means is that KI is now processing your request and has called on the nano banana model in order to generate those images. Now if in case that errors for you, it may be that you haven't loaded credits yet to your KI account. And the great thing about services like key is that you don't need to subscribe to a big monthly fee in order to get started. You can load as low as $5. And this model Nano Banana is quite cheap here. It's only 2 cents per image generated. So from what me and my team have seen, this platform has the lowest cost for automation in the market right now. But continuing this, what you want to do next is to add a weight node because we're just waiting for those images to generate. You can set this as 60 seconds and just click on execute step. And once that has finished, what you now want to do is to just duplicate this HTTP request node. map this to the weight node. And if you open that, what this node will do is to get our image for us. So if you change the method from post to get, we can also change the URL into this one because this is as per KI where our images are located. Credential stays the same, but what you need is to toggle this body as off and send a query parameter instead. So type in task ID in here and the value that we need is a task ID that was provided in your create image node. So if you just drag this out, this is now a unique value which points to the images that you generated. So if we execute this step, if your images are already done, you should now receive output where the state here says success. And if you look at the output that KI provides, you'll find a JPEG link which if you paste that in your browser, that will download the image which you can now preview.

Now finally, just to close this off, you just want to add another edit fields node. Add a field called image result. If you change this to expression and paste in this expression, what that basically is doing is it's looking at the input, which is the result JSON here, this one, and it's just grabbing this portion here, which is the JPEG link that we need. So, if you execute this step, you'll now find that this node extracted those three image files for us to use.

So now, if you notice, this whole corpus of nodes is quite different versus what we had in the final workflow. And this is an optional step, but what you can do is if you right click on this, you can convert these five nodes to a subworkflow, which if you look at our final automation here, converting them will result to this node, which points to the five nodes that you just configured. And this is a bit more advanced, so you don't necessarily have to do it. But the benefit here is that now you can just copy this node into any build that you are configuring, and paste this to any new workflow that you are building out. And now you'll be able to use nano banana without having to reconfigure those nodes yourself. But another thing, if you downloaded this template from the community, if you go to the sub workflow, you'll find that here we have some extra nodes, which I recommend if you're a bit more advanced because this just handles if there are errors or if the request is still in progress, which you don't necessarily need for this automation to work. But now that we have those images, if you're after just the image post, then you're pretty much done at this point.

What you just want to do is add a Google sheet node, specifically this append row and sheet function. And if you haven't set this up, you can just create a new credential here and link to your Google Sheets here. And what that will do is allow you to search for your Google Sheets in this dropdown. So here we can just link it to this Google sheet template that we made which if you're part of the community you can just click on this link and you can just make a copy of this template which would be this one. It's quite simple. So once you have this set up you can just select that sheet here and it should fetch the columns here in N8N where basically what we'll do is just map the generations we did into these columns so that we can properly log them. So for the title and caption if we go to this split out node that is where you'll find these values. So you can just drag them here. For the image output that is coming from the latest node that you configured here at the top. Now for the ID, I advise you to change this to expression and paste in this expression. And what this is basically doing is it's just combining the title with the execution ID which you'll find in a bit. But the reason why we're combining this is basically because we just need a unique value here in the ID which you'll see more of once we execute this step. And now finally for the publishing status, what you can do is change this expression and paste in this expression. But essentially it's just checking if our image result is available for this item. And if it is, we just load this publishing status as scheduled. So if we execute this step, what that has now done is load those three items here in our row along with the images which we can preview here. And if you open those images, you can see that these are actually pretty good. So you have the dress there, you have the setting as well as the character faithfully represented.

But now if you are at your videos, then you just have one remaining section to finish. And to start that, you can just search for this filter node where you can just add two conditions. One is under this split out node. What we want are the posts where the post type is equal to video. So that these three items can be filtered down to the ones where we need a video for them. And the other one is going to be this publish status and we just want to change this condition to is not equal to error because if this says error that means this image output is not there and so we won't be creating a video from that image as well. So, if you execute this step, we'll now filter these three items and only get the one item that we said we need a video for, which is the item that we'll proceed to the next step, which to make this easy, what I recommend is just copy this whole piece and paste it here and just map it into this section. Because what we'll be doing now is to call in the video model to animate our image. So, if you open this one, you can just remove the fields in here except for the aspect ratio. Then, you want to add the video prompt and an image URL. And the video prompt will once again come from this split out node. It's going to be this one. And the image URL will come from this edit fields node, which if we preview this image, you'll remember that this is the image that Nano Banana has already generated for us.

So now, if we execute this step, what that will simply do is ready those elements for us, which if we go to this HTTP request, this node is now to create our video. And we're still going to post our request, but for the URL, it's now going to be with KI still, but using the VO3.1 model. So under the body here, just expand it. We just remove this whole thing and paste in the one we already prepared here. And now what this structure is saying is that we are going to use this prompt. We're going to use V3 fast for our model. This is our aspect ratio. And we're going to pass in our image as the first frame of our video. So now if we execute this step, if you receive a status code of 200, that's good because we can now proceed to this weight node. And V3 takes a bit longer. So you can just set this as 120 seconds is what I recommend. And when you execute that step and the time has passed, you can now get your video through this node which we can just rename. The URL will need to change to this one for VO, but everything here should be the same. So you have your task ID in here still. So now when you execute that step and you receive a success, you'll be able to find here this MP4 link, which if you paste that in your browser, you can now download the video for you to preview.

>> So I'm actually obsessed with this fit. Got this brown dress from Nano Fashion, and it seriously makes me feel like I'm starring in my own Paris movie. >> So that looks really good. And if you notice the dialogue also contains the nano fashion call out that we included in our original creative direction.

So now all that remains is for us to just summarize and log that. So this edit field section you can just change this to vo video result. And if you delete this expression you can just drag this one which contains the mp4 file. And if you execute that step that will just pick out the mp4 file in your output so that it's clean. And so the final node that we need here is going to be another Google Sheets node but this time is going to be an update row function. You can just search for the template that you created here. It's going to pull in the columns here once again. And the purpose of this G sheet node is simply to update this specific row to include our video output in here. So in order to find this row, we just need to get this unique ID and place it here. The way you do that is by going to this append row in sheet and just map the ID in there. And then under the video output that is available in the latest node here at the top. So we just drag that in. And for the publish status, you can just change this to expression and paste in an expression like this, which is just good so that you can mark it as an error if in case the video did not generate correctly. So now if we execute this step, what you'll find is this third row will now update itself to show the video output in here. And there you go. That is now step three already done. Same as before, you can also convert this to a subworkflow if you want. If you need to use V3.1 in other automations and if you do that, your workflow will look more like this one.

Now the last thing you want to do is just set this workflow as active. And now if you open this form and click on production URL, you can now just grab this link and bookmark it or send it to your clients. And whenever you fill in and submit this form, it will now create this many images and videos for you automatically.

Now if you remember in our Google sheet, we have this publish status set to scheduled. And that is useful if you want to autopublish these images or videos into your social platforms. And so here in this template, what you can do is you just have these set of nodes that will autopublish that to Instagram in this case. So in practice, if we open this schedule trigger, this part of the workflow is now going to auto post every 8 hours. And what it will do is it just grab this first post and then post it to Instagram. So if we want to simulate how it will run, we just change this to run from the schedule trigger. And I'll click on execute here. And what it will do is it will get that very first post that has the publisher status set to scheduled. It will use this tool called potato in order to auto post to Instagram and then it will update the Google sheet to mark that as done so that the next time it runs it will grab this next post. And if we go to Instagram, you can see that this test post has indeed been posted. And if you need a detailed guide on how to set this up, you can just watch this previous lesson as well. But if you need this template so that you can get a shortcut that's just available in our community in the link below. We have several more lessons here around creating with AI through automation and several paid opportunities as well as members working together for creating with AI. So, if that's what you're looking for, then check out the link to see if that's for you. And if this gave you value and taught you something new, then consider subscribing to this platform as well, so that we can put out more educational content like this. That's it for this one. I'll see you guys next time. Thank you.