Does the average transaction size hold purchasing power?
PaSta's stability idea is that the network mints or burns a little coin in every transaction to keep the average transaction size constant, and that this keeps the coin's purchasing power constant. These are the first results from PastaTester, a toy economy built to test that claim before any of it goes into the node.
Generated from pastacoin/pastacoin commit . Every number is reproducible with one command (see the bottom of the page). The full memo is docs/SIMULATION-RESULTS.md.
1. The toy economy
200 agents hold PASTA and buy goods from each other. Goods have hidden "real" prices that nobody in the economy can see; the PASTA price of a good follows the quantity theory of money, p = M / (k · Q): total money M divided by money demand k (how much people hoard) and real trade volume Q. The charts below plot p, the PASTA price level, relative to its value just before a shock. A flat line at 1.0 means purchasing power was held.
Three policies see every transaction amount and decide how much to mint (paid to the seller on top of the amount) or burn (taken from what the seller receives):
- No controller. Money supply fixed. The baseline.
- Whitepaper rule (trend). Compares a fast moving average of transaction size with a slow one. Mints only into above-average transactions when the average is falling, burns only from below-average ones when it is rising.
- Anchored to launch average. The same asymmetric rule, but the reference is the average transaction size at launch instead of a moving one.
2. What happens after a shock
Each panel applies one change to the hidden economy at step 2000 (vertical line) and shows the price level under the three policies. Hover for values.
3. Final price change by shock
The same runs, summarised. Zero is perfect. The last two groups are the ones that break the anchored rule.
Table view of this chart
4. What breaks when transactions get larger
Suppose people keep spending the same amount in total but do it in fewer, larger transactions (installments becoming lump sums, or purchases being batched). Purchasing power has not changed at all. The average transaction size has. The controller cannot tell the difference and reads it as inflation.
Self-inflicted price change vs. transaction size factor
Shock at step 2000; total real spending unchanged; money demand k = so agents can afford the larger purchases.
Table view of this chart
5. Gain: speed against churn
The anchored rule's gain sets how hard it pushes per transaction. Under the hoarding shock, low gain recovers slowly with almost no burning; high gain recovers fast but mints and burns a lot of coin along the way.
Steps to get back within 5%
after the hoarding shock
Total coin minted and burned
over the whole run
Table view of these charts
6. Doing nothing well: bias with no shock
A controller should sit still when nothing is happening. The whitepaper's asymmetric rule inflates steadily, a symmetric variant deflates hard, and the anchored rule climbs about 19% in the first 1500 steps and then flattens. Two mechanisms: adjustments are sized as a fraction of the transaction they ride on, so mints (attached to large transactions) and burns (attached to small ones) do not balance; and the controller only sees executed transactions, so large purchases that are skipped as unaffordable make the observed average read low until enough coin has been minted to close the gap. Both are tracked as issue #28.
7. Round two: a robust signal, supply-sized adjustments, a cap, and attackers
Round one showed the rule needs an anchor and that carrier-sized adjustments are biased. Round two rebuilds the controller: once per period it computes one supply change from its signal, bounded by a cap on how much the supply may move per period, and spreads it across the next period's transactions in proportion to their amounts. Amounts below 5% of the running median are ignored as dust. Two signals are tested: the period median transaction size against a launch anchor, and nominal flow per holder (addresses holding at least half a typical payment) against a launch anchor. Two attackers join the economy: wash traders bouncing a typical payment ten times a step, and sybils, 200 dust addresses paying each other. Money demand is 100 in this round so affordability does not distort the statistics.
A third rule, the hybrid, acts on the median-size signal but watches flow per holder for the decomposition: when the median takes a sudden step, it acts only on the part of the step that flow per holder also shows (the monetary part) and, once the step has settled, moves its anchor by the rest (the structural part). Slow drifts never look like a step and pass straight through to the size signal. Two combined cases test it: hoarding and a granularity shift at the same moment, and a granularity step during steady real growth. The round-one rule stays in the table for reference but is left off the charts.
Table view: round two drift, recovery and attacker gain
Which knob fixes what
The same attacks against variants of the rules. Turning the dust floor off, or counting active addresses instead of holders, reopens the sybil hole.
What the cap costs: recovery from hoarding
median-size rule at gain 0.01, steps to get back within 5%
What the cap buys: damage when fooled
sybil dust with the dust floor off; price level change, log scale
Table view: cap sweep
Growth allowance under steady real growth
Table view: growth allowance
Where this leaves the design: the chain data on the multi-chain page says granularity shifts on payment-style chains were small over thirteen years while the median tracked purchasing power. The hybrid is the candidate rule for the node: median size with a dust floor and a cap as the primary signal, flow per holder to decompose sudden steps. Open items are the residual error when a granularity step lands during steady growth, and the storage-weighted user count from the whitepaper, which is the real defence against funded sybils.
8. The real-world companion: Bitcoin
Bitcoin is the natural fixed-supply test case for the shrinking-transaction claim. The Bitcoin demonstration rebuilds the whitepaper's chart from public chain data, corrects it for minted coins, and shows where the average-transaction-size gauge held and where it broke. The multi-chain page repeats the test on Litecoin, Dogecoin, Bitcoin Cash and Ethereum using the median transaction, which is where the whitepaper's assumption actually holds.
9. Limitations
- The price level is a closed-form quantity-theory expression, not an emergent market price. No expectations, no interest, no external exchange rate.
- With the default money demand, agents hold about two purchases' worth of coin, so roughly 45% of attempted purchases are unaffordable and skipped. This biases observed averages. The granularity sweep uses a higher money demand for that reason.
- Sellers receive the mint or burn; buyers always pay the face amount. The split is a design choice.
- No adversarial agents yet (self-dealing, wash trading). Issue #13.
10. Reproduce
git clone https://github.com/pastacoin/pastacoin && cd pastacoin python -m venv .venv && .venv/Scripts/pip install -e ".[dev]" matplotlib .venv/Scripts/python -m pasta.sim.report --json results.json --figures figures .venv/Scripts/python -m pasta.sim --compare --shock 2000:money_demand:1.5 # one experiment