-
Notifications
You must be signed in to change notification settings - Fork 306
💱 Interleaving the SDEX & AMMs #1558
Replies: 1 comment · 1 reply
-
I think Interleaving the SDEX with AMM will decrease performance. I'd imagine that this would make the path finding algorithm more complex. |
Beta Was this translation helpful? Give feedback.
All reactions
-
Hi @rahimklaber, Thank you for your thoughts, both here and shared on Discord. It was inspiring to hear via DMs how you got into the network, largely for humanitarian, real-world use cases. Over the years, I've found this to be a common thread linking us together. In an effort to further these foundational principles that uniquely belong to the network, might I quickly review my own understanding of these ethos? Chiefly, I understand that the founders wanted a decentralized payments network that was cheap, fast, and inclusive, based on personal identity, not computing power. We seem uniquely adept at providing such a system given the lethargy, centralization, and gatekeeping present in other financial systems. I'm writing this as someone who just wants the most efficient technology possible under our stewardship because I've felt so keenly the vast inadequacies of legacy markets for practically my whole life. They have ripped apart my family, taken nearly every drop of opportunity I've identified right out of my hands, and pulverized my aspirations as a mainstream asset manager.1 There is nothing I want more than for the network to succeed, and I believe wholeheartedly that we will triumph enormously over other technologies given the proper execution of scalable, decentralized, egalitarian markets. 1. Extensive Recent Community ActionsSince this post, quite the collective discussion has popped up on the subject. Perhaps most relevantly, you were rightly given accolades for uncovering the deadly bug.2 🎖️ The context under which this occurred is materially-relevant to the rest of this discussion, so I will link it here: Also, we wouldn't have heard live about your expert white-hatting if it weren't for Jayrome, who kindly reached out to community members to solicit AMA questions before the event. Jayrome relentlessly contributes their time, expertise, and consideration through open discussions, prudent facilitation, and news aggregation. They did an unbelievably tremendous job asking with relevant tone-setting context from 2022, genuine tact for differing perspectives, and an open mind toward possible solutions. I believe so earnestly that these open communal discussions are the secret instrument we can leverage to overtake entrenched incumbent interests. Indeed, might the optimal solution for these network-wide quandaries come from the artful, attributable, and permissionless Discussions we've already seen lead to stellar outcomes in CAPs 51, 53, and 56? 1.1 Previous Functional Mobile AdvancementsBefore diving into the nuances, I'd like to applaud your longstanding efforts to bridge different platforms to Stellar with a single SDK. 👏 Too often, work might not see the light of mainnet despite the material efforts behind its development. But many of our long-term challenges can be overcome seamlessly thanks to those key thoughts, incremental improvements, and persistent bug fixes. As I've tried to express, I might not be intimately familiar with the particular nuances of JS/Native/JVM implementations and their core XDR (not Horizon)—just yet at least. But it's clear to see that you're making ongoing progress on what just might be the next big community project. And it's quite inspirational for me, at least, to think that you're able to do all that on top of traditional work. But I do know markets, and I've seen so clearly today's central intermediaries exposed to hacks as intricate as your bug.3 This is why your work can make such a comprehensive difference, empowering users with a direct DEX wallet in the palm of their hand. Might we one day finally escape the totalitarian controls choking present financial systems' global liquidity?4 1.2 Introducing Communal Discussion and QuotesUnfortunately, much of this thinking work can get lost in the fast pace of release schedules. In the spirit of documenting AMM design choices,5 I'll append some discussions from the Stellar Global Discord. Namely, most of these messages stem from shared concerns over a network participant's transparency, integrity, and liquidity governance influence. 1.2.1 Adam: Trading Execution Materiality
1.2.2 @ddombrowsky: Order Book Independence
1.2.3 Active Competative Differentiation Work
1.3 Appreciated Thought-Provoking PerspectiveAgain, I'll call into light your stellar past technical work expanding the ecosystem's toolkit. I'm continually impressed by both your comprehensiveness and deployment skills, whether it's expanding on trailblazing contract streaming or creating a brand new account servicing project complete with its own permissionless documentation. And to think much work here started just four short years ago with an intuitive tokenization offering—just incredible, Rahim. 👏🏽 Given this deep technical background, I'm all the more impressed by your continuous community outreach. Not only have you found bugs such as your community contribution here, but you are also constantly in contact with developers and users alike to address concerns! Having recently discovered the thread myself, it was awakening to read your conversation with Adam about recent flaws in another Soroban AMM that centralized control of deposited liquidity into a select few hands. Especially on other chains, some industry participants prioritize crafting a good story to sell to investors for some easy initial funding. 📊 When these developments lead to material losses in freedom, security, and money for users like us, it's both refreshing and uplifting to know that your skills serve to defend the peoples' interests. We're all just trying to make this work as we go along, and your behind-the-scenes passion energizes! ⚡️ 2. Enabling Trusted Global LiquidityPart of Stellar I find so incredible is the heavy lifting done by community validators behind the scenes. The diligent and selfless contributions bring accessible transactions to all. In this light, I originally wanted to have our own nodes spun up to try testing for the simulated ongoing execution burdens. Part of the reason for this logic is that I don't want to sit here asking for something for nothing. Namely, I'm only a motherboard, CPU, and NVMe drive away from getting things spun up.6 But that's presently outside my scope of operational capabilities across organizations per survivability constraints supra note 1. That said, can we all agree that the contemplation given to my beliefs ought to be weighed independently of my present socioeconomic standing? As I've tried to shortly capture, the beauty of the network really shines when it shares the best industry tech with all classes of society. Could introducing "loyalty tiers," as is so common on central exchanges, run counter to the ethos that genius can come from anyone? 2.1 Enduring Network Design PerspectivesExpanding on the chief question asked in the video from Meridian,7 might we take a holistic consideration as to the cost of liquidity as it stands today? As voluminous comments in the singular conversation forum so far have revealed, liquidity is a key aspect of the network for users, developers, and advocates together. Reflecting on the asked investment of time, energy, and composability into interleaving liquidity, might we consider the sum network benefits? Markedly, the choices we make around items like whether or not contracts call the DEX have significant downstream effects on whether the network runs well for users like us or the centralized institutions presently so dominant across other chains. I like to think there's a reason the large majority of demonstrably-compliant web3 investment products employ the network (or at least originally launched here). All this despite the current lack of attention on self-custody options available to all.8 Might the self-custody implication inherent in existing exchange business models draw attention away from the DEX?9 This might lead to a number of quandaries that came up in this discussion, such as trading volume compared to proprietary venues, AMMs, and HFTs.10 I believe wholeheartedly in our unique opportunity to collaboratively explore the most efficient globalized solution that satisfies the longstanding needs of traders, developers, and innovators.11 2.1.1 @jedmccaleb: Blockchain Liquidity InnovatorMight we emphasize Jed's brief remarks on the panel given their precedential history in markets, as shown by being one of three current footnotes in the Wikipedia page for order books? The particular footnote posits that Jed was the first person to develop an order book link plot showcasing market supply and demand, back when it was just them working alone on Gox. When asked about their view from two years ago that "people love the DEX," Jed optimistically referenced the evolution of the DEX, telling Jayrome:
Can we agree that this steadfast commitment to form refreshingly positions the network in an industry where some leaders are so improperly influenced by Wall Street? Namely, might we best align with our mission to better humanity through the nonprofit nature of SCP combined with the decentralized governance it implies? While alternative systems serve to enrich a select few, might we objectively ask what could best serve users, absent external business interests? To bring this point to light, I recently executed an offer to buy an asset from an issuer I like. However, a majority of the liquidity for this asset lives in Soroban AMM contracts, so I learned after later consultation. Might we jointly develop a scaling solution that doesn't incur at least 80% slippage? 2.1.2 @tomerweller: Seeking Efficient ReplacementTomer seems equally hopeful for a network with more liquidity, trading, and access.12 My understanding of their perspective so far is a focus on composability between protocols built on top of the network. In the discussion, Tomer said they didn't yet have much "to add on top of what was said" at Meridian.13 I sincerely appreciate Tomer's experienced, meticulous, and transformative work throughout the ecosystem. That said, might we bound ourselves for material compliance violations using the two alternative options they propose, based on Soroban and presently in the incubatory stages of development?14 We're all for a new visionary, collaborative, and dynamic system; by my understanding—building on the same team. But the core function of asset exchange implicates not only regulatory security but also practical custody risks which the previous surprise update acutely brought to light. Combined with the recent hikes in AMM "listing fees," might we contemplate further which path could best grow the network? Fees which, I feel obliged to remind everyone, are paid in speculative tokens for the vast majority of present implementations.15 2.1.3 @rice2000: Community Collaboration FocusFrom the original 2022 panel to today, Justin has stood firm as a neutral arbiter between Jed and Tomer's viewpoints.16 It doesn't seem like Justin explicitly prefers any one route, based on limited in-person conversations, historic public info, and recent statements. These sentiments were also true by my interpretation of the 2021 Open Protocol Meeting adopting native AMMs. In conversation with the community projects Justin highlighted on Reddit, developers believe trading needs to be the first Soroban use case because you can't call the DEX from contracts yet. But, as discussed, we can transform the DEX together to deploy infrastructure that doesn't overly burden a central point of failure. Indeed, Justin seemed to lightly nod when Tomer voiced that "another option" is "people like Garand" prototyping evolved order books implementing SPEEDEX. Might we continue supporting parallelization, decentralization, and concurrent trade execution to "prevent liquidity fragmentation and arbitrage?" Garand is only one of many SDF members who's voiced such concerns over needless extractive arbitrage.17 After a crowd survey, Justin responded in 2022 with their thoughts on the most efficient path forward:
3. Smart Contract Trading SystemsAs I've communicated with Tomer and ecosystem participants at large, might we design the evolution of the DEX using a "regulation-aware development strategy" (from Sec 3)? Compliance work takes many years of solid foundations, which Block Transfer has previously found in the steadfast, utilitarian, and resourceful network. Might we continue expanding on substantial past efforts to implement multithreaded batch trade execution? As we will see in the next three subsections, the argument here is materially related to the never-ending debate of centralization vs. decentralization. But when applied to liquidity itself, we need a forcing function to an agreed-upon standard not dissimilar to the GPL. The chief difference between traditional "distribute wealth and power" arguments and fundamental markets is that anything other than a single venue enables wasteful arbitrage.18 In examining this question, I will present three common systems employed across lesser chains. These are the sort of arguments I can't really make in a formal filing given their derogatory nature, so I appreciate this opportunity to expand on these thoughts in a meaningful way outside of litigation. 💜 Could you consider reading these sections as if you were the new Chair of the SEC? 3.1 Off-Chain Order Book SystemsOur community cares greatly about order books because, as "inefficient" as they might be in data-structure analysis, they form the basis of an efficient market. There is no global financial system when each and every transaction relies on the goodwill of a select few.19 Indeed, might the democratic, egalitarian, and accessible provision of liquidity best serve an increasingly decentralized society? I've believed in the DEX since the moment I understood SCP, this video, and Wall Street's exclusive club.20 And I believe with every ounce of my being that we're dooming future generations to continued exploitation by these bastardizing central planners if we fail to protect the last bastion of a free market present in the network. Here and now is our opportunity to fulfill Nakamoto's vision for a disintermediated base financial infrastructure, capable of the globe's payments, trades, and balances—not a select few. We have an unbelieve community of active builders striving for so much more than another venue, as shown in our discssion about how we can build real products not just for finance. As I explain the centralization t ocome, might we remember so muc hof the founding and core teams' vision for a network serving the masses of tommorw, a vision exceptionally executed across the protocol? ight we continue deplyoing the freest market possibly ever created to defeat the unproductive net social expense of off-DEX arbitrage? 3.1.1 Unspoken, Silent Centralization IncentivesPictured is an image from the present homepage of ZeroEx Holdings, Inc.; better known as 0x. Here are their regulatory filings disclosing material venture investing for every year in the first three years of its existence. These filings detail how this corporation sold at least $84,121,200 to a paltry 45 investors at minimum, a significant sum of money that undemocratically shifts the power from Uniswap users to the corporation behind its development.21 The public fee schedules available from 0x22 reveal take rates starting at 0.15%—conservatively.23 These are not expenses passed on to a decentralized group of liquidity providers. And they are not safeguarding fees built around investor protections of regulatory frameworks in toto. These are economic rents siphoned off to a select few groups of early investors who were lucky enough to capture the immense value of liquidity singularities. And it is precisely this centralization that allows them to force transactions through the complex intermediated frameworks necessary to most efficiently transact on their system. Should we really let our freedoms, governance, and oversight stay in the manipulative hands of these centrally-controlled middlemen? 3.1.2 Unspeakably-Efficient Path HandlingNo matter how you slice and dice your interpretation, Rust in the execution environment will never operate as fast as validators' C++ logic. This presently enables the unbelievable efficiencies of 6-hop order routing without a central party. Might this unique differentiation of the DEX best allow us to compete with monopolistic, entrenched, and stagnant incumbents' domineering grasp on global financial liquidity?24 I will go on to compare this opportunity with the present system which continually faces material regulatory scrutiny. Might the only way to maximize capital formation, efficient markets, and investor protections be to design a system which fundamentally disallows centralized censorship of specific items deemed inappropriate in the legacy regulatory context? This idealistic future, originated in the founding vision of Stellar, exists only in a distributed trade execution environment. The only way to mimic this efficiency in the status quo is to consolidate all recordkeeping into a single entity. This powerful overlord can thus know all information, theoretically offering the most efficient system. But we've seen this gatekeeping develop firsthand through the monopolization clearly present in America's DTCC, and it's not pretty. 3.1.3 We Are Not RippleIn the BFT world, benevolent dictators unilaterally decide exactly who starts off with power. And in a mathematical system as complex as the market, these initialization conditions have profound long-term implications. Might we step back and ask ourselves if it's worth deviating from the ingenious course we've been charting together for over a decade? Should we burden the network with spam due to "someone who happens to be running a bot against some Soroban pool somewhere," as aLatvian said? Or should we protect our existing implementation in Stellar Core, obviating the needless localization of functionality as basic as cross-border exchanging payments? Perhaps create a just society where we might share the natural abundance afforded by liquid markets and their implications? There's a reason "ALL other chains" face the material operational limitations presently un-afflicting the DEX.25 Should any meaningful volume shift hands into Soroban venues, we risk seeing the network's good name getting smeared in the legal ambiguity of a Wells notice.26 Is this the fate Jed envisioned when they wrote:
3.2 ZK Scaling and RollupsMy original implementation of a stock market was designed to scale with optimistic rollups, as they're an easy answer to the scaling question plaguing less efficient blockchains. Another option, zero-knowledge proofs, offer similar promises. Admittedly, this is not my area of expertise by any means. But I know markets, and the fundamental problem we ran into with these systems is that they require an order book which lives somewhere other than on-chain. The latter case often requires contracts to both simplify and propagate complex off-chain math. These abstractions create the unholy mess of a market present in the U.S.27 The power of longstanding Rust contracts is undeniable, per Garand's sentiments. We're at the start of an unparalleled journey to build an innovative financial system that actually serves the needs of its users, not its executives. Might we move past the elementary applications so common on other chains which we have already efficiently solved using validator-level logic? 3.3 "UniV4-Style" Future Development PitfallsThroughout the conversations, we've all generally agreed that "the SDEX order books are still more advanced than any set of order books on any chain." Indeed, in my view, Uniswap V4 is just a mechanism to cope with the reality that other chains are not efficient enough to offer limit orders, falling back to the systemic risks of central netting. Markets are not continuous functions like an AMM pricing curve. They do not follow your rules no matter how many times you run them through a Monte Carlo simulation.28 As I presently understand these V4 contracts, they attempt unsuccessfully to tame the exposure participants face as the market moves against them, a natural uncertainty in the business of making a market for a spread. The further down this path of control you center, the closer you get to today's market infrastructure. Pamphile explained the material challenges exceptionally when they wrote, "it's bloated, slow, old and everything."29 Can we really centrally control something as complex as markets themselves? 3.3.1 Constitutional Corporate Overlord, InvestorsAs is made abundantly clear in this response to their SEC investigation, Uniswap "Labs" is a for-profit C corporation with "leading U.S. institutional investors, such as Paradigm, Andreessen Horowitz, and Union Square Ventures" and "more than 100 employees."30 This document also highlights that the enterprise has kept its algorithms under the oppressive protection of rent-seeking software licenses. I am in no way whatsoever implying that similar business practices might emerge over the years from existing network participants. But even if the ecosystem's Soroban developers adhere strictly to the nonprofit principles embedded in SCP, they'll still be targets for regulatory action the moment they touch absolutely anything we're building at Block Transfer. It was also discussed that the SDF could deploy "definitive" Soroban AMMs to centralize liquidity, but this would very unambiguously place the Foundation in the crosshairs of similar threats.31 ⚖️ The stakeholders in today's systems are and have always been investors and issuers. Might any other party involved in the exchange process exclusively serve to siphon value away from those two groups? Should we defend the DEX as the last bastion of a free financial market? 3.3.2 Unacceptable, Unaccountable Execution CentralizationAlong the path of centralization, incumbents try to sell "faster access" as a "trading benefit" to investors. However, if we're truly designing a global (and ultimately interplanetary) financial system, at some point we're going to run up against round-trip propagation time of digital signals.32 This is exactly what Uniswap Labs' latest "invention" has introduced through the Unichain POC.33 I say "invention" because absolutely nothing here is new. I could sit down and list dozens of regulatory filings which detail these exact exchange changes across the American securities landscape. The points at which certificates, settlement, and reporting became centralized come to mind—leading to the ultimate endgame of massive profits paying out to Silicon Valley over Main Street.34 Given America has the world's most advanced, developed, and liquid market for capital, might we learn from the pitfalls of Wall Street? If we can right their wrongs, perhaps we can free ourselves from the shackles of a select few financial intermediaries. Shackles which have so poignantly determined entire directions of progressing nations. 🕌 3.3.3 Requisite Insurance for AdoptionI've spent the past four years talking to just about every anchor, trader, and regulator I know about blockchain. Following the prior logic, institutional adoption of actual trading on a self-custody basis requires gargantuan insurance products when using bootstrapped smart contracts, which we very clearly see pose hazards per your work. Could trading be the most important aspect of a financial system that we are presently left to master?35 Everyone generally wants to move fast when it comes to launching into a sustainable business state—completely understandable.37 But might it be prudent to slow down and build something longstanding to serve generations of users to come? At Meridian, Tomer posited that:38
While we in the DRS community appreciate that there will be bugs in any computer systems, we'd prefer our funds not be at risk in flash crashes perpetuated by complex trading infrastructure. 🫤 Would it be best to strictly apply an unwavering software mindset to something as important as markets? Or might we conceivably best serve the plausible needs of our expanding ecosystem through a feasible uniform front?39 4. Legal, Composable, Community SolutionSince understanding its deep humanitarian implications, I've bet my entire career that SPEEDEX works, and that it works stellar. Without true offers on the DEX, I see no future using today's technology in which I'd like a stake in this industry.40 Do you think Wall Street's time is up, as do the thousands of members in our grassroots community afflicted by their unadulterated theft? ⌛️ Markets have proved time and time again the immense necessity of limit orders as the base building blocks of liquidity for the tens of thousands of long-tail assets issued on the network. The proven DEX is anything but the black box pictured above, which is explicitly not the case for smart contracts, aggregators, and frontends.41 Might a tenable investment in efficient markets today serve the network's issuers for all eternity? Could a truly nonprofit financial system built for its users minimize rents, as discussed? Or, as in the immediately succeeding message, will we continue to be handcuffed to titanic arbitrary capital requirements to bootstrap liquidity?42 Should the most performant trading system really frequently require at least three operations to min/max the pathfinding algorithm? It might be hard for technical people like us to see some of the incredible implications of a 50 bps spread reduction.43 But these innovations truly change people's lives—I've seen, felt, and shared it firsthand. In an increasingly abundant society in raw compute terms, might we best empower all network users with tooling that places the locus of economic control squarely in their hands?44 🤳🏼 Footnotes
|
Beta Was this translation helpful? Give feedback.
-
This discussion extends decentralization points made in note 2.1.1, SCP#25, and Cede timeframe. Its principles favor efficiency over incumbent business models employed by community members that have directly helped me over the years. Sorry about that, but keep innovating because you all are incredible people! 🤝
The inspiration for this post came from @earrietadev's @FxDAO community.1 Last week, Soroban AMM troubles emerged after a contract upgrade running the platform's only liquidity pool.2 This stopped users from withdrawing their funds and placed all deposits at risk.3 😐
The nuances of these developments are still very new to society at large, likely because so few presently understand the immense centralization of risk in the trading markets. It's my understanding that this is why DEX aggregation hasn't been widely discussed across the industry; it's clearly no fault of any Stellar developers. That said, it drives directly into one of our shared objectives:
This post explains that perspective as clearly as I can with five days to write it. Ideally, it's the start of a wider conversation, as there is certainly nothing I can do to stop you from deploying anything you want on Soroban. It's part of the endless debate of decentralization quandaries that I believe SCP so eloquently balances. 🧠
1. Accessible Education Breakthroughs
Speaking of Soroban news, I'd like to highlight @SirTyson for his outstanding recent informational videos.4 It's rare to find a developer of such high caliber as Garand who can also explain their work in plain English. This ongoing treat stands strongly as a magnet for new users discovering the network.5 🧲
6
Garand's sentiments in this short release captured the wide array of applications we can build:
These groundbreaking applications can be so much more than another trading avenue. Per Sec 3.3, these new applications can tie directly into egalitarian engineering sentiments. Hopefully, we can get more industry understanding around the stellar work Garand and the rest of the network's contributors have recently pioneered. 🌐
1.1 Latency Sensitive Background
As he's publicly communicated, Garand is a huge security nerd (oversimplified). I don't want to put any words in his mouth, but I will tell my recollection of the only conversation we've had as communicated in #1504. Namely, certain directive aspects of his work at a major hedge fund may seem "greedy", but I've done quite the same and materially respect him for it—this is just for context.
While Garand might simplify it down to "kernel hacking" on his LinkedIn, he was working on hardware-enabled high-frequency trading enabled by centralized exchanges. Namely, the technology he worked on let his employer make trades that they can't lose (or at least almost never lose). 🧐
These business models rely on the extremely convoluted market structure for American trading, which we will get into specifically in 2.2. I respectfully submit that we can further the network's goals by understanding lightly how this work allows for the kind of risk-free trading Garand saw at Coinbase.7 Given the fragmentation of today's liquid exchange venues, this latency is virtually impossible to remove.
1.2 A Fresh Start
But we have a unique opportunity with the SDEX to imagine how we might build markets as they should be rather than as they have been. While most of the network's liquidity today revolves around a few trading pairs, it may just power all the world's assets tomorrow. Given we're designing the network for the next billion lumenauts, might we briefly appreciate the extremely unique position of the SDEX?
If we agree that we want stocks and bonds on Stellar, then it's counterproductive to ignore American securities laws. Namely, it is our interpretation after extensive diligence that virtually all other "decentralized" exchange platforms can be classified under existing centralized exchange regulation.8 This opinion is not yet formalized, and the SEC does not have an explicit stance on DEXes outside of present enforcement actions, as I affirmed with two Commission staff on Monday.9
Based on the work everyone like Garand does to simplify and accurately explain Stellar, I wholeheartedly believe we can establish a universal set of network interoperability, reporting, and modification standards. Alongside the exceptional on-ramping and redemption flows we've built, might we focus also on the trading functionality so gravely needed for cross-currency remittances? Perhaps our long-term approach on this front can obviate the presently costly market access, interface, and reporting costs. 💼
2. Market Fragmentation
Hello, my name is John,10 and I am a little obsessed with order books. It all started as a small research idea while I worked and went to school.11 But over the years, it became something foundational to my life's purpose of building real savings and retirements for masses of people. 🤝
To understand my perspective, could I share with you a very brief overview of my trading journey? Namely, might I share with you why exactly the American stock market is broken? It's my opinion that the history buried here tells a compelling tale for controlled decentralization, as promoted by our network values.
Our discussion starts with understanding for-profit exchanges. Particularly, did you know that the U.S. has nearly 100 stock exchanges?12 These competitors each offer effectively the same order liquidity, but they continually undercut each other in fees or kickbacks.
2.1 Independent Autonomy
This plethora of trading venues, akin to different liquidity pools, presents a tangible difficulty for routing trades. In these last few weeks, we've already seen the emergence of multiple products that promise to capture the best exchange rate across native and Soroban liquidity pools.13 And these systems face fundamental rent-extraction incentives to skim off each trade.14
Might I ask: if the goal here is empowering anyone anywhere to invest in their future, should our underlying market tooling complicate trading for the sake of profits? I respectfully submit that smart contracts on other chains have had years to mature, but they still barely offer anything not present on the native chain or easily possible. While we are early in web3, we are not early in markets, which have naturally developed to serve a select few.15
Accordingly, might we look to the long-term implications of interleaving the SDEX with AMMs under the frame of how markets evolved and can now expand? I'm quite frightened by how other decentralized exchanges developed because they bring the same troubled past of siloed liquidity spread across disparate proprietary venues. In fact, some DEXes like dYdX have already started down the slippery slope of implementing maker-taker fees. 😨
2.2 A Liquidity Singularity
Once liquidity becomes diversely spread across the market, there is almost no way to "put the genie back in the bottle." Do you see any innovation surface across these contracts, or only isolated clubs? I started trading because I believed in the market as a path to a more abundant life, not a means to pay some broker huge fees. 💸
It seems the network aims for similar goals: empowering anyone to invest, transact, and capitalize on basic capitalistic financial infrastructure. I just don't want you or someone you care about to join the network only to instantly face a hidden tax on each operation because liquidity is not efficiently organized. Seven years ago, I quit my job to trade full-time, hoping to amass wealth through the investment vehicles touted by society, not to enrich a select few.
This is why I'm so concerned about the emergence of non-protocol DEXes across the industry, which naturally compete. In the spirit of open-source, might I suggest that the best approach follows the organic and necessary axiom that one source of liquidity lets us best match all orders between all parties fairly? In contrast, we can let new options compete for trading interest and follow the footsteps of Wall Street: 🏛
2.3 Requisite Routing Function
The red circle above is effectively what DEX aggregators do in the context of traditional centralized liquidity pools that are not central exchanges. This is what the Soroban AMMs are, paralleling "exchange ECNs" and "dark ATSs." Again, the problem here is that you have to compare between vast amounts of disparate liquidity pools for every transaction or get a worse price.
I've seen this happen across financial markets for years, and it always leads to a gatekeeping eventuality where only a select few middlemen can access the best pricing. 😞 From what I've seen on other chains, which looks remarkably similar to our trajectory, the exact same is slowly happening to web3. The immediate question for me is whether or not we should protect something so fundamental to human life like trade itself.
If we can agree that everyone should get the same best access to liquidity, then what do you think about unifying markets? Namely, might we focus on exchange, the essence of an efficient capitalist society? Should we leave something so fundamental to our advanced, developed, and practiced ideals of specialization up to the whims of a select few middlemen? 🎩
2.4 Price Competition
The founding document of the NYSE was a price-fixing agreement between Wall Street. Brokers pay backend fees like these to the plethora of middlemen in the present market system. Do you think extracting value through commissions like these via "smarter trade routing" should be enabled by the SDEX?
To answer this question in the narrow case of the SDEX, might we contemplate the history of traditional centralized financial markets? It's my interpretation of history that, in the long run, all intermediaries go bankrupt. Namely, the evolution of traditional liquidity routing presents a compelling case for the race to zero.
The parallel of displaced orders would be a UniswapV4-style Soroban order book, where you can pay kickbacks or direct bribes to fragment the market. The end result of these shenanigans is a plutocracy where governance can self-fulfill perpetual illiquidity across centralized matchmakers. Might we make investing most accessible and performant for real users instead of circular path payment bots, as insightfully predicted by @orbitlens infra note 18. 💡
2.5 Classic Operations
An efficient market to me means the most value possible given to all participants. If there's a
payment
taking place, it means the lowest requisite transaction cost. And if it's a digital marketplace of buyers and sellers, it means quite the same.A middleman, call them the New York Stock Exchange, charging an extra fee to "authorize" and effectuate a transaction? Well, that sounds like an antiquated business model to me. And indeed, at $90 billion dollars in value, these are profitable business models.
Do you think we should block masses of people in developing countries from investing? Transaction costs alone mean many never even have access to these markets in the first place—this is the promise the network offers to everyone. 🌍 Can't this goal be most efficiently reached with native operation performance?
2.6 Regulatory Compliance
Financial markets thrive because of liquidity, which we can most easily use when concentrated in the hands of the people. It's the grease in the wheels empowering a global payment system, which is why I believe we must protect it from middlemen at all costs. If we want to bring this liquidity to scale with no centralized party, might I suggest that the core trading functions must stay under classic transparency?
Consider briefly the case of executing a reverse stock split using clawbacks, where users have deposited into liquidity pools. Early on, brilliant traditional market advocate @jonjove identified this requisite use case for institutional adoption. And the functionality was expertly integrated into universal liquidity pools with due consideration. ⚙️
The stable protocol best deals with these regulated edge cases key to basic financial functions like liquidity, which drives safe institutional adoption. I wholeheartedly believe that we need native participation to decentralize the rules rather than delegate delicate trading edge cases to explicit contract rules. Might we best achieve comprehensive liquidity with this collective existing rules consensus so that certain core financial innovations stay within our collective regulatory scope of safe oversight? 🛡️
3. Unique Values
There seems to be no other truly decentralized, distributed, and permissionless order book. Do you think this makes the SDEX something special and worth all protections to continue explicitly managing the ledger's liquidity without external states? Should we keep it in whole?
Nakamoto's unkept promise was an escape from the tyranny of centralized control. But the liquidity questions plaguing the industry around central exchanges still leave true ownership entirely up in the air.16 They well achieved new monetary standards since:
Might I respectfully suggest that, as the globe's financial system and given the materiality of liquidity in the global financial system:
I respectfully submit to the community that interleaving the SDEX with AMMs furthers our just principles since doing so:
Might the best work here extend to advancing the protocol for the whole network rather than a few central interests? Given more time, I'd be happy to elaborate further on any of these points either in writing or orally. Moreover, if we support egalitarianism and everyone participating on the same playing field, then might we contemplate further the competitive advantages of interleaving the SDEX with native AMMs so that liquidity stays core to the protocol?
4. Storied Guiding Principles
As someone deeply involved with early crypto liquidity, might @jedmccaleb understand firsthand the quandaries of disparate liquidity pools? In 2012, Jed wrote: "One thing you can do with it is exchange bitcoins for fiat without the need for a centralized market such as Mt. Gox. Which will be very useful for Bitcoin," when discussing preliminary ideas for Stellar. This prescient viewpoint introduced me to the foundational ethos that "liquidity begets liquidity."
Might we continue championing the network's distributed exchange, as it was originally named? Specifically, can we continue innovating on the exceptional core concept released in the first version of the protocol? Namely, interleaving liquidity pools ought to protect users since:
Since any account can send an order to the SDEX, its order book is uniquely egalitarian in that all market participants follow the same rules, treatment, and pricing. You receive the same exchange rate whether you are a major European bank or a rural Kenyan farmer. Perhaps the equal execution enabled by SCP and primed to scale can best empower global, inclusive, and decentralized liquidity?
Footnotes
I won't pretend to understand completely everyone's unique and interesting projects. Enrique has made incredible progress developing on Soroban with fast reactions, an ongoing decentralization ethos of community efforts, and grassroots developer advocacy within events. 👏 ↩
When I say "only," I don't mean that this is the single source of any liquidity. Inherently, anybody approved by an issuer when applicable can post a native offer or deposit into a liquidity pool. But it was the only pool selected for additional governance token incentives. 💸 ↩
The immediate, unannounced migration fixed a bug that let attackers empty a pool's reward reserves. 🕷️ Luckily, nobody drained any deposited funds before @rahimklaber found the exploit. 😌 But the entire liquidity protocol had to deploy new routers, pool identifiers, and balances. 🤔 ↩
See tremendous state expiration explainer, informative technical specifications, and historical data education. ↩
I'm continually impressed by the permissionless, comprehensive, and public nature of Garand's posts. They break down innovations for everyone to understand and implement, no doubt after countless months of development. Hopefully, more pupils from @stanford-scs will join network development efforts. 🌌 ↩
See original material in WhyDRS Discord, sourcing from @BibicJr and featuring @bobmahalo. ↩
It is my present understanding based on this conversation that Garand ingeniously developed a latency arbitrage strategy whereby he identified, via one-way ping latency, which of three cloud providers used by Coinbase hosted the order book for an asset. Next, he spun up an instance at the identified data center and, using his proprietary latency tests, kept refreshing the instance until his virtual instance was initialized on the same rack as the Coinbase server. ⚡ Once he was on the same Ethernet switch, his connection to Coinbase was so fast that it was trivial to execute arbitrage against other popular crypto exchanges with pro accounts. ↩
See, e.g., public discussion, cessation of DSTOQ operations through Liechtenstein custodian, and pending conflicts. ↩
This is my present understanding, which the Syndicate bases its regulatory filings along. 📜 However, it is subject to change and should not be taken as professional advice. We're actively working to clarify the narrative for other Stellar assets, especially tokenized mutual funds. ↩
I've been building on Stellar around the SDEX for just over three years because I wholeheartedly believe the network will be the efficient financial system the world so desperately needs. I've been helping around on the docs lately while our community organizes to work on mainstream frontend interfaces. 📃 Accordingly, organizing our approach to consolidate liquidity seems pressing to preserve a clear, direct, and efficient order execution path. ↩
Trading naturally grew into a huge passion of mine, where I saw firsthand the damage of fragmentation. The turning point for me was when a third of my biggest trade ever went to a brokerage in commissions and fees. Even if you're trading less leveraged assets without derivatives, the small transaction costs created by markets can really add up. 📈 ↩
See 24 national exchanges, internalizing brokers, and 72 dark pools. ↩
See, e.g., services splitting path payments into optimal chunks, splitting orders between three equivalent AMM contracts, and quantifying aggregated LP depth statistics. ↩
Further, many of these routing systems are closed-source proprietary software with material secrecy risks, especially for foundational financial infrastructure. ↩
See discussion, study, and explainer of early emerging brokerages around the Dutch East India Company. 🧂 ↩
See, e.g., unaligned risks, internalization forces, and unsound models. ↩
See supra note 8 regarding convoluted trade history reporting for IDEX contracts. Even with modest standardization, developers will need to implement contract, function, and data standards for each and every unique liquidity pool. Might it be simpler for end users to follow the existing native liquidity pool execution standards? ↩
Interleaving has been vocally spearheaded even before the present masses of circular path payments. We want users to have the most financial success, and this might be challenging without natural understanding. Let's do it together through a common exceptional protocol process! 💬 ↩
Id. We can give users a standardized, clear, and shared source of all execution with validator-level interleaving optimization. Wallets should not need to independently route large path payments through different routes to guess at specification optimizations. Similarly, trades with comprehensive price optimizations obviate interface size-arbitraging overhead. ↩
Without an entirely automated best flow, users risk proprietary systems like the internalization that plagues traditional markets. See also internalization rate at 21, SEC investigation, and liquidity report. ↩
Users get maximum security when only they hold the keys to their assets, which can't happen with upgradable contract software development. While I'm not suggesting anything like that might happen in our community, it is a fundamental weakness solved exclusively through network consensus. Do you think collective scrutiny keeps funds securely processed? 🔐 ↩
Reliability and performance can greatly transform without extensively complicated systems built on the frontend wallet side to extract spreads. Without the need to route between disparate sources of liquidity or transaction processing, might the whole network best employ validation resources? 💻 It seems the aggregation logic in particular could significantly expend ongoing Soroban computational resources. ↩
The material base functionalities of core embody a universal financial system, like efficient payment performance. But employing Soroban transactions costs more from all deployment, management, and processing standpoints. Might we focus on the existing efficiencies in the protocol's liquidity pools? ↩
As SPEEDEX develops, future scaling can include liquidity pools in a comprehensive efficient system. This continues the empowering decentralization promises of automated liquidity participation so that anyone can inclusively help build SDEX liquidity as a dominant use case. Since this innovation emboldens the native liquidity functions, might the best path forward become a CAP bringing native liquidity to scale all together? ↩
With native liquidity in one place, might all migrants and global transfers benefit from the best rates based on all available liquidity? Optimizations here can keep currency conversion at its lowest so that money gets to the places that truly need it most. Wouldn't this be a better destination than an arbitrage bot, price slippage, or optimization miss? ↩
As a destination for liquidity, the network becomes much easier to reference when assets have a single point of reference similar to a cohesive best bid or offer. Requiring pricing consolidation into a single point of failure unnecessarily separates offer inputs across needlessly competing liquidity venues. There will always be competing DEX aggregators because smart contracts have an inherent competitive nature absent from the protocol. ↩
Without interleaving as a best system, smart contracts with proprietary routing can dominate discovery. But forcing permissionless developer standardization would be impossible without the extensive transparent consensus around protocol upgrades. 🛠 I respectfully submit to the community that synchronizing disparate Soroban contracts would, in all likelihood, be no more efficient than pushing through a CAP introducing a new fee band to native liquidity pools, for example. ↩
Do you think direct protocol functions in Horizon are easier to use than a DEX aggregator's contract? It's my interpretation that "the Stellar network" doesn't mean a centralized router on Soroban, despite upgradability. Alone, any interoperable governance standard here again just becomes as important as on-network protocol. 🌐 ↩
Might liquidity be most effective as presently consolidated on the global SDEX? By combining liquidity pool optimizations, we can bypass traditional financial mishaps from brokers approximating spreads. Could a single native standard best synchronize all users with a simple pool of capital? ↩
Beta Was this translation helpful? Give feedback.
All reactions