Skip to content

6.1. Cloud

To productionise code, insurance teams increasingly rely on the cloud.

At its simplest, the cloud is just a machine you rent on-demand — one you can configure, deploy code to, and run jobs or APIs on.

The two dominant providers are Amazon Web Services (AWS) and Microsoft Azure. Within insurance, Azure is the more common choice because of enterprise adoption and integration with existing Microsoft tools.


Compute Options

There are two main types of compute service to run your code in the cloud: Serverless and VMs/Clusters.

Feature Serverless (e.g. AWS Lambda, Azure Functions, Container Apps) VMs / Clusters (e.g. Azure VMs, Kubernetes Service)
Configuration Minimal setup, you just write and deploy code More setup: choose OS, instance size, networking
Run Pattern Starts on trigger, runs code, shuts down automatically Always-on, runs continuously
Cost Model Pay only for execution time and resources used Pay for uptime (even if idle)
Best for Small workloads, APIs, event-driven tasks Large/long-running apps, model servers, APIs
Scalability Automatic horizontal scaling (spins up instances as needed) Manual or semi-automated scaling
Use Case in Pricing Quick rating factor transformations or batch scoring jobs Hosting rating engines, pricing APIs, or dashboards

Example in Pricing

  • Serverless:
  • An Azure Function could score a single quote in milliseconds whenever the aggregator calls your API.
  • A container app could process batch jobs of quotes overnight, only running when triggered.

  • VMs/Clusters:

  • Hosting a pricing API that needs to be always online.
  • Running a distributed LightGBM model training job across multiple nodes.

Development Workflow

A typical workflow looks like:

Develop locally → Push to repository → Deploy to cloud

To make this smooth and reliable:
- Ensure your local environment matches cloud compute (e.g. Docker containers).
- Automate testing and deployment (using CI/CD pipelines).