Lean Client (@LeanClient) header
Lean Client (@LeanClient) profile picture

Open-source Solana client written in Lean 4

Joined November 2026
Photo by Lean Client (@LeanClient)Photo by Lean Client (@LeanClient)Photo by Lean Client (@LeanClient)Photo by Lean Client (@LeanClient)Photo by Lean Client (@LeanClient)Photo by Lean Client (@LeanClient)Photo by Lean Client (@LeanClient)Photo by Lean Client (@LeanClient)Photo by Lean Client (@LeanClient)
def main : IO Unit := IO.println "Hello, world!"
15
2
66
14,468
* all 47,071 instruction fixtures now producing same results as Agave
The Lean Solana client is now checked against the shared Agave and Firedancer conformance fixtures. 46,809 of 47,071 instruction fixtures produce the same result as Agave: the same success or failure, the same changed accounts, and the same compute units left. That includes every fixture for the system program, compute budget, precompiles, ZK proofs and loaders v1/v2/v4. It's the same code that replays mainnet, and every memory access in it is proven safe by Lean's kernel. The fixtures also caught three gaps in our model, now fixed: • lamport overflow past 64 bits • Agave's general rent formula • little-endian alt_bn128 compression None of them could change a mainnet block, but a trusted model should match Agave exactly. The remaining 262 differences are listed in the README and are being worked right now. github.com/MidTermDev/leanCl…
2
7
2
45
4,541
The Lean Solana client is now checked against the shared Agave and Firedancer conformance fixtures. 46,809 of 47,071 instruction fixtures produce the same result as Agave: the same success or failure, the same changed accounts, and the same compute units left. That includes every fixture for the system program, compute budget, precompiles, ZK proofs and loaders v1/v2/v4. It's the same code that replays mainnet, and every memory access in it is proven safe by Lean's kernel. The fixtures also caught three gaps in our model, now fixed: • lamport overflow past 64 bits • Agave's general rent formula • little-endian alt_bn128 compression None of them could change a mainnet block, but a trusted model should match Agave exactly. The remaining 262 differences are listed in the README and are being worked right now. github.com/MidTermDev/leanCl…
6
12
3
53
8,606
A Solana client written in Lean. 160,000+ mainnet blocks in a row, every bank hash matching. Every array access proven safe by Lean's kernel. No runtime bounds checks. And every optimization from here has to pass the proofs first.
10
14
3
86
13,386
Every time we optimize the loop, the validator(s) benefit. Benchmark tests are being taken at the end of each optimization + proofs generated.
3
2
1
26
1,528
Alessandro and toly were right: the slowdown was block verification, not the JIT. Fixed: the Lean client now checks signatures and proof of history as each block's shreds arrive, not after the last one. That cut 60–110 ms per block to under 1 ms. Same results on 800 mainnet blocks, and every bank hash still matches. Next up: execution. leanclient.app
.@MidTermDev literally tell the clanker that Alessandro from anza said it’s slow at block verification and it’s not the jit.
18
7
1
62
11,493
Ecosystem integrations are underway! Thank you, Sidoor!
Sidoor × @LeanClient 🚪 Sidoor is the first launchpad to integrate Lean AMM. The integration is now live across both the Sidoor Launchpad and Sidoor Terminal.
7
16
3
82
5,000
Upon integration of this concept, the official Lean Client Validator has reached 685 SOL staked.
I'm considering a somewhat uncharted path to making @LeanClient profitable as a new Solana validator. I'm extremely thankful that fees from our native token have covered our operating costs thus far, but I want to build something that generates genuine, sustainable value. The idea is simple: Introduce a liquid staking token (lSOL) backed by SOL staked with the Lean validator, and use it as the default quote token for launches on our 0% fee AMM. The AMM will remain permissionless and open to any quote token, but we'll encourage lSOL within our own launchpad to support a non-extractive trading ecosystem. At a 5% validator commission, we estimate needing roughly 60,000 SOL in active stake to break even on operations. Instead of extracting fees from every trade, we sustain operations through validator revenue. Users retain their staking yield through lSOL, which appreciates against SOL as staking rewards accumulate, while remaining freely tradable and redeemable for SOL. The more liquidity our ecosystem attracts, the more stake we can bring to our validator. A profitable validator, a sustainable 0% fee exchange, and an ecosystem that gives value back to its users. I think there's something worth exploring here.
4
7
4
54
10,788
Our approach to gaining stake in our validator starts here. Bootstrap stake by offering the best value of any AMM.
Just staked 200 SOL to our @LeanClient validator and added an additional 200 sol in SOL/lSol pool on Lean AMM. This will ensure liquid payouts for sol and more people can add SOL to the pool allowing people toget around the 1 epoch delay in unstaking. Lean Client, WGMI
5
6
54
2,768
Token launches are now supported on Lean AMM. 0% fees. Everything belongs to the traders. Paired to lSol (Lean Liquid Staked Solana). Launches begin at $5,000 market cap with 62% sold by $35k mcap. amm.leanclient.app/#launch
15
15
8
75
9,276
Live now: wall-clock ns per compute unit for every Solana program, measured by our Lean client executing mainnet, plus hot vs cold time and sorting. leanclient.app/programs
Can it collect counters on what programs it spends the most time in? Hot and cold and just push them to your site. I can pull and have it optimize in a loop
6
9
2
61
3,925
Lean Client, our Solana validator written in Lean, has been voting on mainnet since Dec 1. As of Dec 2, it now follows the full Alpenglow voting rules. Its voting code also comes with machine-checked proofs: it can never cast conflicting votes, it votes in every slot on time, and peers can't flood it. Lean checks the proofs on every push. github.com/MidTermDev/lean-S…
20
20
5
97
24,248
Lean AMM is a 0 fee open-source dex AMM written in Lean. As the cost of code rapidly approaches 0, the only thing left is trust. With lean, we can prove our claims. This promotes a "Golden Age" of defi as we promote quality, machine proven code without the extraction
5
19
6
92
7,785
All launchpads surrounding Lean AMM are currently third party. Lean progam upgradability is still held within our team and will not be revoked until we are satisfied with the full product suite. Thank you everyone for your interest. We will be working hard to continue shipping.
2
2
23
2,934
Lean AMM - a 0% fee dex program, written in Lean, has just surpassed 100 SOL in TVL. More features coming soon for Lean AMM amm.leanclient.app
6
8
3
78
8,056
What started as an experiment in writing a Solana validator entirely in Lean has turned into a 31,000-line independent client, built with its own compiler. Hundreds of thousands of blocks executed. Zero bank hash mismatches. We're now executing heavy mainnet blocks in as little as 162ms on average in benchmarks, with votes reaching over 96% of validators. There's still plenty to optimize, but it's pretty cool to see how far this experiment has come.
9
11
5
101
32,815
Welcome to mainnet, Lean Client Validator #001 Please enjoy your stay. Fees will be directed to keeping vote account funded and increase the stake on this validator. Future developments for Lean are underway 👀
2
8
38
2,994
Our validator has reached voting status! Actual vote TX's should appear within a few hours as we clear our ~33k slot backlog post-update. Watch live: leanclient.app/#node
8
10
6
71
15,479
Lean Client update. Our mainnet node now produces blocks, earns leader rewards, and executes transactions in parallel. Wallets and RPCs can send transactions straight to the node over QUIC; mainnet gossip lists it as a TPU. Before a transaction goes into a block, the leader checks everything that would get the block rejected: parsing, signatures, repeats, whether the fee payer can pay, and the block's cost limits. Blocks fill highest fee first, using the same formula Agave uses, and go out over turbine in batches while the slot is still running. We rebuilt 134 mainnet blocks this way. All were valid, and every bank hash matched the footer. Footers now carry reward certificates, which is how a leader gets paid half of what voters earn. We build them from real votes our node hears, about 112 validators per slot so far. Our checker also accepts every reward certificate Agave leaders put in 134 real mainnet footers. Transactions now run on multiple cores. Each one starts as soon as the transactions it depends on finish, and the bank hash comes out identical to running them one at a time. Over 1,700 mainnet blocks on 8 workers, every bank hash matched, at 122ms a block versus about 180ms single threaded. That's 1.45x faster. The live node runs this way now. Next is building on whichever parent the votes settle on, and moving more of each block onto the workers. All Lean, compiled by our own compiler. leanclient.app
26
9
8
80
9,332
12% fewer CPU cycles per mainnet block. Lean Client now compiles Solana programs lazily: each block of a program becomes machine code the first time it runs, and code that never runs is never compiled. Live on our mainnet node, every bank hash matching the network.
15
12
3
69
14,695
Compilation. Solana programs are bytecode. We now translate each block of a program to x86 the first time it executes and link blocks directly once both exist, so code that never runs is never compiled. The design follows @toly's lean-svm-jit, rewritten in Lean. Feature gates. New Solana behavior ships behind switches that turn on at epoch boundaries. The client now reads each switch from its on-chain account and activates it exactly as Agave does, so upgrades it already supports take effect on schedule, without a new release. Network duties. Validators pass each block's shreds down a relay tree and fill each other's gaps through repair. Our node now answers repair requests from the blocks it has verified, over 2,000 in its first minutes, and computes its place in the tree exactly as Agave does. Account lookups now compare the first 8 bytes of a key before all 32, and duplicate checks run once per call instead of three times. That alone is 12% fewer instructions per block. All of this is live on our mainnet node. github.com/MidTermDev/lean-S…
3
2
17
2,473