Cost-function market makers

A whole family of automated market makers is described by a single convex potential $C(q)$ over the outstanding share vector (Abernethy–Chen–Wortman Vaughan): prices are the gradient $\nabla C(q)$, convexity gives no-arbitrage, and a bounded gradient range gives bounded worst-case loss.

$p(q)=\nabla C(q), \qquad \text{worst-case loss}=\sup_q C(q)-\inf_q C(q)$

LMSR is the special case $C(q)=b\log\sum_i e^{q_i/b}$; a quadratic potential gives a bounded-budget maker that is not a probability market. A CFMM is the convex conjugate of a cost-function maker — the same object seen from the reserves side.

Code: mechanisms/cmm.py · Demo: examples/sim_cmm.py · Research: market-scoring-rules-and-amms.md