Resolved Entity Analyzer
This sample code shows how to use Markup entities and Disambiguated entities and how to use the Linked Data to get additional info on entities (how to retrieve information from the Linked Data end point).
Basically, the code sends a document to OpenCalais with RDF output format, and then analyzes the Companies, Geographies, Products, marked-up Companies, and the relevant disambiguated company URIs in the Linked Data. It outputs an xml file containing simplified data gathered from OpenCalais and Linked Data.
The application sends a document to OpenCalais with RDF output format. It analyzes the entities and outputs an xml file containing simplified data gathered from OpenCalais and Linked Data.
For the three companies (if they exist in the document) with the highest relevance scores, the application provides the following:
- A list of competitors (taken from the Linked Data end point)
- A list of executives (taken from the Linked Data end point)
- A link to Reuters.com (taken from the Linked Data endl point)
- The Markup entity name
- The resolved entity name
For the two geographies (if they exist in the document), the application provides the following:
- The Lat and Long (taken from the Linked Data end point)
- The link to Wikipedia (taken from the Linked Data end point)
- The link to Freebase (taken from the Linked Data end point)
- For cities, the state (taken from the Linked Data end point)
- The Markup entity name
- The resolved entity name
For products (if they exist in the document), the application provides the following:
- The full product name (taken from the RDF)
- The link to Shopping.com (taken from the Linked Data end point)
- The Markup entity name
- The resolved entity name
Download the attached files.
Usage: run.bat [OpenCalais license key] [text file path]
Output: output.xml in the current folder
| Attachment | Size |
|---|---|
| REA_09Mar12.zip | 16.49 MB |
