Natural Language Generation Example for TIBCO Spotfire®

An extensible natural language generation Spotfire dashboard implemented through a TERR data function.

Compatible Products

TIBCO Spotfire®

Provider

TIBCO Software

Compatible Versions

TIBCO Spotfire 10.x 

TERR 5.0.0 and above

CRAN packages: data.table 1.12.0, jsonlite 1.6, stringi 1.4.3

License

TIBCO Component Exchange License

Overview

With the help of a TERR data function users can now implement natural language generation inside Spotfire. The Spotfire dashboard is pre-loaded with generic template sentences that can be customised to more specific use cases. The TERR data function can be extended by following a set of design rules that are indicated within the script. The verbosity, level of detail and tone of the generated language can also be specified, and different languages can be added. 

Release(s)

Release 1.0.0

Published: March 2020

Initial release

There are currently no reviews for this content.

Why not be the first to review it - click here to login

Natural Language Generation with TIBCO Spotfire

This article describes an example of a Spotfire dashboard including natural language generation (NLG) implemented through a TERR data function. The example makes use of a template for the language generation, so that it is possible to specify the verbosity, level of detail and tone of the generated language. An end user with out R programming skills can change the generated language to fit with the application.

The data used in this example is the edits taken from from the Wikipedia RSS feed. The data contains the number of edited characters, the timestamp of each edit, the country and continent of the editor etc. 

This is how the example works:

1. The input data is loaded and the visualizations are rendered.

2. An ironpython script is used to extract data from the linechart, including the linecharts configuration (what columns are used on its axis).

3. The extracted data is passed to the natural language generation data function, that also takes the NLG map as input. The NLG map is a template for how the language should be generated given a set of input parameters and using a set of placeholder variables.

4. The natural language generation data function executes and identifies a set of insights and key facts about the input data. It then generates the natural language using the NLG map, the input parameters, the insights and facts and it replaces the placeholder variables in the NLG map with values it has calculated. The generated language is placed in a document property that can be used in the Spotfire visualizations as needed.

Below is a schematic overview of how it works:

If you want to try this yourself, please see the example on TIBCO exchange

 

 

 

 

View the Wiki Page