Getting Started

Welcome to the “getting started” guide for Praexia. Here we’ll explain how to get up and running with the latest version of Praexia, and where to find documentation and examples.

What is Praexia?

Praexia is a library that allows credit modellers and decision scientists to train and create credit scorecards.

Out-of-the-box, Praexia includes a lot of the common toolkit that a credit modeller would typically need – many of them visual tools. This includes modules for data wrangling, analytics, binning, scorecard creation, and so on.

In order to get credit modellers up and running quickly, we also include fully-worked templates and examples using an included toy dataset.

Installation

If you’re using a managed or self-hosted Praexia instance, everything should be set-up for you already! If you don’t yet have a Praexia instance or license, please visit the official Praexia website to get access.

If you have an existing Praexia instance, and an update is available, you can use pip to upgrade to the latest version of Praexia:

pip install --upgrade constrata-core-credit

If you’re running on Sagemaker, then you need to install the sagemaker variant:

pip install --upgrade constrata-core-credit[sagemaker]

You may also need to enable “Enable Extensions Manager (Experimental)”, and install the bqplot extension, if you haven’t already.

Getting help

Every module of Praexia is fully documented. There are two ways to access documentation. Directly inside a notebook, or from the online documentation (which you’re viewing right now!).

In order to access documentation for any module or function from within the notebook, execute a cell with a ? appended to the module or function you’re interested in learning more about:

    from constrata_core_credit import model_evaluation

    model_evaluation.plot_roc?

This will print out the function’s signature, description, and describe the parameters:

Signature: model_evaluation.plot_roc(fpr, tpr, auc, model_name=None, fontsize=12)
Docstring:
Plot a Receiver Operator Curve (ROC).

:param fpr: A list of false positive rates.
:param tpr: A list of true positive rates.
:param float auc: The area under the curve.
:param str model_name: The name of the model used to plot the ROC.
:param int fontsize: The font size of the title and legend of the ROC plot.
:type fpr: float list
:type tpr: float list

Type:      function

If you prefer accessing the documentation externally, feel free to instead take a look at our online API Reference.

Examples

To help you hit the ground running, we package example notebooks with Praexia. These notebooks can either be used to learn about the various ways in which Praexia’s modules can be used, or as a template for your own credit modelling workflow.

Probability of Default Example

The PD example notebook describes the full end-to-end process of creating a PD model and the subsequent credit scorecard that predicts the probability of a customer to default.

To access this example, open a terminal in your Praexia instance, and execute the following command:

ccc init pd

This will create the example notebook in the local directory, and copy across all necessary example data. You can then select the notebook from the file browser in your Praexia instance.

Monitoring Example

The monitoring notebook directly follows the PD notebook, and demonstrates how to monitor the performance and stability of your trained credit model and scorecard once it has been used to score customers.

To access this example, open a terminal in your Praexia instance, and execute the following command:

ccc init monitoring

This will create the example notebook in the local directory, and copy across all necessary example data. You can then select the notebook from the file browser in your Praexia instance.