RunMat for quantitative finance

Keep running the pricing, risk and economic models you already trust, unchanged, and run more of them on hardware you own.

Talk to us

Keep the models you have already validated

You have years of pricing, risk and capital models written in MATLAB. They have been through validation, they run in production, and the people who wrote them still maintain them. Moving to Python means rewriting each one and validating it again.

RunMat runs those files as they are. You keep the models you signed off and the people who know them.

FinanceMigration guide

european-call.m
% A European call priced by Monte Carlo and checked against Black-Scholes.
% With four million paths the estimate should sit within a few standard
% errors of the closed form.
rng(42);
S0 = 100; K = 105; r = 0.03; sigma = 0.2; T = 1;
n = 4e6;
Z = randn(n, 1);
ST = S0 * exp((r - 0.5*sigma^2)*T + sigma*sqrt(T)*Z);
payoff = exp(-r*T) * max(ST - K, 0);
price = mean(payoff);
se = std(payoff) / sqrt(n);
bs = blsprice(S0, K, r, T, sigma);
gap = abs(price - bs) / se;
fprintf('Monte Carlo %.4f, standard error %.4f\n', price, se);
fprintf('Black-Scholes %.4f, %.1f standard errors away\n', bs, gap);
Terminal
$ runmat european-call.m
Monte Carlo 7.1271, standard error 0.0063
Black-Scholes 7.1281, 0.2 standard errors away

Run your models in containers and CI like the rest of your stack

Putting a MATLAB model in a container usually means an image of several gigabytes and a license server that every container has to reach. On Kubernetes, every worker pod that starts checks out a license and every pod that stops gives one back.

RunMat is a single executable of about 200 MB, written in Rust. It starts in under a second, needs no license server and runs the same on Linux, macOS and Windows, so your nightly risk job goes into a Docker image, a CI pipeline or a Kubernetes pod like any other service you run.

CI and containersSelf-hosted deployment

Dockerfile
FROM debian:bookworm-slim
RUN apt-get update && apt-get install -y curl libopenblas0 \
&& curl -fsSL https://runmat.com/install.sh | sh
COPY models/ /models
CMD ["runmat", "/models/nightly_var.m"]

A deterministic engine designed for AI models to use in controlled loops

RunMat is a deterministic engine: the same script and inputs give the same result every time. It is designed for AI models to use in a controlled loop, for work like the pricing and risk code on this page.

The AI model writes the change to your code. RunMat checks its types and shapes and sends any error back for the model to fix, then runs it. The model reports the result and how it was computed, and every number in that answer came from RunMat, so your validators can rerun it and get the same figure.

Use Claude Code, Codex, any MCP client or the agent built into RunMat, on the model your firm already uses.

AI integrations

Works withClaude CodeCodexAny MCP client

AI modelSets up and interpretsRunMatChecks and runs the studystudyerrors and results
  1. ModelWrites cantilever.fea
  2. RunMatline 28: traction must be force per area, found N
  3. ModelFixes the load unit: N → Pa
  4. RunMatSolved · tip deflection 0.199 mm, beam theory 0.200 mm
  5. ModelReports the results and how they were computed

Fit more scenarios inside the overnight run

Your overnight run has to finish before the desk opens, and every stress scenario you add pushes it later. Expected shortfall under FRTB and nested projections for Solvency II only make that worse.

RunMat runs the same script across every core you have, your GPUs or your own cluster. Going from one core to many is changing for to parfor, and the model stays as you wrote it.

ParallelGPU

% 1,000 stress scenarios, each a full revaluation of the book
loss = zeros(1, 1000);
parfor k = 1:1000
    loss(k) = revalue_book(book, scenarios(k, :));
end
worst = sort(loss, 'descend');
es = mean(worst(1:25));   % worst 2.5%
LaptopRemote serverLARGE CLUSTER

Rerun any number your validators ask about

When validation asks how you got a number, you need the exact code, inputs and random seed from that run. RunMat keeps all three with every run, so you can rerun it exactly.

You can also open the run with the validator and both point at the same strike on the surface while you talk it through.

Roll it out across the whole team

Put RunMat on every analyst's machine and run its server and workers on your own cluster, fully offline if you need to. Your models and client data stay on your network, and your security team can read the source.

Self-hosted deploymentSecurity

Examples

Monte Carlo estimate of a European call converging on the Black-Scholes price, rendered by RunMat

European call by Monte Carlo

Four million paths against the Black-Scholes price.

Arithmetic against geometric Asian payoffs, nearly on one line, rendered by RunMat

Asian option with a control variate

The geometric average cuts the error for the same paths.

Histogram of one-day P&L with the 99% value at risk marked, rendered by RunMat

Value at risk and expected shortfall

500,000 correlated scenarios against the normal closed forms.

Implied volatilities by strike with a fitted quadratic smile, rendered by RunMat

Implied volatility smile

Volatilities from rounded quotes, with a fitted smile.

Par yields and the fitted Nelson-Siegel curve out to 30 years, rendered by RunMat

Nelson-Siegel yield curve

Level, slope and curvature fitted to ten par yields.

Impulse responses of inflation, the output gap and the policy rate over 20 quarters, rendered by RunMat

Responses to a policy-rate shock

A VAR in inflation, output and the policy rate.

What RunMat does not do

  • Market data feeds and terminal connections
  • Order management and trade execution
  • A backtesting platform for trading strategies
  • Simulink-style block diagrams

Start here

  1. 01

    Open the option pricer in your browser. No account needed.

  2. 02

    Run three of your own models and compare their results and run times.

  3. 03

    Talk to us about your models, your team and where it runs.

FinanceStatisticsParallel computingCI and containers