๐Ÿ“’Conversation scripts

FIRST LINE provides powerful and flexible chatbot flow settings, allowing you to createa personalized conversational experience. In addition, it can integrate AI technology from large language models to provide smarter, more natural customer interactions.

๐Ÿ‘‰ https://www.firstline.cc/chatbot

How do I use it?

You can edit different scripts for different chat scenarios. For example, when a customer sends a message, show options and guide the customer to find the answer... etc., to help businesses handle customer service.

Conversation scripts help you handle dialogues in various situations. By using the three elements โ€œEvent,โ€ โ€œCondition,โ€ and โ€œAction,โ€ you can handle more complex scenarios, for example:

  • Use menus to guide customers through processes,reply with more precise answers.

  • According to different processes, assign customerspriority to different customer service agents.

  • send coupons or promotional information, etc.

Use scripts to help handle common customer service questions

Start designing your custom script

To create a conversation script and make it work, just follow these simple steps:

  1. Create a script๏ผšFind the โ€œConversation Scriptโ€ feature under the โ€œChatbotโ€ category in โ€œApps.โ€ Click the โ€œNewโ€ button or the โ€œTemplateโ€ button in the interface to get started.

  2. Design the script๏ผšPlan your script based on your business needs, such as setting up keyword auto-replies, promoting campaigns, etc. During editing, you can use the simulation feature for real-time testing. If you need to leave midway, you can save a draft at any time.

  3. Publish the script๏ผšAfter finishing the script design, click the โ€œPublishโ€ button on the edit screen to officially publish your script from draft status.

  4. Associate the script๏ผšTo make the script take effect in real scenarios, you need to associate it with the corresponding conversation channels, such as LINE or Facebook. Find the โ€œChannel Associationโ€ tab in the script list to complete the association settings.

  5. All done๏ผšAt this point, your custom conversation script is ready and can start automatically responding to customer messages on the specified channels.

โœ๏ธ Interface operations

In the single-script interface, you will see several key function buttons, which are:

Function
Description

Name

Allows setting or modifying the scriptโ€™s name and description, helping keep scripts organized.

Mode switch

Allows you to switch between the scriptโ€™s edit mode and view mode. 1. In view mode, the interface hides some operation buttons. 2. In view mode, you see the published script information, while in edit mode you see the saved script draft information.

Template, Import

Use process templates provided by the FIRST LINE team, or import script JSON from other sources to save design time.

Export

Allows exporting the current script as JSON format for archival or use in other environments.

Simulate bot

Perform real-time testing of draft flows during the editing phase to see how the script actually runs and adjust based on test results.

๐Ÿ“ Notes

  1. For scripts that are in progress๏ผšWhen a script is updated and published, if customers are currently in that script flow, the system will proactively return them to the starting point to restart the flow.

  2. Main script design rules๏ผšThe start of the main script must place at least one โ€œEventโ€ node to define the conditions for a customer entering the script. This design clarifies the trigger point for starting interactions and ensures customers can start the script flow according to preset conditions.

  3. Limit on number of nodes traversed๏ผšTo avoid poor customer experiences caused by overly complex designs, the number of nodes a customer passes through from initiating a conversation to the next utterance (including โ€œCondition,โ€ โ€œAction,โ€ etc.) cannot exceed 200. If this limit is exceeded, the system will automatically guide the customer back to the starting point to prevent potential faulty designs from adversely affecting the customer.

What are the script node types?

Conversation script nodes are categorized into several types depending on their purpose:

Type
Description

Entry

The entry is the starting point where a user enters the flow; it can connect to other nodes afterward but cannot be deleted.

Event

Wait for a specified event to occur; it can be connected after an โ€œActionโ€ to continue the flow. For example, after sending the message โ€œPlease enter the service you want,โ€ determine the next step based on the userโ€™s content.

Conditions

Can evaluate user data, such as current time or the message sent. For example, determine to send promotional messages during a specific time period.

Action

Can perform flow operations such as sending messages or options. It can be connected after an โ€œEventโ€ or โ€œConditionโ€ and will operate only when specific situations are met.

Exit

Represents the end of the entire flow and exit. After leaving, other final operations can also be executed, such as assigning to a specialist or continuing with another script.

Each node type contains various corresponding functions and settings, which will be explained below.

๐ŸšฉEntry

In script design,the โ€œEntryโ€ acts as the critical starting point for users to enter the flow, so the โ€œEntryโ€ is a fixed node and cannot be deleted.

The rule for the first script node connected to the entry depends on the nature of the script:

  • Formain scripts, the first node must be the โ€œWhen customer message matchesโ€ event under โ€œEventโ€; this design ensures the flow can be triggered and executed under specific conditions.

  • ForSub-scripts(i.e., scripts called by another script within a script flow) do not have this restriction. A sub-script does not need to start with an โ€œEventโ€ node; regardless of its starting node, the system will automatically execute subsequent steps when invoked.


๐Ÿ‘€ Events

Events will โ€œwaitโ€ for specified occurrences before continuing to execute connected steps, for example if you add an event โ€œWhen customer message matches,โ€ it will wait for the customer to send a message before continuing with the subsequent flow. The current related functions are as follows.

Event types
Description

Customer sends a message

The customerโ€™s message matches one of the set keywords.

Customer browses a page

When the customer browses a specific webpage.

Customer sends an email

When a customer sends an email and it meets the set conditions.


๐Ÿ”€ Conditions

Decide whether the flow should continue or proceed to another flow based on data.

Condition types
Description
Possible applications

Weekday matches

If the current date matches the specified weekday.

Send promotional messages, specific event reminders, etc.

Memory variable comparison

Compare whether the data stored in the eventโ€™s memory is set or equals a specified value.

Customized responses, flow branching, data validation, etc.

When customer message matches

The customerโ€™s message matches one of the set keywords.

Trigger specific dialogue flows, label classification, reply messages, etc.

Agent is online

Whether an agent is currently online using the system.

Route to human service, show wait time, auto-reply, etc.

Whether customer data exists

Whether the incoming customer has linked customer information.

Customer identity verification, data update prompts, personalized services, etc.

Message type

Whether the message sent by the customer is text or a file.

File handling flows, keyword responses, etc.

Web URL

Whether the incoming customerโ€™s URL matches a specific URL.

Website navigation assistance, personalized ad display, event page direction, etc.


โšก Actions

Action types
Description
Application examples

Send message

Send a message to the customer, text or image.

Customer service notifications, event promotion, product information sharing, etc.

Send options

Send up to three options to the customer; display varies by channel. Three items are the current common intersection limit across social media platforms.

Service menu, quick response choices, etc.

Send carousel message

Send horizontally scrollable carousel cards.

Product showcase, event introduction, user guides, etc.

Send quick replies

Send non-repeatable clickable options to guide the customer.

FAQ answers, appointment selection, service guidance, etc.

Webhook script

Call a webhook script for API integration.

Data synchronization, third-party service integration, automated task handling, etc.

Search knowledge base articles

Search the knowledge base for the article closest to the keyword using conversation variables.

FAQ answers, self-service solutions, knowledge sharing, etc.


๐Ÿ”š Exit

Exit types
Description
Application examples

End flow

End the current conversation flow.

Complete inquiries, end interactions, automatically close after resolving issues, etc.

Other scripts

End and immediately call another script.

Transition from one service process to another related process, such as from product inquiry to order placement.

Assign to agent

Route the user conversation into the system and assign it to a specialist.

When automated service cannot resolve the customerโ€™s issue and human intervention is needed


Frequently Asked Questions

Script design completed โ€” how to associate with channels?

Once you have completed the script design, you can associate your carefully designed script with the conversation channels you choose, such as LINE or Facebook, via the โ€œChannel Associationโ€ tab in the script list interface.

Then, when customers send messages through these channels or other specified events are triggered, the system will start executing according to the flow you designed.

How to test the script flow?

After completing the script design, testing to ensure the flow works properly and meets expectations is a very important step. Whether you are in the design phase or ready to publish the script, there are appropriate testing methods:

  1. Draft-stage testing๏ผšIn edit mode, use the โ€œSimulate botโ€ feature in the script interface for real-time testing. This allows you to preview and evaluate the draft flowโ€™s effect before official publishing, and promptly discover and adjust potential issues.

  2. Post-publish testing๏ผšIf the script is already published, you can test through the official channel. If you donโ€™t want to affect channels currently in normal use, you can create a dedicated โ€œLive Chatโ€ channel for testing. After creating the channel, click the live view button in the live chat interface to start evaluating the scriptโ€™s performance in a real application environment.

Are templates provided for reference?

To help you get started quickly and spark creative ideas, we provide a variety of process templates. These templates cover basic applications and demonstrate how to effectively use our script design features to optimize customer service and interaction experiences.You can find the template button in the script list or at the top-right of a single scriptโ€™s edit interface.

Open the template window from the list
Open the template window in the edit interface

How to edit the script name, description, or disable it?

To make minor changes to the conversation script, such as changing its name or adding notes, you can operate directly in the single-script edit interface.

  1. Enter the interface of the script you want to modify.

  2. At the top of the single-script interface, find the conversation script title. Click the title to edit it. Note that changing the script name takes effect immediately, but this action does not trigger publishing the script or saving the current edits.

How to use conditions or events to make decisions

Throughout the flow, when you need to make branching decisions, you can use the โ€œEventโ€ and โ€œConditionโ€ blocks in the block to make determinations. These two types of blocks will evaluatethe same-type blocks at the same level.

The flow will evaluate the same-level blocks of the same type

As shown above, the flow evaluates โ€œEventโ€ blocks at the same level; if the evaluation for a condition is false, it will automatically proceed to the next โ€œEventโ€ block based on the evaluation until the condition is true or it connects to a different-type block.

Advanced usage

Use sub-scripts to subdivide flows

When your single script becomes larger and harder to maintain and manage, it is recommended to split the script into other different scripts, for example by usage scenario or different options.

Then, use the โ€œExitโ€ blockโ€™s function to call other sub-scripts to continue the flow, making it easy to simplify complexity.

Of course, if different scripts share a small portion of the same flow, it is recommended to create that common step as another script for reuse.

Use โ€œmessage variablesโ€ to determine subsequent flows

In some script block settings, you can store messages into variables of the current script to facilitate smoother subsequent flows. For example, when you ask the customer for a nickname and the customer responds, store the customerโ€™s nickname into the variable nickname, then continue the flow using โ€œSend message,โ€ setting {{ nickname }} Mr./Ms., hello! Greet the customer and confirm.

Send personalized messages using template syntax

You can process the transmitted message content using memory variables and template syntax to easily send the messages you need.

If using template syntax, you can simply use it like this.

For more complex applications, please refer to the following articles.

๐Ÿ‘จโ€๐Ÿ’ปTemplate syntax

Last updated