How to Extract/Add Custom Entities
About
The Custom Entity Extraction (CEE) component extracts entities from any input text based on a list of entity names.
- Adding the Custom Entity Extraction (CEE) component and outside databases that contain predefined values speeds up the tagging process.
- This component automatically extracts entities that are defined by a list of entity names.
How to Configure Custom Entity Extraction
Use the following instructions to configure the Custom Entity Extraction component.
- Add the Component.
- Existing Components: Click the named link for this component to see the Configuration section:
- Entity Name:
- Select the Predefined Entity Radio button and click the drop-down arrow to select the name of the entity.
- SQL: Select the External Database Radio button
- Connection String: Provider a database connection string
- Select Query: Provide a select statement to define entity Values
- Example: SELECT EntityName from Entities
- Input properties:
- Specify the input properties, such as body, Heading, etc., that are used to send the web service request.
- Property names must be separated by commas (
,
). - If an external web service expects a property with a different name, the following syntax can be used:
originalName->modifiedName
- Output property:
- Specify the output properties that are expected in the web service response.
- The property names must be separated by a comma (
,
).
- Append Data to Output Property:
- Click to enable.
- Include Counts:
- Check this option to have returned entities include a count.
Examples:- UnChecked: Gold, Silver, Diamond
- Checked: 10;Gold, 4;Silver, 1;Diamond
- Check this option to have returned entities include a count.
- De-Duplicate Entities: Click to remove any duplicate entities.
- Example: When using Entity Values "New York", "York", "Boston"
- If the search text contains "York":
- Unchecked: York, New York
- Checked: New York
- If the search text contains "York":
- Example: When using Entity Values "New York", "York", "Boston"
- Apply: Click to apply your changes and see a confirmation message.
- Validate: Click to validate your changes and see a confirmation message.
- Input Properties: Based on configuration.
- Output Properties: Based on configuration.
- Select these entities using the drop-down list.
- For more information, see Using predefined entities.
How to Use Predefined Entities to Enrich Content
You can use predefined entities for content enrichment and to import entities on the Custom Entities page:
- Go to the Custom Entities page:
- Browse for a
CSV
file containing the entities definition.
The name of the CSV file is used as the entity name. - Click Import Entities
- Add the Component.
- <Your Component>>Existing Components:
- Name: Click on the name of the feature that you are configuring with custom entities, such as
CE:
- Entity Name: Select an imported entity.
- Input Properties: Specify as a comma (,) separated list.
- Output Property: Specify.
- Append Data to Output Property: Append the extracted entities to the output property or overwrite the output property with the extracted entities.
- De-Duplicate Entities: Remove all duplicate entities from the output. If an entity is part of another entity such as
York
andNew York
, onlyNew York
is returned.
How to Add Custom Entities
Use this page to import a .csv
file of custom entities that you create and want to use with Custom Entity Extraction.
- Custom Entities: Click to see the Custom Entities page.
- Choose File: Click to select a custom entities file to import.
- Import Entities: Click to populate the Custom Entities table above.
Custom Entities Format Example CSV
Simple
Extract Common Entity by name.
This example extracts "United States" and/or "Canada" when matched within the source.
Results
Simple with Translation
Results
Searching on Multiple Entities
OR
Results
Searching with Multiple Output Values
Results
Custom Entities Format Example SQL
Info:
SQL uses similar format as CSV but takes advantage or 1 to many rows.
Table Column Names do not matter only positioning.
Simple
Extract Common Entity by name.
This example extracts "United States" and/or "Canada" when matched within the source.
Results
Simple with Translation
Results