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

Loading player…

Superfluid Opolis: Workshop, Payroll Mining & $WORK Rewards - Voith Mascarenhas & Patrick Gallagher

Ethereum DenverSat, Oct 9, 2021, 12:00 AM

This talk is from ETHDenver & ColoradoJam , the world’s largest Web3 BUIDLathon and Community Gathering. ETHDenver’s content is crypto and blockchain focused. Learn more: ethdenver.com Subscribe to our channel to learn more + connect on Twitter: https://twitter.com/EthereumDenver. Speakers: Voith Mascarenhas & Patrick Gallagher, Superfluid This talk was recorded Sunday, February 7, 2021. ETHDenver 2021’s content themes included DeFi & Money Legos, NFTs & the Creator Economy, ColoradoJam & the Next Frontier of Statehood, Protocols & Interoperability, Open Source & Public Goods, The Ownership Economy & Digital Orgs, Usability Design & Adoption and Legal, Privacy & Identity. Industry experts also weighed in on topics like decentralization, privacy, identity, non-fungible tokens, scaling, governance, diversity, and arts and culture in blockchain technology. The 2021 event was February 5-12 and hosted virtually in 2021 with 5000+ blockchain enthusiasts, developers and community members from 80 countries and 50 U.S. states. 🔴 SUBSCRIBE ETHDenver’s YouTube https://www.youtube.com/channel/UCgz9NU06t_FkT0Py1Vadczw 💡 LEARN ETHDenver’s Official Website https://www.ethdenver.com/ 👋 CONNECT ETHDenver Twitter https://twitter.com/EthereumDenver 📖 READ ETHDenver News on Medium https://medium.com/ethdenver 🛍️ SHOP ETHDenver Official Merchandise bufficorn.com 💬 CHAT Telegram https://t.me/Ethdenver Discord https://discord.gg/AxFmNdCVnU 📱 FOLLOW LinkedIn https://www.linkedin.com/company/ethdenver Instagram https://www.instagram.com/ethdenver/ Facebook https://www.facebook.com/ETHDenver/

Transcript

first up my friends it's superfluid and um also my friends at opolis weird so uh patrick hey john good to see you man i haven't talked to you in a while yeah it's been a while last time we met uh we were at the uh after party for denver in the mountains going skiing that's right it's last year so um welcome back so you're gonna be talking to us about superfluid and then void from the opolis team is going to be talking about sort of how we're doing some things with superfluid as well as other projects to create the future of the employment protocol for global utility so in any case guys take it away have a good time all right what is up eath denver hey good morning everybody uh i'm patrick and i'm coming at you from superfluid today i'm going to be talking about how to build a super app uh and uh superfluid essentially is a new d5 primitive uh for recurring automated transactions and so what that basically means is once you create a super token by wrapping a regular token now it's got all these superpowers and uh today we are basically going to deploy uh a new contract we are going to start a flow of tokens to that contract and then we're going to do some cool things like transferring an nft and that's going to update where the stream of tokens is going so we're going to call this the holy grail but before we go into the holy grail i just want to give a background on uh what superfluid is so right so this new d5 primitive uh it's adding functionality to existing erc20 tokens so you can take any of them and upgrade them and then they get these super powers like money streaming you can do reward distribution so it's like a super powered air drop kind of you can give out shares to different people and then you can hit like the distribute button and then boom everybody gets all of the tokens according to you how many shares they have and then uh we also have batch calls so you can perform multiple steps in a single transaction using super tokens rather than having to you know ask the user sign this okay sign this okay sign this right so it's like a little more um a little more uh usable a lot more utility to it and then the last one is contract callback so that's what we're going to be doing today is looking at how to work with money streams and then how to have a contract interact with those streams so if somebody uh does something to you on your contract and then you want to change oh say okay now the stream should go here now the stream should go here you can do that as well so callbacks give this sort of uh reactionary abilities to your apps and they can update token stuff okay so uh a super app then is something that allows you to programmatically control streams and uh what this does is uh it gives a callbacks like i said uh for the app that we're building today it's going to be a holy grail so we're going to mint a holy grail and we're going to give it to uh we're going to we're going to have it for ourselves we're going to create a stream going into the holy grail and then we are going to transfer the holy grail to somebody else and um the app is going to control where the stream of tokens should be going so i would encourage you guys to check out if you need ideas for building this and we'll kind of come back to this later go to hacc.superfluid.finance hacc.superfluid.finance and we've got a lot of ideas there for what you can build if you're going like okay but like what do i use it for so you can get some ideas there and find teammates and then there's the app which we're going to use in the demo today we uh if you show up here we're going to minch you some girly some tests that eve and some tokens that you can play with and start creating a stream and you can also monitor streams we have the js sdk which works for both web3js and ethers that allows you to quickly create new streams and also do the instant distribution like i talked about earlier um that is available and of course the docs here you can get get set up get started with everything we have the network directory where you can see where all the contracts are deployed on the test nets we have basically every testnet except for covan and we have the discord so discord.

superfluid.finance if you tag one of us you can get help and then of course you know we're in the east denver discord as well okay so now to the holy grail all right so we're going to mint an nft erc 721 we are going to flow tokens to that nft and whoever holds it is going to receive the flow of tokens so this is a link we'll put this in the discord later if you click this link remix it will give you everything that you need that we're going to do today so i'm going to hop over to that link now and we are going to select the tradable cash flow contract and we are going to deploy it all right cross your fingers that gourley is going to work well today it was a little bit slow yesterday so i'm using alice alice is the account that i'm deploying the contract from and if we go to the dashboard we see that alice has 996 super token die so that's we call it die x we add the x to denote the superpowers of the the die so now that's in my dashboard i have 996 of it and what i'm going to do is i'm going to start a stream to that token that we're minting all right i see that that is confirmed our contract is now deployed and if we go over here to name we see the up the name is the holy grail the symbol is grail okay great what's the total supply right like how many holy grails are there one okay we're just only one holy grail right that's very important alrighty so now what we're going to do we're going to get the con the address of this contract and we are going to create a new stream all right here we go we're going to select die we're going to do a thousand a month oh wait a second but i don't have a thousand a month or a thousand die in my in my balance right is it still gonna work i don't know let's find out one thousand no not ten thousand i could do ten thousand let's just do one thousand though all right get this die flow into the holy grail and while that's processing let's go check out our other account over here uh this is uh this is bob's wallet and he has also logged into the dashboard he has a little bit of gurley eath because we airdropped it to him when he logged in but he has no incoming streams so his balance of super token is nothing so let's go back over to alice's wallet transaction confirmed in a second we should see a stream pop up in here oh wait what happened why are there two streams now we have a stream going out and then we have a stream coming in can you guess why yep it's because we're holding the holy grail we're the owner of the holy grail so when we send a stream to the holy grail it's pointing it right back at us so we see at a similar rate it should probably be the same numbers it might just be a little you know rounding error but these uh the incoming stream and the outgoing stream is at the same rate and if we go down and check we'll copy our alice's address and we will check current receiver actually we don't need to do that we see right here there is an incoming flow rate and we are the receiver 949 that's us okay so now what is it time to do it's time to transfer and when we're transferring nfts we call the transfer from function and let's go and grab bob's address we're going to transfer the the holy grail to bob we're going to copy our address because that's who we're transferring from and we're going to pass token id 1. remember because there's only total supply of 1 and that id is just 1. all right so we deployed the nft we sent a stream to it and now we're going to give the nft to somebody else and that stream is going to automatically update so let's go sit and wait on this account here on bob's account the receiver and see oh there it is now they are receiving the stream that alice is sending and so if we look at alice we see there's a negative flow and if we look at bob there is a positive flow so there we have it we just minted an nft we sent a stream to it because it was a super app it was able to react to things happening in the contract and update the flow of tokens using callbacks and that's what enabled us to modify this flow of tokens to the holy grail without actually having to do anything other than transfer that nft to somebody else so now we see that bob is receiving about a thousand die a month we were able to send a flow of 1 000 a month without having a thousand die a month because super token streams don't require capital lock up so you don't need to have all the money up front which is why this is great for payroll this is great for sending cross-border payments uh it could be good for subscription as as well and as long as you have uh enough die here remaining like until this runs out that stream is gonna flow and the cool thing is that you uh you can cancel it at any time of course but if you have streams coming into your wallet uh that are more than the outgoing streams then uh you can keep that going on forever right there's no uh there's no need uh for you to like call a thing and like withdraw it and then redeposit it no it's like if your incoming is a thousand and your outgoing is a thousand uh then it's gonna go forever right like if it's a thousand and one then you can do a thousand and one out so um that's really cool so like i said go to hacc.superfluid.

finance you can go to the ideas billboard see some examples of what people have already built with superfluid you can look for ideas that don't have a team yet and you can find other teammates that are looking for somebody to build on their idea we also let me go back to the presentation [Music] um the the sdk is pretty easy to use you basically just initialize it create a user object and then call user dot flow and provide the flow rate uh one thing is the tokens the flow rate is in tokens per second so you need to adjust for 18 decimals and then you also need to convert to a per second flow rate so um with that uh also go discord.superfluid.finances our discord the link to this presentation will be in the channel for super fluid in each denver hackathon so just ctrl k by the way if you're not familiar with discord control k and then like search for the channel you want it's like it's such a great hack so um that's a nice little hotkey that i'm controlling superfluid you can find and uh you'll get the links for all of this we have uh we have five thousand prizes two thousand for first place uh 1 000 for second place and then four 500 prizes so that's nice because um you know we're hoping we can spread the love and uh you know make make a uh give lots of people some prize for you know building on this stuff because blockchain is hard and we know that and we want to make it easier for you so come ask for questions don't get frustrated um you know you you can definitely do this i believe in all of you i remember my first hackathons i was it felt like i was climbing mount everest but um it is hard and it's not just you like everyone agrees this is hard we want to make it easier for you and we want to give you prizes if you build with us because we want to recognize that effort that you're putting in um so with that said uh you know this this is one example superfluid is one example of uh how we can send let me go back to the very beginning uh one of the ways we can send uh salaries to people and uh as john mentioned you know we hope that maybe opolis will consider streaming salaries to people using superfluid i think that would be cool because we we think that everybody deserves to be paid in real time um and not you know every every two weeks or every month or you know every month plus another week to process something and then your bank holds it right no you should get paid in real time so uh with that i'll hand it over thanks guys um well thank you and speaking of payments be from opelus ayer so i'm white muskratis and you know i have with me over here spencer who's the product manager and he also happens to be a member of the commons so uh i'm super hyped to have him here and he'll be helping me with this talk uh as we go along so let's get started so okay so you're gonna you're talking about the uh so i'm here to talk about the decentralized employment payroll mining and work rewards now this concept the employment commons comes from opolis and what that is is uh i would like you to hear from a member so spencer why don't you tell us about opolis the employment commons uh yeah so so really quick um as voice mentioned i am a member and i have been a member of the the employment commons and i've also been uh contracted by opolis to help manage the the building of of what we're about to show today and kind of a couple further steps um and so i'm i'm working for opolis on a contract basis and that means that um uh i have the kind of the freedom to work in other areas as well and so i currently have a number of different projects across a number of different uh clients or or projects that i'm working on that and all of my benefits are actually centralized within uh within opolis and i'm provided uh health care and uh payroll kind of benefits uh with offalets with opolis um which i think is is really cool and that's one of the reasons i wanted to help help opolis build build this thing and what we are building is a way for me and other members of the employment commons to be rewarded and also to participate in the governance of that employment commons so this is the very early stages as we'll be talking about this is a progressive decentralization approach that opelus is taking but basically as you can see here in these bullet points as i receive a payroll through the opolis mechanism i am going to be rewarded for that payroll consumption and something that we kind of call payroll mining so i'm going to be receiving work tokens kind of as a thank you and as a reflection of of what i've been doing and those work tokens will also allow me to participate and help to govern the employment commons of which i'm a member okay um yeah so that's the comments and what all of that sounds like uh the stuff right i mean you can pretty much implement all of these benefits and all of that on the web 2 on web 2 itself but where does the web 3 part come in so as i said it's a cooperative um everyone benefits from being part of the co-operative but how do we be transparent in that case so that's where we web 3 comes in and what are the different challenges there if say office has to become fully decentralized and so oculus doesn't say that it is uh decentralized now but it aims for progressive decentralization and the thing with payroll or anything is that you have to fill in a bunch of tax forms and a human has to review those forms and tech a tax man wants their money in fiat right now i'm and come on let's face it crypto is not a mainstream a mainstream currency yet right and then we have all these users who have who are not used to the web3 space so where they come in they see here about this thing called gas for the first time okay i need to interact with the blockchain oh but i need something called guess oh that's a bummer but we are here and we are planning to be the bridge between the web 2 and the web 3 world so how do we do that so we use great tools for that the first thing to interact with the blockchain you need a great wallet so we'll be using a magic wallet i'll get into the details of that how it's different from the rest of the wallets existing wallets if you haven't heard about magic we have all sorts of gas related problems the network is congested so and the grass gas prices keep spiking on the ethereum network so we plan to use side chains and they're using x die at the moment for governance we are using snapshot which i'll be demoing in a while and hey we just spoke about uh superfluid just book and we plan that superfluid will do a token distribution so let's head over to the demo so as spencer said he said we have this way where for processing your payroll and for using operas you get rewarded right so that's what i'm here to demo today uh how what do you do with those rewards uh how does governance work so that's what we are going to demonstrate today so once you've um come in uh to the opposite dashboard the the way to get on to the uplift dashboard is you have already uh filled up the onboarding forms someone has gone through your uh forms and has have got you verified and now you're a member of the comments so this is the screen that you see once you're a member of the comments and i'm here now to show you the rewards and confidence part so the moment i click on this is the screen that comes in and but here's the thing uh for any project we first need to select a wallet right and as i said earlier we are using a different kind of volunteer using something called magic and it really is magic and i'll tell you uh why that is magic in a while so um as i said earlier um we want to get rid of this friction that is there for web 2 users who are used to the internet but not used to the bigger three world and we we don't want users to get all these problems related guess so how do we do that use magic for that so if you come in here you can just say click on use default wallet and it says it's setting up the wallet for you and what happens is behind the scenes we are finding funding the wallet with cash and all of this is abstracted out to the user you don't have to worry about what's going on over there and let's see let's just wait for it to get quiet listed so what's happening here behind the scenes is uh so we have a few a few different contracts that we've set up and deployed on xdi uh one of those is kind of our member registry or white list contract and that that holds all the addresses of the of the members of the commons so my address as a member will be there we also have our the the work token contract and then the the uh the staking contract which we'll uh we'll talk about here about um uh one thing that we wanted to make really sure of when as we were thinking about how we wanted to build this was to make sure that we could support both our our uh web two native friends who are um becoming members of the employment commons um and and that is kind of that's one of the reasons that we're using magic to make it super smooth for them um but the we also want to support uh members like me who are a little bit more uh web three native and so there's there's gonna be a way to for me as a as a web 3 native member to switch to an existing wallet that i already have and also get all of these benefits as well so go ahead boys okay yeah uh well um let's speak about payroll so since uh opera process is payable for you the way it works at opelus is payroll gets processed on the first and third friday so if i go to history and invoices your you will see that there's an invoice that has been created and this invoice is dated for the 19th of february but hey today is 7th so invoice won't get processed until the 19th of february and why does that matter because what happens is when invoice gets processed and say it crosses a certain threshold then you you can get rewards so but there's nothing to worry about what what i have here is i have built a tool here which is going to simulate this uh time travel thing we are going to pretend that it's going to be 19th of february and then see a payroll block will be mined and you'll get your rewards so let's select the date 19th in february fast forward the time to 19th of february let's click on this and just to as this is going one reason this is this is important to show and important to understand is that the the rewards that i get as a member are a function of the growth of of the opolis commons as measured by the amount of of money flowing through the payroll system so new rounds of rewards that we're calling uh blocks are triggered at certain thresholds of growth of that total payroll and so what's happening in this simulation is we're basically simulating the the employment commons growing sufficient to cross that threshold so now that so and triggering some rewards that are distributed to all of the employment commons members that have that have been uh consuming the payroll services including the the example on the screen here right and just to add to it um superfluid is going to be helping us with this uh payroll distribute on the token distribution so if i refresh here you'll see oh i have already received a bunch of tokens here it says my total is 15 000. so for the i already have some rewards here and again as you can see it it's not staked at the moment so as spencer told you we have a smart contract where we can stake our tokens uh so let's have a look at that let's take a couple of tokens here so let me just take about 100 tokens and here's the cool part here's where you get to see the real magic of the magic wallet so let me click on stake now if you use something like metamask you would have to approve the transaction right and and the way this works is you need to make two different calls one is the approved call to the erc20 token and then is the actual staking call to this taking smart contract but guess what you don't have to worry about any of that using this all of that happens behind the scenes and there you go you see that your tokens have been staked but how do you trust me like this has actually happened on the blockchain well you don't need to trust me what you can do is come on the uh go to the blockchain come here and check the transactions that have been made here so if i click on this particular transaction that is created here you can see that the stake method was called and if you look at this particular address here it matches with mine so there you go magically your transaction was mined and a user did not have to worry about anything so let's go to the next part that is uh governance and so as as we're looking at governance you might be asking why why would i as a member want to stake my work tokens stake my rewards and the reason is primarily to earn additional uh voice in in the governance um and as we'll see i uh in this example and i can't even talk about myself i will be if i stake then i will be kind of boosting the amount of say that i have in certain governance decisions over the opposite commons or the employment common no right so if you come on this governance portal you see you can create a bunch of proposals here the proposals that have already been created but before the first thing you need to do is connect a wallet so i have already set up a wallet our wallet is not yet supported here but i'll use metamask for now oh sorry about that metamask logged me out for some reason okay there we go we have logged in so let's click on this proposal and the way this works is uh this actually publishes data to ipfs and you don't really need to make a transaction all it takes is your signature as we will see so here's a proposal which says the work token reward allocated for payroll consumption what should be that percentage right now it's 30 what if i want to increase that percentage so let's say let's click on 50 and then i say what while voting you see something different here your voting power is 11 work tokens it's not one and that's the reason being you have to take 10 tokens and we're using quadratic voting gear and the formula is square root of the stake plus one that equals to 11 work tokens so let's just vote and see what happens and here you see it's requesting for your signature it's not requesting you don't see any guests requested over here so that's a good part just need a signature and there you go it says our vote is in if i scroll down below there you go you see that my vote is here and has 11 equivalent work tokens associated with it so that's all for the demo uh let's head back to the presentation here and the last topic is towards the decentralized future as we said we tend to be become progressively decentralized but here are a few challenges the one one of the biggest challenges is that we have to verify all the uh forms like i9 w4 which can only be done by human right now so we probably need on-chain kyc but how is that going to happen oracle's is the answer i don't know that's an open quest the other thing is we want to be transparent about the payroll volume process and the reason being the token reward that have been allocated are calculated based on that so we need to be transparent about that but we also need to keep user security in mind so we don't disclose user level data like how much how much am i making this can we could probably use something like new cycle there where uh only two people who have a certain secret can share that data on the blockchain um and the biggest part is crypto needs to be a mainstream currency right now it's not so until then uh your tax man will want uh the appearance in fiat but opulence is here opulence is here to bridge that gap for you till that happens and if you like all this stuff and we have a couple of bounties here and we are building an api which will be launching sometime this year but we would like to hear from you what you would like to see in our api now that i've seen our product let us know so we have a bounty for that we also have a bounty for integrating uh crypto processing crypto payroll we have a bounty for that so please go to this uh and or reach out to us on uh the discord server and we'll be happy to help you well that's all i have thank you for watching thanks boy thanks spencer thanks pat great job guys so to answer pat's question or his call to us as he transition hell yes we're going to use superfluid to stream payroll we think people need to get paid in real time too i mean we spencer and i have already been talking about that as the roadmap for some of the next generation things that we're going to be doing so hell yes um the the whole roadmap for opolis is really just to glue all the primitives and natives together in a usable format one of the most exciting things is voice demonstrated is like you literally don't have to be a crypto person at all to be able to use this product it's completely obfuscated away from you which means big onboarding opportunity payroll unemployment is the next killer app and i'll be doing a talk on that actually next this coming thursday during the ownership economy summit so thanks guys

Automatic transcript — names and jargon may be misspelled.