Predictive and Portable Models
  • 30 Oct 2024
  • 4 Minutes to read
  • Dark
    Light
  • PDF

Predictive and Portable Models

  • Dark
    Light
  • PDF

Article summary

Note

As of Release 6.7 clients will no longer be able to create new Predictive Coding sessions. Existing Predictive coding sessions are not disabled, they can continue to be used in the near term. It is highly recommended that clients use CMML with ACS as a replacement for PC.

Predictive Models

Brainspace’s Predictive Coding and Continuous Multimodal Learning (CMML) classifiers support generating a predictive model on a dataset after coding example documents. The predictive model can then be used on later classifiers (usually in different datasets) to score all of the documents in the classifier to prioritize and classify them.

A portable model is a *.csv (comma-separated values) file containing a simplified version of a CMML predictive model. Each line in the *.csv file is a feature description followed by a portable weight between -100 and 100.

Creating a Portable Model

You can create a portable model in three ways:

  • Exporting a predictive model from a classifier within an active dataset

  • Starting with an existing portable model and editing it

  • Manually creating a *.csv file in the proper format

When exporting an existing predictive model as a portable model, only the most influential features are retained and the coefficients are scaled and rounded between -100 and 100. An exported portable model can be either saved outside of Brainspace as a *.csv file or within Brainspace in the portable model library, managed in the Administration panel.

Note

6.4 introduces a new Supervised Learning algorithm that introduced a different weighting scale for term weights. In previous versions of Brainspace the term weight scale was -100 – 100. The new scale is -10-10 which requires users that have any models built in earlier versions to adjust the term weights. For example if users have an earlier model that has a term with a weight of 15 in 6.4 that weight would need to be converted to 1.5.

An existing portable model in *.csv file form can be edited, or curated, before importing it into a new dataset. Editing can drop features, change the weight of features, and add features. Features can be words or phrases, as well as metadata values described by feature descriptions.

Since a portable model is simply a *.csv file with a particular format, it is also possible to create a portable model file manually , without beginning from an existing exported portable model.

An imported portable model will be converted to a predictive model. The predictive model can then be used just as if it was trained on that dataset. It can also be updated with training data from the dataset to further improve it.

Portable Model File Formatting and Editing

A portable model is a *.csv (comma-separated values) file. The first row of the file is a header with the column headings “term” and “weight.” The remaining lines each contain a single pair consisting of a feature description in the first column and a portable weight in the second column. Below are examples of feature-weight pairs:

  • purple, +5

  • augmented intelligence, +7

  • échantillon aléatoire, +2

  • 机器学习, +3

  • “[“”cc””,””fred jimes <[email protected]>””]”, +1

  • “[“”emailclient””,””outlook””]”, +2

  • “[“”created-year-month-day-hour””,””2001120412″”]”, -3

The first four examples are textual features, while the last three are metadata features. As shown above, the feature description for a term (a textual feature) is just the term (word or phrase) itself. You can enter terms manually in a *.csv file or convert an existing lists of keywords to *.csv format.

Metadata feature descriptions require more care. It is important both to know what derived features are present in your dataset of interest, and to observe the proper formatting of the JSON array used for metadata feature descriptions. When using metadata features in a portable model, we recommend starting with an exported predictive model from the dataset of interest, or one with the same fields and import configuration.

Portable weights must be integers between -100 and 100, including 0. There should be no decimal point, and scientific notation should not be used (so write 100, not 1E+2).

Portable Model Character Encoding

Portable model files use the UTF-8 character encoding. The usual 7-bit ASCII encoding is equivalent to UTF-8 for the characters typically used in English, so you can usually ignore character encoding issues when editing portable model files that contain only English.

For portable model files that contain non-ASCII UTF-8 characters, care needs to be taken to both import the portable model *.csv file using UTF-8 encoding and to export the *.csv file preserving the UTF-8 encoding. This may be challenging in some versions of Microsoft Excel, for instance. You may want to consider using a text editor or *.csv file editor with explicit UTF-8 support.

New Portable Models

When creating a new portable model, provide a name, select a *.csv file to upload, and optionally select which user groups can access the portable model.

Create a Portable Model from a CMML Classifier

After creating a CMML classifier and running training rounds, you can convert any completed training round to a portable model.

To create a portable model from a CMML classifier training round:

  1. Click the Supervised Learning tab.

    The Supervised Learning screen will open.

  2. Click a Classifier card.

    The Classifier screen will open.

  3. In the Training pane, click the Portable Model Actions icon:

    The Portable Model Actions dialog will open.

  4. To save the portable model to the Brainspace library, Click the Save to Portable Models button.

    The Save Portable Model dialog will open.

  5. Type a name for the portable model.

  6. Toggle one or more Portable Model Groups switches to the On position.

  7. Click the Save button.

After creating the portable model, you can use it to create a new CMML classifier, or you can download the Portable Model as a *.csv file.

Download a Portable Model as a *.csv File

After running CMML classifier training rounds, you can download a *.csv file for any of the training rounds.

To download a Portable Modal as a *.csv file:

  1. Click the Supervised Learning tab.

    The Supervised Learning screen will open.

  2. Click a Classifier card.

    The Classifier screen will open.

  3. In the Training pane, click the Portable Model Actions icon:

    The Portable Model Actions dialog will open.

  4. To save the portable model to the Brainspace library, click the Save to Portable Models button.

    The Save Portable Model dialog will open.

  5. Type a name for the portable model.

  6. Toggle one or more Portable Model Groups switches to the On position.

  7. Click the Download button.


ESC

Eddy AI, facilitating knowledge discovery through conversational intelligence