Skip to main content

Procedure formatting

Updated over 2 weeks ago

Procedures are reusable conversational subroutines that represent standardized logic blocks performing common actions across multiple scenarios. They are designed to avoid duplicating logic and ensure consistent handling of repeated behaviors, such as confirming names, collecting phone numbers, or verifying contact information.

Primary objective

Maintain conversation quality and consistency by:

  • Standardizing repeated conversational actions across scenarios.

  • Eliminating duplicate logic across the system.

  • Ensuring uniform handling of common behaviors (e.g., name confirmation, phone collection, contact verification).

  • Adapting based on information already available in Customer Attributes.

Procedures must remain generic and scenario-independent, functioning reliably regardless of which scenario invokes them.

Formatting rules

1. Title

Always use: ## **<Procedure Name>** procedure

Example: ## **Reconfirming or Gathering User Name** procedure

2. Body (Instructions)

Each procedure body must clearly define:

  • When the procedure should be invoked.

  • What conditions should be checked before execution.

  • What the AI Employee should say or do in each case.

  • Conditional logic with example phrasing to maintain conversation quality.

Attribute references and context injection

Procedures can reference Attributes using the format: [[attribute IDN]]

Example: [[project_attributes_restaurant_large_group_reservation_minimum_party_size]]

Context from the conversation or additional instructions can be injected into a procedure using the format [context/instruction].

Example:

โ€œAsk the user, your address is [user address], and you will be available on [availability date], is that correct?โ€ 

Example

Title

## **Reconfirming or Gathering User Name** procedure

Body

When you need to gather the User's name, check the <UserInformation> section, which may already contain this information.

### **If `user.full_name` contains information that resembles the name**: reconfirm, your name is [user.full_name], is that correct?

### **If `user.full_name` is either not set or null**: ask, may I have your name, please?

Note: It's okay if the user has provided only their first name.

Did this answer your question?