New Ethereum talks, every Monday. The week's conference uploads by event, in your inbox.

Loading player…

Building a Cross-Chain DEX with Chain Abstraction & Intents by Shao | Devcon SEA

DevconThu, Oct 9, 2025, 12:00 AM

In a multi-chain world, creating a user-friendly DEX is challenging. This talk explores how a DEX can leverage intents and chain abstraction to offer seamless cross-chain trading. We'll discuss the implementation of ERC7683 and integration with Across Protocol to enable trading across multiple chains. Speaker(s): Shao Skill level: Beginner Track: Usability Keywords: UI/UX, Trading, Intents, erc-7683 Follow us: https://twitter.com/efdevcon, https://twitter.com/ethereum, https://warpcast.com/devcon Learn more about devcon: https://www.devcon.org/ Learn more about ethereum: https://ethereum.org/ Visit the https://archive.devcon.org/ to gain access to the entire library of Devcon talks with the ease of filtering, playlists, personalized suggestions, decentralized access on Swarm, IPFS and more. Devcon is the Ethereum conference for developers, researchers, thinkers, and makers. Devcon SEA was held in Bangkok, Thailand on Nov 12 - Nov 15, 2024. Devcon is organized and presented by the Ethereum Foundation. To find out more, please visit https://ethereum.foundation/

Transcript

[Music] I'm sha co-founder of niod deex uh I've been building things different things in eum uh since 2018 um I guess most of my most of my friend don't know what I was working on the thing were building are just too complicated to explain but this time is different we're finally build something that even my parents know how to use so uh today I'm going to share the experience of building a niod deex a product that uh High blockchain complexities away and a to make defi accessible to everyone so uh problem we all knew there are so many usability issues gas C phas Bridge tens of ler toes there are just so many things you need to figure out before doing a simple transaction and most of us I believe are offering different solutions from different angle so like U Better loging another wallet or a faster chain but even if we have some uh great solution for part of the problem but if some other place some other step are broken and users still cannot get their jobs done think um for example um just like someone want to buy her first coin let's assume they have a perfect wallet and unboarding experience is just perfect but it's very likely that he will Stu when he need to pick one CH from like 100 different L2 or let's say now he has a um perfect wallet and also the best decks and now he want to connect his wallet into her uh the best Dex but she might be mobile and just don't know why just what I con sometimes just not connected and nor the best wallet or the best Dex can help them helping her but or um maybe you should finally overcome all the problems now finally the the last step she's going to buy the coin she want but turns out it might be a fishing link then he's buying the coin that actually not the coin should think he she's buying and the worst scenario is should might lose everything just because of this simple mistake after spent so much effort the risk and reward seems asymmetric I think um there's no like 70% usable or 90% usable in crypto it either works or it doesn't so I think um we cannot make it useable by just offering some partial Solutions we need to have a holistic approach that address end to end user experience and users should not need to learn like 10 different tools just for solving one problem you need to user just want to deal with one product instead of like 10 different tools so uh and from uh the entire process we shouldn't mention any technical terms those crypto Jun is Irrelevant for the user normal user who want to get things done and when we are talking about chain abstraction it's not about technology it's all about user experience we need to work start with user experience and work backward to the technology so it seems like a very humble and simple request the ideal uh flow for a normal user should be just like for example like a biometric loging just like most of other app and then deposit some f and then you can start to trade in second seamlessly in one app but that's not the fact and after so many years seems like there are not many product offering this kind of experience probably not even one so our approach is to offer a unified product combine several powerful components and that only integrate some trusted D app with a native consistent user interface to offer a simless user experience um but then it's unlike traditional wallet that will expose user to unlimit the app which could break your experience or maybe could be unlimited potential attack vector and it's also not un uh not like traditional Decks that you always need another wallet to connect and I'll start to uh share like how the unboarding experience first a can I play the video thanks oh great thanks so um user should use uh uh this uh should use a crypto like uh normal F Tag app so in this case uh you just use the pass key and create a wallet and uh by the way there's a second Pass key is for creating a session key but uh it's out of the scope today but anyway now you have a self custody wallet without managing the c-ras so uh behind the SC um um after that process we'll deploy um Smart Control wallet that of course come from the 4337 standard we're using a smart contract wallet called kernel built by Zod uh W as a service company uh so when we deploy this Kel contract uh we also use this Pass Key account as the main signer there is one unique feature or constraint of Pass key is it's binding to a domain which means uh you cannot use this Pass key in another domain so it's nearly impossible to be fishing but also there is another downside that what if the site is down so seems like uh recovery mechanism is a topic that we cannot skip but the challenge is if users still need to create another W for the recovery but then it's probably they still need to manage the SE race then it's our failure so uh we want to have a mechanism that even user don't need to access the private key or they don't even need to manage that as long as they have address that can receive the fund even it's like a centralized exchange address or someone they trust that still works so our idea is just uh it's very simple so while user has the access to the pass key so he can set up he can uh enter the fallback address that he plan to receive the fund when something goes wrong and then he used the social login to create another Guardian address and then ask the colonel to Grant the special permission to this Guardian that this Guardian can trigger some recovery event that led kernel to transfer all the fund to this fullback address this is only possible because of this is a small contract wallet at least uh for today and um this kernel contract also Implement another modular small account um standard ERC 7579 that can make this smart account be extended with compatible permission so uh for example like uh in our case this permission would be like you only allow Guardian to trigger uh to ask kernel to call a function uh that is transferred and the receiver must be fullback addressed so um now user has a no reliable selfed wallet even when the site is down or even if she lost the pass key so after the onboarding experience we're going to talk about how we combine uh leverage the intent based Coss chain Swap and some account abstraction to offer a simless chain abstraction experience so uh first let's start with a scenario that Alis uh want to buy some AR with uh us usdc let's say a usdc is from U optimism could you help to play the video thank you uh so at she only focus on what asset she's going to buy and don't need to care about CH and pick the asset buy that's it don't need to worry about any other thing no gas no bridge and you can see there are both optimism and ariton in one place we should unify ethereum 100 of ethereum layer to into feels like a one ch um but uh so how does it works so we go through this cross chain architecture step by step uh but should be quick the concept is quite simple so first in optimis and CH and Alice broadcast uh send a sign order and procast this order to express her intent so now Alice want to buy a minimum amount of obop with uh usdc and then uh relat pick this order and then uh relate this order send a transaction to a Smart contract the smart contract will pull some usdc from Alice to this small contract block the fund as an ESC he will relate uh he will repay the usdc later to relayer once the uh he he ensur the relayer finish his job so in the op ch ch this relayer um since you know the intent the order and then send a transaction to a Smart contract and then smart contract will transfer the Orit Chom to Alys and uh from Alice point of view the cross chain transaction is done the trade is done she already receive the op she need and she already paid the usdc she doesn't care it's in a small country or another relayer but uh for relayer she needs to wait uh the crossair there there must be something like cross shair messaging under the hoood and she she to wait the CR messaging to let optimism CH know okay now relayer in Aron already done his job so um you can imagine this crossair messaging is not that fast but from 's point of view it's a lot faster because once her trade is down she didn't touch anything about bridging so once optimism confirm uh okay Rel did his job in AR Chom then smart contract will unlock the Fone just transfer from to relayer so um this is just an overview of this architecture and now we're going to zoom in a little bit on this smart contract component so actually there are several layers so first um uh niod deex as a user facing product um has another contract that conforms another cross chain intent uh intent based cross chain swap standard uh youc 7683 it could allow different system and to work together to share uh infrastructure like orders and fer that can make this system more efficient uh under the hood the uh this um 76 A3 implementation interact with another settlement layer in our case we use a cross protocol um then a course protocol also uh work with another Uma Oracle optimistic Oracle to do the cross messaging so um you as you can see relay seems like taking a bit more risk but uh user is still not risk- free as many other um smart contract user so there must be some smart contract R uh when using this kind of complex architecture but uh I think it's our job I mean the one who build a user facing product we should be accountable to deal with this complexity not user for example like if something goes wrong like okay Uma Oracle um has a unexpected result which may um make user loss her Fone but it's impossible to ask atast user to act as a distributor during the challenge period um if we really want to do this kind of like chain abstraction thing I think it's not only about make things easier but also about uh dealing with this risk and complexity if we if we abstract this away then it's our respon responsibility to help users deal with it so uh today uh We've shared approach that to offer integrated experience that make Divi useful just like a normal F Tag app and we El we show how we can eliminate C phrase and wallet extension by adopting Pass Key and embedded wallet and we also show how we can um abstract gas away and design a fun recovery mechanism thanks to modular mod account and we also show how we can let user to buy most of the s in almost every evm CH in one Tab and feels like in one chain without knowing anything about multi chain and now user can use Defi and use crypto in one app instead of like 10 different tools and we crypto native often think users should do your own research but I think the truth is no one want to do research and even um it's about dealing with money most of the normal user they still need someone to trust to be accountable even what we offer is a self custody solution I think self- custody shouldn't be an excuse for us that don't care care about user experience if we really want to unboard a buildon user to crypto I think user facing product like us should have the encourage to manage the entire user Journey To Own every step to make sure our experience meet users expectation uh I'm sha from niod deex um everything I share is already Liv in production for like two months and I really hope we can make Divi and crypto accessible for everyone Thanks a Lota now we have a little bit of time for questions and thanks a lot for submitting a few I see only one of them is upvoted so let's start with that one and the question is are there more security issues in using intense chain abstraction versus fully onchain Alternatives like Unis swap our approach is actually not that much difference compared to Unis swap but I'm not sure what kind of fly unchain alternative like Unis swap because if you trade you want to trade like a a cross chain swap in Unis swap are using basically the same mechanism unless you're talking about like every doing everything in one chain and then bre yourself to another chain um but I think that's something that's not comparable all right so let's move on to the next one um I don't know whether that one is uh counts as as uh promoting I'm not from across don't ask me all right the next one is uh how can the solver prove that it made the correct work and are there any ways the solver could take Alice's tokens and not do the swap but steal them um oh sorry where where is the problem so it's it's this one okay okay thank you uh it's gone anyway uh uh I don't remember the problem it's a bit long but uh I guess it's not able to do that actually Rel has more risk than the trader because um if you thank you sver doesn't need to prove it made the correct work it's the cross chain messaging protocol need to prove the solver uh did the work and solver just need to uh there's not much power from the solver solver just need to wait and hope the CR Ming doesn't steal his money all right um the next uh question is what bridges are you using behind the scenes to fulfill the orders I don't uh we're us this we're using across settlement but I don't consider this as a bridge because we are not using their liquidity but it depends on how you define the bridge we're just using that for for doing the qu settlement that it's a bit different uh compared to bridge uh at least this what uh understand this all right the next one is is your solver Network open to participate in who is actually solving the user intense how do you ensure users get the fastest and most efficient path okay the easiest way is we make it permission so we provide liquidity within a certain time period to make sure we can always deliver uh under our control but of course uh once it's know uh maybe after some time per period period then it's everyone can to take this order and because we actually try to uh know rely on like the solver Network in across but uh seems like because we offer too many different kind of asset so there only a few major asset that you know some other field I want to take all right all right um the next question is how do you manage liquidity providers is there a separate interface for them we right now for spot trading we're just using uh we're more like a UI layer like a we just uh use like act as aggregator to use others liquidity from like Unis swap or other places all right um Can a user approv spending amount from the wallet when using the wallet in another app connecting via wallet connect assuming wallet connect connection is possible uh technically yes but uh but now we don't think it's easier to understand for normal user so uh at least in our product it's it's not supported but yeah it's technically technically doable all right um what is the backend between pasy and kernel validator and as far as I remember now it's in zero Dev yes it is okay you just got a confirmation lovely um why pwa over native app it's just easier for us to to to launch and and we just launch for two months we don't want to wait for like another month to to wait for Native app but that's also doable in the road map cool and uh there are a couple more questions but I'm afraid the time is up uh for the Q&A feel free to catch show after this and ask all of your questions and let's hear it up for for sh

Automatic transcript — names and jargon may be misspelled.