Improving the customer’s experience via ML-driven payment routing

Xianyun Mao, Stan Xu, Rachit Kumar, Vikas R, Xia Hong, Divyakumar Menghani25 Jan 2023

Problem

LinkedIn charges cards on every renewal of its monthly and annual subscriptions. Most transactions can go through two or more payment gateways. Traffic was split between them by more than 100 static rules (per country, currency, transaction, product and card type). The rules ignored that approval rates of gateways change over time, and updating them by hand was error-prone. A failed charge can end in service suspension and involuntary cancellation, so a lower approval rate loses paying customers.

Example from the article: ads payments in the US were routed to gateway A and gateway B in a fixed 40-60 split regardless of which gateway approved more.

Solution in brief

Treat routing as supervised classification. Resample the logged transactions so that every gateway is equally represented (inverse probability weighting by bootstrap), train a multiclass softmax logistic regression on the resampled data, and send each transaction to the gateway with the highest predicted score. The model was validated against the old rules in an A/B test.

Questions this case answers
  • How to learn which of several interchangeable options works best for a given context from logs produced by a fixed random allocation, when the allocation itself skews the training data
  • How to replace a large set of manually maintained allocation rules with a model that adapts to changing option performance
  • How to route subscription renewal payments across several payment gateways to maximize the approval rate?
  • How to replace a hand-maintained table of routing rules with a model that follows changes in gateway performance?

Tools and methods

  • Inverse probability weighting via bootstrap sampling — removes the bias caused by the old traffic split
  • Multiclass softmax logistic regression — predicts the best gateway; chosen for low serving cost
  • A/B test of model-based engine vs rule-based engine — checks the approval-rate lift with 95% confidence intervals
  • Periodic refresh — retrains on routing data since the last update
Continue reading — it's free

Google or a one-time email code. No password.