Skip to main content

Developer Guide

This guide covers the technical implementation and configuration of the Conversation Clipper feature.

Architecture Overview

The Conversation Clipper relies on Deepdesk's NER (Named Entity Recognition) Service to detect and extract entities from conversation messages. For a comprehensive overview of the underlying architecture, see Architecture › NER Service.

Entity Detection

The NER Service analyzes conversation text and identifies entities using multiple detection methods:

  1. Flair NER model: ML-based detection for names, locations, and organizations
  2. Regular expressions: Pattern matching for structured data like phone numbers, emails, and dates
  3. URL matching: Automatic detection of URLs
  4. Simple string matching: Fixed entities matching items from a configured list

Supported Entity Types

The following entity labels are returned by the NER Service:

Flair NER (ML-based)

LabelDescription
PERName of person
LOCLocation (addresses, cities, countries)
ORGOrganisation
MISCMiscellaneous entities

Regular Expression Matching

LabelDescription
phoPhone number
emaEmail address
pcPostal code
strStreet address
ibanIBAN number
amtAmount (monetary values)
date_Date
xdigThree or more digits (e.g., order numbers, IDs)

Other Matching

LabelDescription
urlURL
phraseFixed entities from configured list (simple string matching)

Configuration

Enabling the Conversation Clipper

The Conversation Clipper is enabled at the account level through Admin configuration. When enabled, the widget displays the Clipper panel alongside other Agent Assist features.

Ignore List

Administrators can configure an ignore list to exclude specific terms from entity extraction. This prevents common words or phrases that match entity patterns from appearing in the Clipper.

Use cases for ignore lists:

  • Company names that shouldn't be extracted as person names
  • Internal terms that match entity patterns
  • Common greetings or sign-offs

Custom Entity Patterns

Custom entities are defined using regular expressions and configured through the NER Service. This allows capturing business-specific identifiers that standard NER models don't recognize.

Example custom patterns:

  • Order numbers: ORD-\d{8}
  • Tracking codes: TRK[A-Z0-9]{10}
  • Account IDs: ACC-[A-Z]{2}\d{6}

For details on configuring custom entities, see NER Service › Business Logic Layer.

Entity Type Selection

Configure which entity types appear in the Conversation Clipper. For example, you might choose to show:

  • Phone numbers and emails (always useful)
  • Custom order/tracking numbers (business-specific)
  • But not person names (if not relevant to workflows)

Data Flow

  1. Message ingestion: As messages arrive in the conversation, the Backend sends text to the NER Service.
  2. Entity detection: The NER Service runs ML models and regex patterns to identify entities.
  3. Filtering: Ignore lists and entity type configuration filter the results.
  4. Deduplication: Duplicate entities across messages are consolidated.
  5. Display: The filtered, deduplicated entity list is returned to the widget for display.

Frontend Integration

The Conversation Clipper is integrated into the Deepdesk Agent Widget. The widget:

  1. Requests entities from the Backend when a conversation is loaded
  2. Updates the entity list as new messages arrive
  3. Provides copy-to-clipboard functionality for each entity
  4. Displays entities in a compact, scannable format

API Response

The NER Service returns entity data in the following format:

[
{
"text": "John Smith",
"label": "PER"
},
{
"text": "+31612345678",
"label": "pho"
},
{
"text": "TRK6642953",
"label": "xdig"
},
{
"text": "john@example.com",
"label": "ema"
}
]
FieldDescription
textThe extracted entity value
labelThe entity type label (see Supported Entity Types above)

Performance Considerations

  • Real-time processing: Entities are extracted as messages arrive, with minimal latency impact on the agent experience.
  • Caching: Entity detection results are cached to avoid reprocessing the same text.
  • Model selection: The choice between Flair and spaCy affects both accuracy and latency. See NER Service › Model Options.