Teneo Developers
Table of Contents
Was this page helpful?

Share to

Language objects

Language objects are building blocks for language conditions. They capture words, synonyms, or various ways of expressing the same (partial) intent. They make it possible to efficiently write and re-use conditions.

A closer look at language objects reveals that while they are used in language conditions, they also contain language conditions themselves. Moreover, language objects often use other language objects in their conditions:


All language objects together form a hierarchical structure, where word-level language objects are at the bottom, and various kinds of lists, synonyms, and phrases are at the top.
You can use both the language objects of the pre-built lexical resources that you have linked to your solution, and any language object that you and your team created in your solution.

The main components of a language object are:

  • the name
  • the language condition

We will have a closer look at both of these components in the following.

Names and types of language objects

The name of a language object is always written in upper case. When you use a language object in a condition, you add a % sign before its name.

The language objects that come with the pre-built language resources follow a naming convention. This makes it possible to get a feel for what they cover already from their names. For instance, a name that ends in .SYN covers a set of synonyms, and a name that ends in .LIST captures a list of some kind, e.g. a list of different colors or car brands.

When Teneo generates language conditions from examples (with the 'NLU Generator' button) it only considers language objects that follow the naming convention (and are of certain types, as indicated in the table below). Thus you should make sure to name your language objects properly if you'd like them to be part of the automatically generated conditions.

If you want to use DOG.NN.SYN as a condition you would need to write %DOG.NN.SYN

The most important language object types are:

SuffixTypeExample NameExample ConditionUsed by 'NLU Generation'
LEXLexical entry: is the smallest building block from which more complex language objects are built. Covers different inflections of a word, but also spelling and regional variations.DOG.NN.LEXdog / dog's / dogs / dogs'yes
SYNSynonyms: groups language objects with similar meaning.DOG.NN.SYN%DOG.NN.LEX / %HOUND.NN.LEX / %MUTT.NN.LEX / %POOCH.NN.LEX / (...)yes
ENTITYEntities are collections of one or more words that all have some characteristic in common.COFFEES_SERVED.ENTITIYClick here for detailsyes
PHRPhrases: groups various ways of expressing the same phrase or partial intent.IS_BROKEN.PHR((%BE.VB?PRESENT.LEX / %SEEM.VB.SYN)>> %BROKEN.ADJV.SYN ) / (...)yes
LISTList: lists related concepts, such as colors or country names. A list often contains other lists.HERBS.LIST%BASIL.NN.LEX/ %CILANTRO.NN.LEX/ %CORIANDER.NN.LEX / (...)no

Language objects may also contain an infix signalling their part of speech. A more extensive table of the language object types, and part of speech tags used, can be found here.

Language Condition

The language condition in a language object describes patterns that need to be present in a user input for the condition to be fulfilled. They are expressed in Teneo's condition syntax.