Key benefits
- Improved recognition of user inputs. Lexicon slots allow the agent to recognize variations of keyphrases (synonyms), enabling flexible user input handling without requiring exact matches.
- Consistency across conversations. Lexicon slots ensure uniform interpretation of terms across different flows, improving reliability.
- Easier maintenance. Centralized lexicon management makes it easy to update lexicon slots, reducing errors.
Limitations
- Maximum of 250 lexicon slots per lexicon.
- Maximum of 30 characters per lexicon slot name.
- Maximum of 50 slots and 50 synonyms per keyphrase in the lexicon editor.
- Maximum of 100K keyphrases per lexicon.
Key components of a lexicon

Work with lexicon slots
Lexicon slots are managed within lexicons, which you can create and configure in Cognigy to support conversational flows.- GUI
- API
- CLI
In the navigation menu, go to Advanced > Lexicons. Click Create lexicon to create a lexicon. Open a lexicon and click Create keyphrase to add keyphrases. You can also upload and download lexicons as CSV files.
Also, you can generate keyphrases by using generative AI.
Attach lexicons to use slots
Lexicon slots aren’t automatically recognized by the NLU model. To use them in a flow, you must manually attach a lexicon to the flow. Once the lexicon is attached, slots are populated when keyphrases or their synonyms are detected in user input.Upload and download lexicons
For easy slot management, you can upload and download lexicons in CSV format.CSV file requirements
CSV file requirements
To upload the file, make sure your CSV file is UTF-8 encoded.The CSV file should have the following format:Example:Fields beginning with the characters
@, +, -, or = aren’t allowed.Upload lexicons
Upload lexicons
To upload lexicons, follow these steps:
in the upper-right corner.
- Open the lexicon and click
next to the Search keyphrase field. - In the Upload Lexicon CSV file dialog, select one of the following options:
- Skip importing duplicate keyphrases. Skips importing any synonyms from the CSV file that already exist in the current lexicon. If there are duplicate synonyms in the CSV file, they’re ignored during the import process. Only new and unique synonyms are imported.
- Overwrite the current keyphrases. Replaces all the current keyphrases in the lexicon with the keyphrases from the CSV file. If there are any existing keyphrases in the lexicon, they’re completely overwritten, and only the keyphrases from the CSV file are retained.
- Merge tags and synonyms from the current and imported keyphrases. Merges the synonyms of keyphrases from both the current lexicon and the CSV file. Only unique synonyms are merged. If a synonym exists in both the current lexicon and the CSV file, it isn’t merged.
- Click Upload CSV file and select the file.
Download lexicons
Download lexicons
To download lexicons, follow these steps:
- Open the lexicon and click
next to the Search keyphrase field. Wait for the CSV file to be generated. To track this process, you can view the Export Lexicon task by clicking in the upper-right corner. - When the task is completed, click
again. The icon is highlighted and its tooltip reads Download lexicon.