...
How to using AI to automatically reply your Facebook Ads Comments
Introduction
A New Feature has been introduced, where the user comments on your dark post or ads, you can give a Like as well as reply to these User Comments under the comment keyword trigger.
Create FB Ad Post
Let’s create a Ad Post in Ads Manager.
...
Creating A Comment Keyword Trigger
Automations -> Comment Keywords -> Create New Comment Keyword
...
Once we click on New Comment Keyword, we can set up this function to trigger our FB Ad Post User Comments.
Let’s set up the required parameters:
...
We are selecting the FB Ads Post, for which we need to reply for the Ads Post User Comments and give likes.
Comment is Anything, (need to trigger for types of Comments)
Public - Not used
Status set to Active
Save Comment Payload (the Comment information along with the User ID & other details are stored in this JSON Variable for further data retrieving.
Private Reply in Messenger - (selecting the Subflow, which executes when the Comment Trigger happens.
Following Options are turned Active
Reply to new User
Reply to existing Subscriber
Like the User Comments
Reply to replies to Comments
Integration With Facebook Ads Manager
Integration -> Others -> Facebook Ads
...
Here you are linking your Ads Account Manager along with your FB account Page
Creating the Comment Trigger Flow
Lets go to the Subflow which we have name as Facebook ads comment trigger
Let me explain the concept in building this SubFlow:
Create a Condition block - to differentiate between the Keyword comment chatgpt and general questions asked about your Business / Services
Once the Comment is chapgpt, we are triggering an Action Block where we are calling the Facebook API for Ads Post Comment Reply Action Function.
In this Action Function, we are retrieving and Mapping the Post or Comment ID from the JSON Variable declared in the Comment Trigger Automation.
Next we are sending a PM Message to the User on their Messenger.Channel.
In case the Comment is not chatgpt, we are diverting to another Action Block with OpenAI Integration, where we are doing an Embedding Match with the User’s Comment to check the comment is related to our Business / services we offer and retrieving the related Openai_embed_text.
Incase the Embed Score is >0.8, we are triggering an Action Block by Integration of OpenAI Create Chat Completion Action.
Here we are creating a new variation of the Mapped output of Openai_embed_text, and sending the OpenAI variation reply to the FB Ad Post User’s Comment.
In case the Embed Score is <0.8, the FB Ad Post comment collected in the JSON Variable to be sent to the Action block with OpenAI - Create Chat Completion with a new System Message to OpenAI to answer or greet accordingly if the message is a greeting message.
...
Condition Block -> Json Variable - “fb_ads_comment match value with chatgpt”
Action Block -> Facebook API -> Ads Post Comment Reply Action
...
...
Message Block -> Sending a PM message on Messenger to the Ad Post User Comment
Action Block -> Integration with OpenAI - Embedding Match
...
Condition Block -> Check openai_embed_score is greater than or equal to 0.8
Action Block -> Integration with OpenAI - Create Chat Completion function
...
...
Action Block -> Integration with OpenAI - Create Chat Completion function
...
Note: As the page was big, split into two - up and below images includes one page.
...
Action Block -> Advanced Actions -> Facebook API
...
End Result as seen on the FB Ad Post Comments
...
In conclusion, managing comments for your ad posts with OpenAI and ChatGPT is a simple process. By following these steps, you can automate your comment responses and save time. Make sure to customize your replies and settings to your liking, and you'll be on your way to managing comments effectively.