Add/Edit Segmentation Rule

Use the Add Segmentation Rule dialog box to create a new segmentation rule. A segmentation rule identifies where a sentence break occurs in source text. You can also define exceptions to the rule.

The dialog box has two views: Basic and Advanced. Rules are created in the Basic view by selecting rule components from lists. In the Advanced view, rules are created using regular expressions.

To display the Add Segmentation Rule dialog box, click Add in the Segmentation Rules dialog box.

 

Basic View:

 

Box

Description

Description

Add a description of the rule.

Advanced View - Click to switch between the Basic and Advanced views.

In the Advanced view, a rule created in the basic view, is displayed as regular expressions. When you switch back to the Basic view, the regular expressions are retained in that view.

 

NOTE

If you create a regular expression which cannot be parsed, it will not be displayed in the basic view.

Before break

Regular expression

Select the type of character that appears immediately before the end of a sentence. Alternatively, you can type the values in this box. You can enter plain text or a regular expression.

If you enter a regular expression you must select the Regular expression check box. If you do not select this box, SDL Trados Studio assumes that the value you have entered is plain text. For example, in plain text, the character '.' is a full stop (or period). However, if you select the regular expression check box it becomes 'any character'.

Break characters

Select the character that indicates the end of a sentence. The available characters are:

. Full stop (period)

! Exclamation mark

? Question mark

: Colon

; Semi-colon

Tab.

Check Abbreviations

This box is only available if you choose the full stop (period) as the break character.

Select this and text will not be segmented if the full stop follows an abbreviation. For this to work the abbreviation must appear in the Abbreviation list for the language, in the Language Resource Template.

Check Ordinal Followers

This box is only available if you choose the full stop (period) as the break character.

Select this and text will not be segmented if the full stop precedes an ordinal follower. For this to work the ordinal follower must appear in the Ordinal Followers list for the language, in the Language Resource Template.

Include closing punctuation

When you select this option, any punctuation appearing immediately after the selected break character is ignored and the text will break on the break character.

"Text inside quotation marks."

(Text inside brackets.)

In both of these examples the text would break on the full stop.

After break

Regular expression

Select the type of character that appears immediately after the break character when a sentence ends. Alternatively, you can type the value or values in this box. You can enter plain text or a regular expression. If you enter a regular expression you must select the Regular expression check box.

Exceptions

You can create exceptions to the rule you have created.

 

Advanced View:

 

Box

Description

Description

Add a description of the rule.

Basic View

Click this to display the Basic view.

Before break

Add a regular expression that identifies the pattern of text that occurs immediately before a segment break.

Rules created in the Basic view are converted to regular expressions in the Advanced view.

After break

Add a regular expression that identifies the pattern of text that occurs immediately after a segment break.

Exceptions

You can create exceptions to the rule you have just created. For example, if you have selected the exclamation mark as a terminator but you have a product name that ends with an exclamation mark, you can create an exception rule for the product name.

Click Add to create an exception rule. When you click Add the Add Rule Exception dialog box is displayed.

To remove an exception, select the rule and click Remove.

To edit an exception rule, select the rule and click Edit. When you click Edit the Edit Rule Exception dialog box is displayed.

 

 

Related Topics

How to Create a Segmentation Rule

How to Edit a Segmentation Rule

About Language Resource Templates