Exporting a Model
This function exports all files that are needed to deploy a trained model to a TIBCO Patterns server. The following files are exported for the selected model:
|
•
|
The trained model binary file |
|
•
|
A Java source file that contains the TIBCO Patterns query with all model features |
|
•
|
All thesaurus files used by the TIBCO® Patterns Search query |
Figure 52: Exporting a Model
To export a model do the following:
|
1.
|
Select the model to be exported. |
|
2.
|
Click Export Executable Model. |
|
3.
|
Specify the names of the model and query files and the location for the exported files. |
Note: Make sure that the specified directory does not contain any thesaurus files that should be preserved because any thesaurus files with the same names will be overwritten.
The exported model can then be loaded to a TIBCO Patterns server. You should also load a table with fields that are identical to the ones in the data table used to train the model. In addition, all thesaurus files used by the query should be loaded to the server. The thesaurus name on the server must be the same as the thesaurus file name.
In a typical scenario, you use the exported Java method to obtain a NetricsQuery object with values from one record of the loaded table, or with values of a new incoming record. Then you can perform a search operation on the server table using that query, which in turn uses the Learn model that you have loaded to the server to predict the final query result. Thus the query finds records in the table that are predicted by the model to be the most similar to the record used to create the query. This allows you to use the model for finding likely duplicate records in the table. For more information on the relevant operations with the server, see TIBCO Patterns Concepts Guide.
Note: The Query file name is also used as the name of a Java factory class. This class provides a method that generates a NetricsQuery object, representing the query used to match a record with the given set of field values.