'The Road to Starknet' - Tom Brand
ETHGlobal·Sat, Oct 9, 2021, 12:00 AM
Join Tom Brand of Starkware as he explains how to scale your dapp using Starknet.
Transcript
hi everyone thanks for coming to uh watch this talk and thanks thanks for hate global for having me here my name is tom brand i'm a the product lead of stark net at starkware and today we're going to talk about starknet and we'll go over what we see what what is starting at what is the vision on what foundations it lies and how we plan to reach door or what is the road map towards darkness and so let's dive in yeah so starting at starknet um in one sentence is a decentralized permissionless zika rollup which offers scalable and secure ethereum-like state and what i mean by that so first of all it's a zk roll up i won't dive into what is exactly zika roll up here um you can see it online and on other uh talks but generally speaking it is the mechanism of offloading from l1 or mainnet both computation and storage and moving into l2 and using a proof system and specifically in stark net stark proofs in order to securely prove state transitions on l1 so starting it is a zika rollup it will be permissionless both for of course for the user so everybody will be able to use it but would be permissionless for the operators and for the provers um and and they terminate like state means that uh developers will be able to deploy stark net contracts which are the equivalent of solidity smart contacts which will support general computation and they will all be deployed in one single composable state meaning all the contracts will be able to interact with each other so this is our vision to starknet and before we go to understand how we plan to reach there um it's very important to understand that starknet uh lies on a very strong foundations so starkware is uh live almost uh three years and we've we've been developing really hard uh in those three years uh the stark stack um and what i'm going this and what i'm going to describe now is um how we plan on on what technology we plan to build startnet so first of all we have cairo which is uh also what we offer here when it's global to developers to to develop but basically it's uh our turing complete language uh for scaling dapps using starks i will get to it in a second but cairo is what allows us to um to write uh um the stack for starknet um next we have our starkprovers so once you uh write your program and you want to generate a proof to it you need to have strong provers and our provosts are at least as far as we know and as far as was um approved and mainnet are the most powerful pools in the world and lastly we have starkix which is an actual zika roll-up application which works in a production which uses both cairo and the stark provers and is it's a real live application that allows us to make sure that the technology that we develop actually works so let's dive into each one of those a little bit and understand how they allow us to to later build starsnet so first of all cairo i won't dive deeply into cairo here because during this global hackathon there are many talks that stockwere has given and is going to give about cairo so first of all on monday we had a workshop which included an intro to cairo and then live coding session i encourage you to come to our discord channel and and search for it there and ellie also gave a talk eleven sasson our president and co-founder also gave a talk about um how cairo changed the paradigm for writing proofs and why uh if you wanna build on startnet you should first go learn cairo and next week on friday papini which is one of the inventors of cairo is going to give a talk that technically explain how we built cairo and how it works so what is important for us to understand is that cairo is allows anyone to write any program that they want and all those programs proof that is generated for those programs can all be verified in one smart contract so this is the the the first thing that allows us to to use cairo in order to build stark nets which hold many many many programs and second of all cairo was built to be efficient and secure meaning that even if we want to take a very big computational statement for example a batch of many many many transactions we are able to generate a proof to it in a very short time and it is also very secure meaning there are ways that we can audit and test a a program and know that it is secure um most important is to understand that this is already in production on minute on july we demonstrated the program uh on the reddit's scaling bake off and since november all starting systems use cairo and it is available to the public as you may have as you may know and this is actually what we offer developers to build in the hackathon and all the information that you need in order to start developing in cairo is you can find out through the site cairolink.org and perfect now that you understand cairo and or maybe i would add just one sentence so why cargo is important for start net because for two reasons first of all it allows us to write what we call the start net os which is the base layer you can think of it as the evm uh which runs the the logic of the state transitions of stark net now since cairo is just like writing a program and it is very efficient it also means the stark net and improving state transitions of stagnant will be very very efficient um and second starting net contracts the native language that they will be written i'm not talking about transpilers from higher languages or from solidity will be written in cairo and so this also allows us to to give a lot of flexibility um to developers to um and maybe i will go into it later but to write very efficient uh dups okay great now i understand cairo the next uh foundation is the stock pulvers so as i've said they are the most powerful provost in the world and they power all star kicks deployment since um june 2020 on main it i may be repeating myself that we are on that our technology is the main but i think it's a very very important thing to understand and so just some stark guinness record so the reddit scaling back off as i've said was in july 2020. um it was a rollup meaning that the data was unchained and there we generated proofs of 30 300 k transactions in a single proof which resulted in an amazing uh gas price per transaction of 315. in immutable circuits deployment which is uh live on mainnet since last week um in order to move their state from l1 to l2 we generated huge proofs of ns of nfts which actually minted them on l2 so we generated proofs of 600k nfts means in a single proofs which resulted in less than 10 gals per minute right so what those provers allows us in the context of starknet is the ability to generate huge proofs which results in mean which results in in a very very high scale not only that we're able to generate very very big proofs we are also able to generate in a reasonable amount of time those two parameters allows us to have a lot of flexibility in the way we construct the the protocol of start and lastly the less foundation is stark itself um but already today there are multiple deployments on mainnet uh so have or wait i'll go step backwards so start kicks [Music] is a zika roll-up application um starting that is a zika roll-up platform or layer which allows many contracts to be deployed on top of it and start kicks is a specific application um so we have uh diversify which supports payments and sport trading we have the ydx which supports derivatives trading and we have immutable x which supports minting and training of nfts we have more coming which hopefully will announce publicly soon and what starcx actually gives us is the ability to dog food our tool chain and technology uh uh and build it against real world needs we are working with customers we are working in a production environment and this allows us to make sure that both approvers borsaka cairo and all the development development tools that we are developing are actually able to build real world applications perfect so now that we understand the the the foundations of starknet or where we are today um we can go and understand how we plan to to to achieve stark net and as we do everything on stark word this is also we will do in a stepwise approach and what i mean by that is that first we will um the first step is planets and in this step we will build the the the basic building block of starknet which is the starknet contract um in the next step we will take this starknet contract and and put it you know in a in a one composable state with many many other contracts and the last step is once we have this um composable state we can decentralize the network and have permissionless operators and pulvers so let's go into one each one of those steps and understand it a little bit better and okay i see that i okay perfect so as i've said the first step um is a single up roll up and this is already expected on test net in a few weeks i think it will be mid-may maybe a little bit later but what as i said this basic step is is developing the start net contract so what developers will be able to do at this step is to write start net contracts deploy them on stark net and run them what i mean by by random is is send transactions to them update their storage and and those badges transactions will be uh proven and and verified on chain and a state update to the contracts uh will occur um those contracts will support arbitrary logic meaning you will be able to write anything you want with them and this will actually be the first zika rollup that is available to developers that support general computation meaning up until now there was no zika rollup that allows a developer to just write whatever arbitrary logic they want and to advance the state with sending transactions to it so this is the first step and be ready to hear from it in few weeks and the next step okay multiple up um we'll take this building block of a stark net contract and and we'll put it in an ethereum like permissionless uh state and and you will be you can expect everything that you expect for material so you you deploy a contract contracts can interact with each other um users interact with the system uh with transactions users will be able to sign either with a very efficient stock proofs or with detailing sorry with the very efficient stock signatures or with the ethereum signatures and we expect this to be um on mainnet meaning live on mainnet later this year um probably by the last quarter of this year um and what this so i said that it would be an ethereum-like state but what it will offer is a massive massive scale [Music] again i don't want to throw numbers in the air um but you can they won't be very different from what we've demonstrated with starkex and hopefully even better right so this is the second step and we expect it somewhere by the end of this year and and the last step is um decentralizing the network operation of this zika rollup and the most important part of it which we didn't have at step two is allowing permissionless operators and provers which of course result in a censorship resistance network now what is very unique in zika roll up is that we are able and since we are a layer 2 is that we are able to rely on ethereum consensus in order to achieve a very efficient leader election mechanism and the validity proofs allows us to have very fast finality again i don't want to throw things here but um in the coming months we will write more and more about how we plan to uh to build this network and of course we will use the crypto economics mechanisms to to [Music] to even further uh incentivize the efficient operation of the network we want to use them in order to to achieve the basic security properties but we'll use them in order to um make it much more efficient um okay perfect so maybe if i go back to this slide so step one is something that we already have today uh we have starcraft deployment on mainnet uh cairo and the stock provers are operational and cairo is on open to the public uh the step one and step two is something that we plan to have this year and next year we will probably have step three um okay perfect so we've discussed our foundations we discussed the road map um and i would like to sum up um what are the fundamental advantages that uh we see for starknet so first of all scalability um the layer two scaling solution the first thing that they need to provide is scalability and we think that startnet is have the best chance to provide the highest scalability possible so first of all off chain as i've said we we are able to generate the largest proofs this comes from both the strong provost that we have and the fact that we are writing things in cairo so many many optimizations are trivial to writing kyle for example um having a patricia tree is something which which is very complicated to do if you're if you don't have a programming language but once you have a programming language cairo is almost level to write and on the engine part we have the smallest data footprint first of all again using cairo we are able to make huge optimizations on the that on-chain data just to give an example applying hoffman tree on the engine data can reduce it by a factor and is not very hard to implement in cairo and second of all we have many many ideas on how to to allow secure network but minimizing the data on chain and just to give one idea we will allow developers on the contract level to decide which storage they would like to have on chain and which storage they would like to have often and so everything which is required for the user custody will have to be on chain for the contract to be sound but storage which is not required for the user safety and may be only required for the functionality of the contract on l2 might not be on chain and the flexibility that we will allow developers for deciding which data will be on chain or not we think will will have major advantages so the first thing is scalability second of all is the security um i think there's no argument that zika rollout is inherently more secure than optimistic roll-up so this is the first thing and the second point is and i think is not less uh important is that our technology stock is production tested if i i think i i said enough um but it allows us to have a lot of confidence that the both approvers and cairo and the the the paradigm of follow-up is is sound um and that i mean everything have bugs but that we are able to uh discover them um already in a walk on star kicks and lastly is the state finality so uh since we're using proofs all the state updates that the current chain are our final we've written a lot about why this results in a capital efficient system but i think one thing that we was not uh much discussed in the ecosystem is the ability to create interoperability between l1 and l2 um so since um the state is final once it is being updated we will support a mechanism that allows contracts on l2 to call contracts on l1 and contracts on l1 to call contracts on l2 and since this call happens immediately at the state update uh many many interesting applications can be built on top of that um so if i maybe will sum up what what what i've said here um so startnet um is currently what starkware is working towards and it will offer a general computation composability and experience of ethereum on one hand and on the other hand the security the capital efficiency and the scalability of the zika rollups as i've said it lies on solid foundations the road map um as i've described it allows us to go but in a step wise approach and first build the the building blocks and then apply them to a larger system and so thank you very much for your time and you're more than welcome to a discord server to continue the conversation and ask any question that you might have and i'm really hope that you will build amazing stuff with cairo in this hackathon and i can't wait to see [Music] what you'll build thank you very much
Automatic transcript — names and jargon may be misspelled.