Skip to main content
Back to NLP Topics The ML engine maps user utterances to intents using example-based training. It supports supervised and unsupervised learning, with a range of network types for different use cases.

How the ML Engine Works

Intent detection pipeline:
  1. User utterance is preprocessed (tokenization, stop word removal, lemmatization, n-grams).
  2. The ML model classifies the utterance as a probable or definitive match against trained intents.
  3. Results are passed to Ranking and Resolver.
Entity extraction: After intent is identified, the engine extracts entity values from the utterance using NER (Named Entity Recognition) trained annotations. Supervised vs. unsupervised learning:
  • Unsupervised (auto-expand): The assistant learns from all successful interactions automatically.
  • Supervised (recommended): Developers monitor interaction logs, tune NLP settings for failures, and retrain.

Add ML Utterances

  1. Go to Natural Language > Training > Intents.
  2. Select an intent and add sample utterances.
  3. Click Train to update the model.
Utterance guidelines:
  • Utterances don’t need to be full sentences; phrases work too.
  • For distinct intents (for example, “Find Flight” vs. “Book Hotel”): 200-300 utterances each.
  • For similar intents (for example, “Change Seat” vs. “Change Flight”): 1000+ utterances each.
  • For Deep Neural Networks: larger datasets (data-hungry models) produce better results.

ML Network Types

Configure under Natural Language > NLU Config > Engine Tuning > ML.

Thresholds and Configuration

Go to Natural Language > NLU Config > Engine Tuning > Machine Learning.

Synonyms and Concepts for ML

Bot Synonyms: Go to Training > Bot Synonyms. Add synonyms for words in task and entity names. Synonyms are app-wide.
  • To add: click New Synonym, enter the keyword and its synonyms (press Enter after each).
  • Parallel editing is supported — multiple users can add/delete synonyms concurrently without data conflicts.
Entity Synonyms: Go to Training > Entities. Add synonyms per entity node. Concepts: Custom concept groups prefixed with ~. Define in Training > Concepts. Used in patterns and entity detection.

App Substitutions

Define domain-specific word replacements using the ~bot_substitutions concept:
Syntax: original_word|replacement (case-insensitive match, case-sensitive replacement).

App Word Aliases

Define alternate spellings or STT transcription corrections using Bot Synonyms with a + prefix. Example: +Alpha Romeo as an alias for Alfa Romeo — corrects speech-to-text transcription errors.
  • Aliases don’t change the original utterance.
  • They normalize values returned for Custom Concept entities.

Homophones

Handle words that sound the same but have different spellings. Define using a concept with | separator:
The engine considers all homophones during POS tagging and replaces the word if a homophone is a better grammatical fit. To define: Training > Concepts > New Concept — enter homophones separated by |.

Emoji Support

Import default emoji mappings into system concepts to handle emoji inputs:
  1. Go to Natural Language > Training > Intents > ⋯ > Import Emojis into Concepts.
  2. Emojis are added to system concepts (for example, ~emohappy, ~emohello).
  3. Review and remove unwanted emojis after import.

Patterns for Intents and Entities

See NLP Guidelines — Patterns for operators, syntax, and examples. Add intent pattern:
  1. Training > Intents → click Patterns / +Pattern for an intent.
  2. Enter patterns; press Enter between each.
Add entity pattern:
  1. Training > Entities → click the edit icon for an entity.
  2. Select the Patterns tab → enter patterns.
Add intent rules:
  1. Training > Intents → click Rules / +Rule for an intent.
  2. Enter Trait or context tag conditions using AND/OR operators.
Negative patterns:
  1. Enable at NLU Config > Ranking and Resolver Engine > Negative Patterns.
  2. Per intent: Training > Intents → select intent → Negative Patterns tab → add patterns.

NLU Config — FM Engine Tuning