Setting Up Recognition Languages

One of the main recognition parameters is the language to be used for recognition. The recognition languages can be specified for the entire document and for individual data fields.

Recognition language for the entire document

The recognition language for the entire document is specified in the Document Definition. To specify the recognition language for a document, use the IDocumentDefinition::DefaultLanguage property.

The recognition language which is used for the entire document is usually one of the predefined languages, or a group of such languages. Predefined languages are the languages supported in ABBYY FlexiCapture SDK by default. The collection of available predefined languages represented by the PredefinedLanguages object is accessible via the PredefinedLanguages property of the Engine object. It is a collection of Language objects.

To change the language used for recognition of a document, do the following:

  1. Find the necessary predefined language in the collection of available languages. Use the FindLanguage method of the PredefinedLanguages subobject of the Engine object. The predefined languages are identified by their internal names. For the list of the internal names of the predefined languages see Predefined Languages in ABBYY FlexiCapture SDK.
  2. Assign the received Language object to the IDocumentDefinition::DefaultLanguage property.

C++ (COM) code

Languages may be simple (e.g. English, Russian), or compound (composed of several simple languages). See the Type property of the Language object. The Language object exposes methods which cast it to a type-specific interface and thereby provide access to the extended attributes of a language of specific type.

Changing the recognition language for individual fields

The recognition language can be changed for an individual field by setting the recognition parameters of this field. The IFieldDefinition::RecognitionParams property provides access to the parameters of field recognition. The recognition language can be set for text fields only (IFieldDefinition::Type = FT_TextField).

To tune the recognition parameters of a text field, receive the RecognitionParams object as a TextRecognitionParams object. (Use the AsTextParams method of the RecognitionParams object.)

To use a group of languages for recognition...

To use regular expressions for recognition...

To use user dictionaries for recognition...

To use a special recognition language for a data type...

See also



15.08.2023 13:19:30

Usage of Cookies. In order to optimize the website functionality and improve your online experience ABBYY uses cookies. You agree to the usage of cookies when you continue using this site. Further details can be found in our Privacy Notice.