Part 1 Title: The Predictable Machine
There was a rhythm to it. A cadence that became muscle memory.
Mornings began the same way coffee in hand, terminal open, models humming quietly in the background. Screens of structured inputs, clean outputs, and low-latency logs. I worked as a quant researcher and developer at an event-driven hedge fund, and the job was exactly what it promised to be: intellectually demanding, obsessively precise, and almost never surprising.
You built signals. You tested them. You deployed them into production pipelines that were already optimized to an inch of their lives. You watched the PnL curve smooth out over time, dipped a toe into some novel factor here or there, then circled back to iterate. The market reacted. The model adjusted. We beat it, a little more each quarter.
The strategy was solid. The code was efficient. The work was clean.
That’s not a complaint, it's what most people dream of. A job that pays well, doesn’t ask for your soul, and makes you feel smart every day. There were worse ways to spend a career than writing code that beat the market. I knew that.
But still, the feeling crept in. The sense that we were building something exquisitely engineered… and fundamentally empty.
The models worked but for who? We weren’t building a product. We weren’t building anything, really. Not in the sense of shipping or ownership or consequence. The code never touched a user. The algorithms didn’t help anyone. It was just a performance, piped to a silent set of LPs who never asked questions so long as the returns were green.
No one told me to care. And for a while, I didn’t.
But there was a moment, maybe a specific day, maybe a slow accumulation of them, where I looked at the screen and felt like a ghost inside a very elegant shell. All signals, no voice.
And worse: I was bored. Not because it was easy. But because it was predictable.
I didn’t know what came next. But I knew it wouldn’t come from another feature-neutral merger arb signal.
Part 2 Title: The Cracks in the Frame
The feeling didn’t arrive all at once.
It started quietly, like a thread pulled loose from the corner of a tightly tailored suit. You keep wearing it, knowing the seams still hold. But once you notice the thread, you can’t unsee it.
For me, it was a string of weeks where I caught myself dragging my feet on problems I used to chew through without pause. Model debugging that once felt like chess now felt like a loop. Research cycles blurred together. Even success , which we measured in decimal improvements, felt... procedural. We hit our targets, and no one flinched. I flinched.
I remember a strategy review meeting, one of those polite, softly competitive sessions where everyone arrives with their own version of “here’s what’s working, and here’s why it’s smart.” The PM nodded through it, satisfied. But as I walked back to my desk, I thought: None of this really matters.
Not in the grand sense, but even in the narrow sense of creative satisfaction. The ideas were clever, but bounded. The goals were surgical. The strategy didn’t want revolution; it wanted repeatability. That was the job: optimize the machine, don’t question the factory.
But the questions started to surface anyway.
Why do we build these signals in secret? Why do the best ideas get siloed, buried in proprietary code that no one will ever see? What would it mean to build something where the logic was transparent, or even forkable?
That last word stayed with me longer than I expected. Forkable. Like in open source software. Or protocols. Or blockchains.
Somewhere along the way, I stumbled into that world. Crypto. At first as a tourist , a listener. I followed a few threads on Twitter. Read a couple of whitepapers. Laughed at the memes. Scoffed at the scams. But I kept reading.
There was something in it. Something chaotic, unpolished, overconfident , and weirdly sincere. People weren’t just optimizing spreads. They were rebuilding the plumbing. Token by token. Protocol by protocol.
That’s when the crack turned into a fracture.
Not because I thought crypto had all the answers , but because I was finally ready to ask better questions.
Part 3 Title: Glimpses of Something Else
It started the way a lot of obsessions do now, through a thread.
Someone I followed, maybe a former quant, maybe just someone with the right mixture of sarcasm and insight, posted a long breakdown on MEV. I had no idea what it stood for. But the thread was sharp, full of links, diagrams, even a few screenshots of Etherscan transactions that looked like digital hieroglyphics.
I read it twice. I still didn’t fully get it. But it had the tone of someone explaining not just a new problem, but a new system.
And that was the hook. Not the coin prices. Not the bull markets. Not even the tech. It was the sense that, in this parallel corner of the internet, people were trying to rebuild the fundamental architecture of finance, sometimes badly, sometimes brilliantly, but always in public.
So I lurked.
Podcasts on the walk to work. Discords after hours. GitHub repos I couldn’t yet decipher but bookmarked anyway. It was loud, tribal, manic, borderline unhinged at times, but buried in the noise were people building with an energy that felt... unlocked.
In TradFi, the smartest people I knew were guarded. You’d never explain your alpha unless you had to, and even then, only in riddles. In crypto, people dropped 15-tweet explainers on strategies they hadn’t even launched yet. It wasn’t just open-source code, it was open-source ambition.
I was skeptical, of course. Every instinct from finance told me this was a honeypot of hype and half-baked ideas. But there were exceptions. People who thought in primitives. Protocol founders who didn’t speak in slogans. Engineers who wrote smart contracts with the same elegance I once saw in high-frequency execution engines.
And even when I didn’t understand what I was reading, I couldn’t help but admire the velocity. Products launched in weeks. Governance proposals shipped mid-thread. Token models debated live. Everything was moving too fast , and that was kind of the point.
Crypto didn’t have all the answers. But it was asking questions my world had stopped asking.
Part 4 Title: A Problem Worth Solving
Joining @buttonxyz didn’t feel like joining a company. It felt like being handed a blueprint and asked, “Can you make this real?”
There was no product to debug. No legacy codebase to inherit. Just a direction, an ambitious one, and the expectation that I could help bring it to life. I came in as the founding quant engineer, and my first task set the tone for everything that followed: design and build the dynamic rebalancing logic for our core basis trade strategy on Hyperliquid.
It wasn’t about tweaking something that already worked. It was about creating the system from scratch , backtests, logic, assumptions, safeguards, everything.
There’s a version of the basis trade that looks clean in a doc or a thread: short perps with high funding, long BTC spot, harvest yield, stay neutral. That version is technically correct — and functionally useless.
Because the moment you try to automate it, everything breaks unless you can rebalance intelligently.
That was my first job at @buttonxyz — build the engine for a fully on-chain basis strategy. Not in theory. Not in a notebook. But as code that could run, optimize, and survive on a real exchange: Hyperliquid.
There wasn’t a strategy waiting to be tweaked. There was nothing. We had to build the whole pipeline: from execution layer to position logic to the dynamic rebalancing core — the part that decides when and how to adjust the hedge as market conditions shift.
That’s where it got hard.
A rebalancing problem disguised as a trading problem
@buttonxyz's idea was simple: let users deposit BTC, and use that BTC as margin to earn stable, uncorrelated yield via delta-neutral funding trades. But to do that, the system has to stay hedged.
And staying hedged in crypto isn’t easy.
The perp and spot legs constantly move out of alignment. Volatility increases variance in the hedge ratio. Fees, slippage, and adverse selection make every rebalance costly. So... when exactly should the strategy adjust?
Rebalancing every time the hedge ratio drifts would be death by a thousand fees.
So we had to build a smarter logic — a bandwidth around 1.0 (the ideal hedge ratio) that only triggers a rebalance when the drift is dangerous relative to expected cost. That’s where the Optimal Rebalance model came in.
We turned to this logic: Rebalance when hazard > cost
- The hazard: liquidation risk, funding loss, hedge drift
- The cost: execution slippage, taker fees, opportunity cost
The strategy uses a volatility-sensitive formula to define a “safe zone” or no-trade band. When the hedge ratio stays within the band — do nothing. But when it drifts too far (due to volatility, margin change, or position decay), it triggers a rebalance.
But in practice, computing those terms involved layers of modeling:
- Drift penalty from EWMA of historical volatility
- Liquidation risk based on leverage + margin buffers
- Cost estimates from slippage curves and fee ladders
And all of that needed to be optimized — enter Optuna.
We built a full optimization pipeline
I used Optuna to run hyperparameter sweeps over key risk and execution parameters:
- lambda: risk aversion coefficient
- alpha: volatility decay speed
- eta: slippage penalty
- taker_weight: execution profile (favoring maker orders)
Each parameter shifted how aggressive or conservative the rebalance logic behaved. Too aggressive? Costs exploded. Too slow? Hedge drifted dangerously. The goal was to find the sweet spot — enough protection without overtrading.We simulated strategies under hundreds of market conditions — bull chop, bear bleed, sideways volatility. The model had to adapt without overfitting.
The result wasn’t perfect — but it was real
We ended up with a live simulation engine that could:
- Accept BTC capital
- Short perp with precise sizing
- Estimate hazard in real-time
- Rebalance only when it made sense
- Track every decision transparently, ready for on-chain auditability
It wasn’t just backtestable — it was composable. A real, modular piece of DeFi infrastructure that could scale.
I’d spent years building models that no one outside our firm ever saw.
Now I was writing one where every rebalance would be visible — in smart contracts, with collateral at stake.

.jpg)
