ContextHub - Import Screen

For quick ingestion of context data without plugging in an integration through APIs, there is a context item import available, where CSV files containing your data can be uploaded. For example, to do a quick import of a file with lab sample measurements. 

This feature enables you to import historical and ad-hoc context data from an external platform: 

  1. In ContextHub click on the  icon situated on the left side panel.  
  2. Click on "Add component" and populate the fields. In the right-hand side panel, the appears.   
  3. Select your file to import, and either drag and drop your file or upload via the browse files option. 
  4. Select the "View import history" button to list previous importations.  

Screenshot_2021-10-13_at_13.47.47.png

Existing logbook applications, OEE tools, spreadsheets with batch data, LIMS data or other 3rd party tools can have their data ingested and imported as context. Providing aligned workflows and types are available in ContextHub, Context Item import functionality allows you to use a standardised CSV format to easily import data from external systems.

CSV Files 

CSV stands for comma separated values, and the .csv file format is commonly used to exchange data between applications. This format can be easily imported and opened by excel, and vice versa. Further information on the rules and uses of CSV files is provided in the TrendMiner help panel. Just type "csv-file requirements" into the help panel search tool and open the file. 

The CSV-file consists of the following columns in which the listed info is required: 

Column # 

Column-name 

Required info 

Description 

Text that will show up as the context-description. 

Type 

Technical identifier (used in imports, API calls, etc.) of the Context Item Type 

Keywords 

Keywords separated by commas e.g. "keyword1, keyword2, ..." 

Events_0_state 

Start state as defined in the corresponding Context Item Workflow 

Events_0_ts 

Timestamp of the starting state in "UTC" format YYYY-MM-DDThh:mm:ss:SSSZ 

Events_1_state 

End state as defined in the corresponding Context Item Workflow 

Events_1_ts 

Timestamp of the end state. 

Properties_0_key 

Technical identifier of the Context Field (or other property) 

Properties_0_value 

The value of the Context Field (or property) 

10 

Properties_1_key 

Technical identifier of a second Context Field (or other property) 

11 

Properties_1_value 

The value of the second Context Field  

Note: Dates in TrendMiner are represented in UTC with the option to include time zone information in alignment with ISO-8601. 

Note: The administrator can configure several states and substates that can be employed within a workflow. There is no limit to the number of states you can use. 

Note: We employ a REST API to enable more elaborate integration with data in ContextHub e.g., data ingress to retrieve data from external systems and data egress to expose context data to business intelligence tools. REST API development teams can develop integrations of choice if required. 

Note: Make sure to check the format of the .csv file after editing it in tooling like spreadsheet software. Depending on the settings and tools used, a csv file can be saved as comma separated or semicolon separated. 

Possible error messages 

Message 

Problem 

Incorrect number of tokens found in record: expected 9 actual 8. 

The provided line in the CSV file does not have enough columns. Provided are 8 but expected are 9. 

Validation failed.: field identifier Must not be empty. 

  • On a single line: the value for the "Property_x_key" column was not provided. 
  • On every line: the "Property_x_key" column was not provided in the header line. 

Validation failed.: events[x].occurred Must not be null. 

  • On a single line: the value for the "Events_x_ts" column was not provided. 
  • On every line: the "Events_x_ts" column was not provided in the header line. 

Too few columns. Make sure to use a comma instead of a semicolon as separator. 

The used separator might be a semicolon. TrendMiner uses a regular comma as separator. 

Default types and workflows 

Type

Workflow 

States 

OPERATIONAL 

OPERATIONALSTATES 

In progress, Paused, Ended 

ANOMALY 

STARTENDSTATES 

Started, Ended 

INFORMATION 

 

 

MAINTENANCEPLANNED 

MAINTENANCESTATES 

Started, Completed, Inspection, Ended 

MAINTENANCEUNPLANNED 

MAINTENANCESTATES 

Started, Completed, Inspection, Ended 

LOSSQUALITY 

STARTENDSTATES 

Started, Ended 

LOSSPERFORMANCE 

STARTENDSTATES 

Started, Ended 

LOSSAVAILABILITY 

STARTENDSTATES 

Started, Ended 

EQUIPMENTFAILURE 

STARTENDSTATES 

Started, Ended 

SAMPLE 

REQUESTRECEIVEDSTATES 

Requested, Received 

OUTOFSERVICE 

STARTENDSTATES 

Started, Ended 

MEASUREMENT