# Overview

Smart Fields are dynamic, reusable data variables in Assembled AI that allow you to collect, store, and use customer information throughout your automated workflows. They serve as a bridge between customer interactions and your business systems, enabling you to capture context-specific data and automatically map it to your platform fields (like Zendesk custom fields).

# What are Smart Fields?

Smart Fields are structured data containers that can:

- Collect information from customers during conversations
- Store data enriched from external APIs
- Map to custom fields in your ticketing system
- Be reused across multiple workflows and automation rules
- Maintain data consistency across different channels (chat, email, phone)

Think of Smart Fields as dynamic variables that travel with a customer case, accumulating valuable context and information as the conversation progresses.

# Types of Smart Fields

Assembled AI supports four types of Smart Fields:

## 1. Text Fields (`string`)

- Store textual information like names, descriptions, or free-form responses
- **Example**: Customer name, order description, issue summary

## 2. Number Fields (`number`)

- Store numeric values like quantities, amounts, or IDs
- **Example**: Order number, account balance, ticket priority

## 3. True/False Fields (`boolean`)

- Store yes/no or true/false values
- **Example**: VIP customer status, subscription active, issue resolved

## 4. Dropdown Fields (`enum`)

- Store predefined options from a list
- Support platform-specific mappings (e.g., different values for Zendesk vs Salesforce)
- **Example**: Issue category, product type, urgency level

# How Smart Fields Work

## 1. Data Collection

Smart Fields can be populated through multiple methods:

**AI-Powered Collection**: During conversations, Assembled AI can automatically extract information and populate Smart Fields based on customer responses.

**Workflow Steps**: Use "Gather Data" steps in your workflows to explicitly ask customers for specific information.

**Case Data Enrichment**: Automatically populate Smart Fields through API calls to external systems using collected customer data.

**Manual Entry**: Agents can manually update Smart Field values during customer interactions.

## 2. Data Mapping

Smart Fields can be mapped to:

- **Platform Custom Fields**: Automatically sync values to Zendesk, Salesforce, or other platform custom fields
- **Handoff Forms**: Include Smart Field values in escalation forms when transferring to human agents
- **API Calls**: Use Smart Field values as parameters in custom API integrations

## 3. Data Usage

Once populated, Smart Fields can be referenced in:

- Workflow conditions and branching logic
- Response templates and automation rules
- Escalation and handoff processes
- Reporting and analytics

# Setting Up Smart Fields

## Creating a Smart Field

1. Navigate to **Settings > Info Fields > Smart Fields**
2. Click **Create Field**
3. Configure the field properties:
   - **Name**: A descriptive name for the field (e.g., "Customer Order ID")
   - **Description**: Detailed description of what the field contains
   - **Type**: Choose from Text, Number, True/False, or Dropdown
   - **Options**: For dropdown fields, define the available values and descriptions

## Dropdown Field Configuration

For dropdown fields, you can:

- Define multiple options with descriptions
- Set platform-specific mappings (e.g., map "High Priority" to "urgent" in Zendesk and "1" in Salesforce)
- Create conditional logic based on selected values

## Platform Integration

To automatically sync Smart Field values to your platform check out our [Setting up Integration Fields](https://support.assembled.com/hc/en-us/articles/41891780735629-Setting-Up-Integration-Fields) article.

# Using Smart Fields in Workflows

## Data Collection Workflows

Use Smart Fields in "Gather Data", or Guide workflow steps:

```auto
Step: Gather Customer Information
- Select Smart Fields: Order ID, Issue Category, Customer Tier
- Instructions: "Ask the customer for their order number and describe their issue"
```

## Conditional Logic

Create workflow branches based on Smart Field values:

```auto
Condition: If Customer Tier equals "VIP"
- Route to: Priority Support Queue
- Else: Standard Support Process
```

## Case Data Enrichment

Automatically populate Smart Fields via API calls:

1. Configure a Custom API endpoint
2. Map API response fields to Smart Fields
3. Enable case data enrichment in your settings
4. Smart Fields are automatically populated when the API is called

# Smart Fields in Chat Handoffs

When escalating chat conversations to human agents, Smart Fields can:

- **Auto-populate handoff forms**: Include collected customer information in the escalation form
- **Create context for agents**: Provide agents with relevant customer data before they take over
- **Map to platform fields**: Automatically create or update tickets with the collected information

## Configuring Handoff Fields

1. Go to **Chat Settings > Handoff**
2. In the **Smart Fields** section, select which Smart Fields to include
3. Configure form labels and whether fields are required
4. Smart Field values will automatically populate the handoff form

# Best Practices

## Naming Conventions

- Use clear, descriptive names: "Customer Account ID" instead of "ID"
- Include the data type in complex scenarios: "Priority Level (1-5)"
- Be consistent across similar fields: "Order Status", "Payment Status", "Account Status"

## Data Structure

- Create reusable fields that can be used across multiple workflows
- Use dropdown fields for standardized categories to ensure data consistency
- Consider how fields will map to your platform's custom fields

## Workflow Design

- Collect essential information early in the conversation
- Use Smart Fields to avoid asking customers for the same information multiple times
- Implement validation rules to ensure data quality

## Integration Planning

- Map Smart Fields to existing platform custom fields where possible
- Design your Smart Field structure to align with your reporting needs
- Consider how Smart Fields will be used in downstream systems

# Advanced Use Cases

## Customer Segmentation

- Create Smart Fields for customer attributes (tier, region, product)
- Use these fields to route conversations to specialized teams
- Automatically apply appropriate service levels based on customer segments

## Order Management

- Collect order IDs, product information, and issue details
- Automatically look up order information via API calls
- Populate relevant order data for agent context

## Technical Support

- Gather device information, error codes, and troubleshooting steps taken
- Use Smart Fields to track resolution progress
- Automatically categorize issues for reporting

## Multi-Platform Consistency

- Use platform-specific mappings for dropdown fields
- Ensure consistent data across Zendesk, Salesforce, and other systems
- Maintain unified customer profiles regardless of interaction channel

# Troubleshooting

## Common Issues

**Smart Field not populating**:

- Verify API mapping is correctly configured
- Check that the workflow step collecting the data is properly set up
- Ensure the customer provided the requested information

**Platform sync not working**:

- Confirm the platform custom field exists and is properly mapped
- Check that the Smart Field type matches the platform field type
- Verify integration permissions and API connectivity

**Workflow conditions not triggering**:

- Ensure Smart Field values match the condition criteria exactly
- Check for case sensitivity in text comparisons
- Verify that the Smart Field is populated before the condition is evaluated

## Data Validation

- Implement validation rules in your workflows to ensure data quality
- Use dropdown fields instead of free-text when possible
- Provide clear instructions to customers about expected data formats

# Conclusion

Smart Fields are powerful tools for creating intelligent, context-aware customer service automation. By thoughtfully designing your Smart Field structure and implementing them strategically in your workflows, you can:

- Reduce customer effort by avoiding repetitive questions
- Provide agents with rich context for faster resolution
- Maintain consistent data across all your business systems
- Create sophisticated automation rules based on customer attributes
- Generate meaningful insights from structured conversation data

Start with a few essential Smart Fields and gradually expand your implementation as you identify additional use cases and automation opportunities.
