Configuring a task involves defining a procedure to follow using a prompt, optionally utilizing tools to execute the procedure, and potentially extracting data. Depending on the procedure and the mission to accomplish, you will choose a specific model.

You can choose a different model than the default model defined in the general terms of use.

Task Configuration

The Task Prompt

This section involves describing to the agent what you expect from it and the steps to follow for the conversation segment related to the task. We recommend limiting instructions here to those specific to the task. Remember, you have likely defined a base prompt in the general settings.

To ensure reliable interactions with your agent, we recommend following the format below:

  1. Objective:

    Define the overall goal that the agent should accomplish in this specific task. This is the broader outcome the agent is working towards, such as scheduling an appointment, answering a query, or confirming details. 2 lines maximum.

  2. Instructions:

    Provide a step-by-step breakdown of the actions the agent must take to achieve the objective. This includes things to say and actions to perform. Ensure the instructions are clear and precise to guide the agent effectively through the task.

  3. Response Instructions:

    Establish a list of Dos and Don’ts for your agent in this section. This is the most empirical part of the prompt. By testing your agent, you might identify undesired behaviors.

Example: A town hall agent helping a client book a room.

’#### Objective: In this phase of the conversation, your goal is to assist the caller in booking a room at the town hall.

’#### Instructions:

  1. Ask the caller from which date they are looking to make a reservation.
  2. Call the function get_rooms_availabilities to check room availability.
  3. Present the available options naturally to the caller and help them choose a suitable time slot.

’#### Response Instructions:

  1. Use the get_rooms_availabilities function before proposing any options.
  2. Confirm the date only after ensuring the caller’s availability.

Variables to Extract

There is a high likelihood that you will want to automatically extract information/data from the conversation. Variables allow you to plan for this extraction.

Example: You create an agent for a medical office tasked with calling patients the next day who have not confirmed their appointments. Without reading all call logs, you want to have a presence list.

  1. Create a Boolean Variable: presence_confirmed?. To learn how to create a variable, check the Variables section.
  2. In the Task, under ‘Variables to extract during the conversation’, select presence_confirmed. To do this, press the button circled in red on the screen below and select the variable to be extracted.
  3. Enter a Clear Extraction Instruction: For example, “Will the patient be present for their appointment?”. You can enter the instructions on the text bloc highlighted in blue in the screen below.
  4. At the End of the Task, an extraction agent will search for the information in the conversation and store Yes or No in the presence_confirmed variable.

The data extracted in this way can be utilized by the agent in the subsequent procedure. Parameter extraction for function calls is unrelated.

Adding a Task

Calling the Next Task

After configuring the current task, you can set up the agent to proceed to the next task in the workflow. This allows for seamless transitions between different procedures and ensures that the agent can handle complex sequences of actions efficiently.

Steps to Call the Next Task:

  1. Define the Next Task:

Ensure that the next task is already created and properly configured in your task list. To create a new task, click on the “Add task” button highlighted in red on the screen below. Once the task is created, connect it to other tasks as follows:

Use the circles at the top and bottom of the task block (see screenshot).

  • The top circle (highlighted in green) represents an incoming task (another task connects to this one).
  • The bottom circle (highlighted in blue) represents an outgoing task (this task leads to another one).
  1. Configure the Transition:

    In the current task settings, locate the section for task transitions or workflow.

  2. Set Transition Conditions

    If the transition to the next task depends on certain conditions provide the condition in the transition section.

  3. Mention the Next Task in the Task Prompt

    You should mention the next task in the task prompt. This will help the agent to know what to do next.

    Example:

    If the client wants to book a room, proceed to book_room.

  4. Test the Workflow:

    After setting up the transition, test the workflow to ensure that the agent correctly moves to the next task under the defined conditions. To test your agent, read the Test your agent section.