Follow Up Agent

Written By William Bowen

Last updated 4 months ago


Introduction

This article provides a template to build your Follow Up Clerk. This is an AI that will follow up with leads that don’t reply, increasing conversions.

Inputs

  • Follow up schedule.

  • Company.

  • Company overview.

Outputs

  • Three follow ups with leads on a schedule determined by you.

  • Contextually-relevant follow ups. AI reads the conversation history and generates a follow up message based off that.


Follow Up Schedule

Decide on your follow up schedule.

If the lead doesn’t respond, when do you want the follow ups to be sent?

Something like: 1hr, 1 day, 7 days.

This is the follow up schedule.

If the lead responds after any one of the follow ups, the schedule resets to the beginning (back to a 1hr follow up when the lead doesn’t respond).

After 7 days, there will be no more follow ups.

You decide what your schedule is and write it out.

The units that work are: minute, minutes, hour, hours, day, days.


Company Knowledge

Write the following out for your company:

  • Company name:

  • Company overview (1-4 sentences):

This will be used in the prompts for each AI agent so they have context on who they are working for.

This improves the AI’s performance as it has more understanding about your company.

Without this, the AI doesn’t know if its a support agent for a B2B logistics company or a B2C clothing company (who will get very different support questions).

Where possible, don’t let the AI guess! Just as with human employees, you wouldn’t make them guess what company hey are working for, you would tell them and bring them up to speed. Do the same for your AI employees!

Example:

For Clerk Chat, we write:

Company name:

Clerk Chat

Company overview (1-4 sentences):

Clerk Chat makes every business conversational through AI. Clerk Chat enables businesses to provide 24/7 conversational messaging across multiple channels, using AI to perform sales, marketing and support roles in your business. By integrating with tools like Salesforce, it delivers personalized, concierge-level service at a fraction of the cost of traditional support systems. Clerk Chat enables any business to become conversational with their clients through AI, over SMS.


High-level logic in Figma

Here is an outline of the high-level logic of the FAQ Clerk laid out in a logic diagram in Figma.

This Clerk requires only two nodes that aren’t connected.

The ‘Schedule Follow Up’ node sets the follow up schedule. Every time a message is sent to the number, this node runs and resets the follow up schedule (e.g. send a follow up in 1 hour if the lead doesn’t send another message).

The ‘Follow up agent’ sends a follow up message once the scheduled follow up time arrives.


Detailed logic in Figma

Here is the same diagram with added detail. This diagram includes the properties that will be set in the Clerk Chat Agents editor.

When building agents, it is good practice to outline these first on Figma to ensure the logic makes sense.

❓ For a breakdown of these properties check out this article What are Agents?


Build in Clerk Chat

Follow these instructions (with screenshots) to implement the Follow Up Clerk:


The template

Example
{ "$schema": "https://web-api.clerk.chat/pipeline-schema", "name": "Follow Up Agent", "nodes": [ { "type": "tool_provider", "name": "ScheduleFollowUp", "triggeredBy": [ "userMessage", "scheduledRun" ], "responseType": "tool_call_result", "nodeConfig": { "type": "conversation_tools", "config": {}, "enabledTools": [ "schedule_next_run" ], "tools": { "schedule_next_run": { "description": "Schedule the pipeline to run at some point in the future", "paramValues": { "delay": { "type": "fixed", "value": [ "first_follow_up", "second_follow_up", "third_follow_up" ] } } } } } }, { "type": "ai_bot", "name": "follow_up_agent", "triggeredBy": [ "scheduledRun" ], "responseType": "user_message", "nodeConfig": { "modelProvider": "openai", "modelVersion": null, "maxTokens": null, "temperature": null, "variables": {}, "prompt": "# Role: \n\nYou are an experienced Sales representative at [company]. \n\n—\n\n# Goal: \n\nSend a follow-up message to the lead. \n\n—\n\n# Context: \n\nYou are part of the top-of-funnel sales team at . You are speaking with a client over SMS. \n\nYou are the first and final bot in this workflow. Your message is sent back to the lead. \n\nPrimary goal of complete workflow: \nSend a contextually-relevant follow up to a lead to re-engage them. \n\nYou have been called because the lead has not responded to your message so we want to follow-up with the lead. \n\n—\n\n# [company] Overview:\n\n[company overview]\n\n—\n\n# Personality: \n\nHuman-Like: Conversations feel conversational and natural, avoiding robotic language. DO NOT keep repeating the lead's name, this is unnatural. Read the conversation history, if you have already said the lead's name once, do not say it again for the rest of the conversation. \nFriendly and Professional: Casual yet polite tone. \nDirect: You do not state the obvious. You are to the point, while being friendly. \nEngaging and Positive: Use emojis sparingly (only once every 5 messages) to add warmth. Read the conversation history and see if you have sent an emoji in your last 5 messages. If you have, do not send an emoji. \nYou are confident. Do not always ask the lead: \"let me know how I can assist you!\" This is too subservient.\n\n—\n\n# Instructions: \n\nRead the conversation history. \nGenerate an appropriate follow up message for the contact, based on something that was said in the conversation history. \nEnsure the message is human-like and authentic. We want to lead to think they are speaking to a human.", "promptSections": [], "sectionTemplates": {}, "responseSchema": { "type": "object", "required": [], "properties": {} }, "opts": { "sendStructuredConvo": true } } } ], "edges": [] }

Conclusion

You have successfully built a Follow Up Clerk!