# Publishing Predictive Model Markup Language (PMML) Models to TIBCO® Artifact Management Server

The Publish Models workspace node allows TIBCO Statistica™ workspace designers to automatically connect to TIBCO® Artifact Management Server, and publish Predictive Model Markup Language (PMML) models. The workspace node can publish one or more Predictive Model Markup Language (PMML) models that are connected upstream. It is also capable of saving the connection details of TIBCO® Artifact Management Server. Statistica is the no-code model building, model management and development environment. TIBCO StreamBase® is the execute model in production environment. TIBCO® Artifact Management Server is a new add-on for the StreamBase product to manage metadata. The aim is to simplify the user experience of publishing PMML models from Statistica to StreamBase.

A sample template for designing Publish Models workspace node is also available. Template for Publish Models workspace node can be accessed by using the following path: Home > New > Workspace.

## Procedure

The Publish Models workspace node can be accessed from the Feature Finder, the Ribbon Bar or the Node browser.

1. In a workspace. On Publish tab, click Publish Models.

2. To open Publish Models dialog box, click the gear icon on the Publish Models workspace node.

   Note: You can also open the Publish models dialog box by double-clicking the Publish Model workspace node.
3. Enter the URL for Artifact Management server.
   1. For establishing secure connection, change the protocol to https.
   2. Enter the host name for Artifact Management server.
   3. The default port number for Artifact Management server is 2185. If Artifact Management server is hosted on a different port, change the port number.
4. Enter the credentials (such as Username, Password) for Artifact Management server for publishing the models.

5. In Artifact Management Server, the workspace node publishes the models to Statistica project by default. To publish models to a different project, enter Project Name.
   Note: The default Project Name on the workspace node is set to publish the models to Statistica in Artifact Management server. If Statistica folder does not exist, it is created automatically.
6. The default Folder name %user% is replaced automatically by the user account name when executing the workspace node. The models are published to the user account name folder in Artifact Management server. To publish the model in different folder in Artifact Management server, enter Folder Name.
   Note: If the folder does not exist, it is created automatically.
7. To automatically commit for approval to Artifact Management server, select Commit for Approval.

   Note: The workspace node includes a default Check-in Comment similar to, Published from Statistica [version number] by [username] from [workspace name] using [machine name] on [date time]. Optional check-in comments can be entered in the Check-in Comment . On successfully committing a model, these comments appear in the Notifications list in Artifact Management Server.
   Note: If the Commit for Approval option is not selected, then Auto approve, Review Comment, Push to StreamBase, Service Name and Operator options are disabled on the workspace node. Models are added to the local user repository and they are in checked out status in Artifact Management server.
8. To automatically approve the committed models, select Auto Approve. This option is only available to privileged users.

   Note: The workspace node creates a default Review Comment similar to, Approved from Statistica [version number] by [username] from [workspace name] using [machine name] on [date time]. Optional review comments can be entered in the Review Comment. On successfully approving a checked-in model, these comments appear in the Notifications list in Artifact Management Server.
   Note: If the Auto Approve option is not selected, then Push to StreamBase, Service Name and Operator are disabled on the workspace node.
9. To push a model to Streambase:
   1. Select Push to StreamBase.
   2. In the Service Name textbox, enter the name of the running StreamBase service.
   3. In the Operator textbox, enter the name of the PMML operator within the StreamBase Eventflow which is running on the server.
   Note: Push to Streambase check box is enabled, if a single model is connected to the Publish Models workspace node. For publishing models to StreamBase®, ensure that a StreamBase service is running on the same server hosting the Artifact Management server.
10. The models connected to Publish Models workspace node are listed in PMML Models section.
    1. The Publish column includes check box only for latest compliant PMML Models. It is selected by default. If it is not selected then, this model is not published to Arifact management server.
    2. Version number column displays the PMML Model version.
    3. Model Name column displays the name of the upstream PMML Model workspace node.
    4. Model Name in AMS column allows you to enter a new name for the model and publish to Artifact Management server. Only alpha-numeric, hyphen and underscore characters are allowed for model names in Artifact Management server.
11. To Run the Publish Model workspace node, right-click on the node and click Run or click the green play icon on the Publish Models workspace node.
    The PMML Models are published to Artifact Management Server.
    On successfully publishing the models to Artifact Management Server, the status messages for the PMML Model add, update, commit or approval from the Artifact Management server are added to the Publish PMML Models Summary Report output that is generated within the Reporting Documents workspace node.

    On successfully pushing the models to StreamBase, the status messages from the Artifact management server are added to the Publish PMML Models Summary Report output that is generated within the Reporting Documents workspace node.

    On failure, to publish a model to Artifact Management Server or push a model to StreamBase, the Publish Models workspace node generates error with the respective error message from the Artifact Management Server and stop further execution of the workspace.

Copyright © Cloud Software Group, Inc. All rights reserved.