Quick Start

This guide walks you through publishing your first forecasting model on pd4castr — from installing the CLI to viewing your results in the platform. You can complete the entire workflow in about 10 minutes.

Prerequisites

Before you begin, make sure you have:

  • Node.js version 20 or later
  • Docker installed and running
  • A pd4castr account — create one at pd4castr.com.au
  • Publisher access on your organization’s account (required for publishing) — contact us to get set up

Step 1: Install the CLI

Install the pd4castr CLI globally with npm:

npm install -g @pd4castr/cli

Verify the installation:

pd4castr --version

For more details, see Install the CLI.

Step 2: Authenticate

Log in to connect the CLI to your pd4castr account:

pd4castr login

The CLI displays a verification URL and a login code. Open the URL in your browser, enter the code, and complete the login flow. Once finished, the CLI confirms you’re authenticated:

✔ Successfully logged in to the pd4castr API

For more details, see Authentication.

Step 3: Scaffold a project

Create a new model project from a template:

pd4castr init

The CLI prompts you for a project name and a template. Choose python-demo to start with a working example that includes sample data and configuration:

? Name your new model project: my-first-model
? Select a template: python-demo
✔ Template fetched successfully

This creates a my-first-model directory with everything you need:

my-first-model/
├── .pd4castrrc.json    # Model configuration
├── Dockerfile          # Container definition
├── model.py            # Forecasting logic
└── test_input/         # Sample test data

For more details, see Scaffold a Project.

Step 4: Test locally

The python-demo template includes static test data in test_input/, so you can run the model right away. Navigate into your project directory and start a test run:

cd my-first-model
pd4castr test

The CLI builds a Docker image, runs your model container against the bundled test data, and checks that all inputs were consumed and output was produced:

ℹ Starting model tests...
✔ Found 1 test input data files
✔ Built docker image (my-first-model:latest)
✔ Model run complete
	✔ Input Fetched - static_data.json
	✔ Output Uploaded
✔ Model I/O test passed

For more details, see Testing Your Model.

Step 5: Publish

When your model passes local testing, publish it to the platform. Publishing requires your organization to have publisher access — if you don’t have it yet, contact us to get set up.

pd4castr publish

The CLI validates your model, builds and pushes the Docker image, uploads any static inputs, creates the model on the platform, and triggers the first run:

✔ Model I/O checks passed
✔ Docker image built
✔ Docker image pushed
✔ Static inputs uploaded
✔ Model created on pd4castr
✔ Model run triggered

For more details, see Publishing.

View your results

Once the model run completes, open the pd4castr platform to view your forecast output. You can see the forecast chart, inspect input data, compare sensitivities, and explore the data using SQL.

For an overview of the platform, see Platform Overview.

Next steps