---
title: "Register a Model Definition"
description: "Register a Model Definition to bring a trained model onto the platform."
---

import { Tabs, TabItem } from '@astrojs/starlight/components';

<div style="padding: 14px 16px; border: 0.5px solid #AFA9EC; border-radius: 12px; background: #EEEDFE; margin-bottom: 1.5rem;">
  <div style="display: flex; align-items: center; gap: 7px; margin-bottom: 8px;">
    <svg width="16" height="16" viewBox="0 0 16 16" fill="none">
      <path d="M9 2L4 9h4l-1 5 5-7H8l1-5z" stroke="#7f77dd" stroke-width="1.2" stroke-linecap="round" stroke-linejoin="round"/>
    </svg>
    <span style="font-size: 11px; font-weight: 500; letter-spacing: 0.05em; text-transform: uppercase; color: #534AB7;">TL;DR</span>
  </div>
  <div style="font-size: 13px; color: #3C3489; line-height: 1.65;">
    Bring a trained model into Corridor as a <strong>governed object</strong>, whether you built it in a Notebook or trained it outside with your own tooling (scikit-learn, H2O, ONNX, and more). Once registered, it can be <strong>simulated, explained, approved</strong>, and reused across Policies and other Models. This page walks through the registration form.
  </div>
</div>

## What is it?

The Model page is where you bring a trained model into Corridor as a governed object. Models built inside the platform in a [Notebook](/user-guide/how-tos/use-the-notebook/) or trained outside with your own tooling can both be registered. Once registered, they can be simulated, explained, approved, and used downstream.

A registered Model sits one layer above Features and Data Elements in the registry hierarchy:

<div class="flow-diagram">
  <div class="flow-row">
    <div class="flow-col">
      <div class="flow-box box-de">Data Elements</div>
      <div class="flow-box box-feature">Features</div>
    </div>
    <div class="flow-arrow">→</div>
    <div class="flow-box box-model">Model</div>
    <div class="flow-arrow">→</div>
    <div class="flow-col">
      <div class="flow-box box-policy">Policies</div>
      <div class="flow-box box-feature">Other Features</div>
      <div class="flow-box box-model">Other Models<small>(e.g. ONNX reader)</small></div>
    </div>
  </div>
</div>

## Benefits of a registered Model

**1. Reproducible scoring**

The platform validates the model's expected inputs against the registered objects you select. Every simulation runs through the same scoring code path that production will use (no drift between "the notebook version" and "the deployed version").

**2. Built-in governance**

- **Change management** and **version control**: every edit to the Model is captured as a new version.
- **Lineage**: see exactly which Data Elements and Features feed the Model, and every Policy or downstream Model that consumes it.
- **Permissible purpose**: tag the Model so it can only be used in approved contexts (for example, restrict an `underwriting`-tagged Model from a prospecting Policy).
- **Approval workflow**: submit the Model for review, attach a simulation as evidence, and route it to the right reviewers before it can go live.

**3. Explainability and monitoring out of the box**

Enable a [Model Explainer](/user-guide/how-tos/register-a-model-explainer/) at registration time and every simulation produces per-prediction contributions or reason codes. Standard **Model Quality** reports (ROC/AUC, KS, lift, confusion matrix for classification; error distribution for regression) are generated automatically from each simulation.

## How to Register

Follow these steps to register a Model.

<details open class="step">
<summary>

#### Open the Create Form

</summary>

On the **Model Studio → Model** page, click **+ New Model**.

A name prompt opens first. Enter a descriptive name for the Model (for example, `Default Within 18 Months`) and confirm to land on the full Model form.

</details>

<details open class="step">
<summary>

#### Fill in Attributes

</summary>

Set the **Model Type** <span style="color: #E5484D;">\*</span> - the type of prediction, such as `Binary Classification`, `Regression`, `Time Series`, or `Multi-class Classification`.

Set the **Output Type** <span style="color: #E5484D;">\*</span> - the data type of the output (for example, `Numerical` for a probability, `String` for a class label).

Fill in the **Alias** <span style="color: #E5484D;">\*</span> (the identifier used to reference the model's output downstream) and the **Entity** <span style="color: #E5484D;">\*</span>. See [Common Registration Info](/user-guide/how-tos/common-registration-info/).

Set the **Dependent**, the target variable the Model is trained to predict. Optional but recommended, since approval reviewers and downstream reports use it.

</details>

<details open class="step">
<summary>

#### Add Inputs

</summary>

In the **Input** section, search and select the registered objects the Model consumes.

- Inputs can include **Data Elements** and **Features**. Models can also consume other **Models** as inputs (useful for stacked models or ONNX reader models).
- Each input is referenced inside the model definition by its alias.

:::tip[Tip: paste a list of inputs at once]
If you already have the input list elsewhere (a notebook, a spec, an old model definition), paste it straight into the Input field. The platform resolves each name against the registry and adds the matching Data Elements and Features for you, so you don't have to search and click them in one by one.
:::

<div class="collapse-section" data-summary="About Transforms (optional)">

A **Transform** is a calculation applied to a model input (a Data Element or Feature) during model execution. It is **specific to this Model**, unlike a [Feature](/user-guide/how-tos/register-a-feature/), which is generic and reusable across Models and Policies.

Use one when your model was estimated on a derived value but only the raw input is registered. For example, a model trained on `requested_loan_amount_low` (1 if `requested_loan_amount < 5000`, else 0) needs that flag defined as a Transform, since only `requested_loan_amount` exists in the registry.

Transforms are created on the **Transforms** page and, once defined for a Model, appear on its details page automatically and are computed as part of model execution.

</div>

</details>

<details open class="step">
<summary>

#### Fill in the Formula

</summary>

The **Formula** section is where you provide the model definition.

**Define the model.** Pick the **Model Input Type** that matches your model and provide the file or logic:

<table class="attr-table">
  <thead>
    <tr>
      <th style="width: 22%;">Model Input Type</th>
      <th>Use when</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td class="field-cell">Python Function</td>
      <td>The scoring logic is a self-contained Python function.</td>
    </tr>
    <tr>
      <td class="field-cell">Pickle</td>
      <td>The model is a serialized scikit-learn (or compatible) Python object.</td>
    </tr>
    <tr>
      <td class="field-cell">PMML</td>
      <td>The model is exported to PMML by tools like KNIME, R, or SAS.</td>
    </tr>
    <tr>
      <td class="field-cell">H2O MOJO</td>
      <td>The model was built in H2O or H2O Driverless AI.</td>
    </tr>
    <tr>
      <td class="field-cell">ONNX</td>
      <td>The model was exported from Keras, PyTorch, scikit-learn, or another framework supporting ONNX. Requires a two-step setup.</td>
    </tr>
    <tr>
      <td class="field-cell">Custom</td>
      <td>Any other framework (e.g. TensorFlow). You provide the model file, initialization logic, and scoring logic directly.</td>
    </tr>
  </tbody>
</table>

Then follow the matching tab below.

<Tabs>
  <TabItem label="Python Function">

1. Provide the Python scoring function directly in the editor or upload the file containing it.
2. Each input alias from the Input section is passed as a Python value to your function.

  </TabItem>
  <TabItem label="Pickle">

1. Upload the pickle file.
2. If the model's expected inputs don't match the inputs you selected in the Input section, resolve the mismatch by adjusting the Input section.

  </TabItem>
  <TabItem label="PMML">

1. Upload the `.pmml` file.
2. Specify the **Output Field**:
    - For classifiers, the probability column for one of the dependent classes.
    - For regression, the predicted value column.
3. If a declared input doesn't match the file's expected inputs, add or remove inputs in the Input section to resolve the mismatch.

  </TabItem>
  <TabItem label="H2O MOJO">

1. Upload the MOJO file (H2O or H2O Driverless AI).
2. If the inputs don't match, resolve the mismatch by adjusting the Input section.

  </TabItem>
  <TabItem label="ONNX">

ONNX models are registered in **two stages**, because the raw ONNX output is an array.

**Stage 1: Register the raw ONNX model (M1)**

1. Set **Model Type** to `Time Series` so the array output is allowed.
2. Upload the ONNX file.
3. The **Output Field** is populated by the final layer name from the model build.

**Stage 2: Register the output reader (M2)**

Register a second Model (typically `Binary Classification`) whose **Input** includes M1. The reader reads the array from M1 and returns the element you want (for example, the first element as the probability).

:::note[Scikit-learn exported to ONNX]
Scikit-learn models exported to ONNX return a class label, not a probability. The Output Field is the class column.
:::

  </TabItem>
  <TabItem label="Custom">

For frameworks not covered above (for example, TensorFlow), provide the following:

1. **Model File**: upload the serialized model file.
2. **Initialization Logic**: code that loads the model object once. Its return value becomes the `model` available in the scoring step.
3. **Scoring Logic**: code that takes the input aliases plus the initialized `model` and returns the prediction.

  </TabItem>
</Tabs>

</details>

<details class="step">
<summary>

#### Enable the Model Explainer (optional)

</summary>

Once the definition is written, toggle **Model Explainer** on (below the definition editor) to produce per-prediction contributions or reason codes from each simulation. See [Register a Model Explainer](/user-guide/how-tos/register-a-model-explainer/) for the full walkthrough.

</details>

<details class="step">
<summary>

#### Link Training & Validation Data (optional)

</summary>

Optionally attach the data used to develop the Model, for approvers and reports. For each entry, pick a **Type** (a registered **Dataset** or a file **Location**) and a **Label** (Train, Validation, and so on). Click **Add** for more entries.

</details>

<details open class="step">
<summary>

#### Fill in Properties and Create

</summary>

Fill in the [Properties](/user-guide/how-tos/common-registration-info/#properties) (Description, Permissible Purpose, Group, and Keywords), then click **Create** at the bottom right. The Model is saved as a draft and you land on its details page.

</details>

## What's Next

- [Run a Simulation](/user-guide/how-tos/run-a-simulation/) on the Model to validate it on a representative sample.
- Add a [Model Explainer](/user-guide/how-tos/register-a-model-explainer/) to surface per-prediction contributions or reason codes.
- Send the Model for [approval](/user-guide/how-tos/approve-an-object/) so it can be used outside your draft workspace.
- Use the approved Model in a [Policy](/user-guide/how-tos/register-policy-decision-workflow/).
