▷ INTERACTIVE EXPLAINER

A Bitcoin address becomes a self-organizing pool.

One bc1p… address. Some UTXOs. A signing agent that classifies them, verifies the AMM math, and signs the PSBT. The pool isn't a smart contract — it's the address itself, plus the math the agent runs.

Open the X-ray ↓ Play with the math
02 · TWO POOL TYPES, SAME ARCHITECTURE

Single-Rune vs Multi-Rune.

The architecture is identical: a Taproot address + an agent. The only thing that changes is how many runes the agent recognizes inside it. Toggle below to see how the X-ray morphs.

CURRENT VIEW

Single-Rune Pool

Two reserves: BTC sats and one rune. The agent runs x · y = k on these two numbers. Simple, fast, ideal for first-time pools.

  • 1 rune type held inside the address
  • 1 row in swap_pools + is_multi_rune = false
  • Quote = pure constant-product on the two reserves
  • Swap output: BTC → user · runes change → pool
01 · X-RAY OF THE POOL

What's inside the address.

Every pool — Single or Multi-Rune, KS-operated or User-operated — is just a Taproot address holding a mix of UTXOs. The signing agent reads them on-chain, classifies each one, and only ever spends the right kind for the right job. Hover the dots in the X-ray below to see what the agent sees.

bc1p7xn…poolAddr…0p3 AGENT classify · price · sign Pure BTC UTXO 丰 132,500 sats · spendable for fees + payouts used as: BTC reserve
Pure BTCspent for swaps + fees
Rune UTXOOP_RETURN runestone — never spent as fee
Inscriptionlocked — never touched, ever
The agentreads on-chain, verifies + signs PSBT
03 · THE MATH, LIVE

Constant product. x · y = k.

Every swap inside the pool obeys one invariant. Move the sliders to feel how the price, the slippage and the fee all derive from this one equation — the same logic the agent runs locally before signing the PSBT.

132,500 × 100,000,000 = 1.325 × 10¹³
You receive
~ —
runes
Effective price
Slippage
Pool fee earned
k after swap
Price impact 0.0%
k drift visualized — invariant preserved net of fee
04 · THE LIVE SWAP FLOW

From click to atomic settlement.

Click Run swap to watch one full atomic swap travel through the system. Every node verifies the next node's work — nobody is trusted blindly.

1
Userchooses pool on /swap
2
Kray Space (router)builds PSBT · OP_RETURN runestone
3
Agent (local)reads real on-chain UTXOs · ignores server claims
4
Agent~25 immutable rules verified
5
Agentsigns pool inputs (SIGHASH_ALL)
6
Routerre-validates the signed PSBT
7
Usersigns their input · KrayWallet / UniSat / Xverse
8
Routervalidates all sigs · broadcasts
9
Bitcoin L11 atomic transaction · settled

Same address. Same agent. Yours.

Now that you've seen what's inside the pool, decide which side of the swap you want to live on.