{"id":"mhJXsOKoSdg","title":"NEAR Lunch and Learn Ep. 01: Cross Shard Transactions with One Block Delay","description":"Here, Alex discusses cross shard transactions with one block delay. \n\n~~~ABOUT Lunch and Learns~~~\nThis is the first of a new series of videos exploring a concept on the NEAR protocol blockchain discussed in the NEAR office at lunch. Grab a sandwich and settle in!\n\nFollow the latest from NEAR Protocol on, \n\nDiscord: https://near.ai/discord\nMedium: https://near.ai/medium\nTwitter: https://near.ai/twitter\nGitHub: https://near.ai/github","channel_name":"NEAR Protocol","published_at":"2019-10-18T00:00:00.000Z","thumbnail_url":"https://img.youtube.com/vi/mhJXsOKoSdg/hqdefault.jpg","transcript_text":"okay so we will talk today about receipts in Charlotte blockchain specifically how to make receipts arrive from one blockchain from one short-chain to another search in in exactly one block so first let's see let's see what the problem is and I will use nightshade which is near sharding designed for the food example so in in nightshade there's a main chain which produces blocks every well that's a few seconds in each of those blocks for every short contains 1 or 0 we call them chunks so for example it said is exactly 4 shards and every every block will contain 1 or 0 chunks for each shirt those chunks they build on top of the last chunk that that was produced for the chart and so affected those chunks they kinda represent a short chain right so this chunk in the in the in the first chart and the third block is that is building on top of the chunk that was included last time for the same shirt yeah okay and so for simplicity of this of this presentation we will not look at the and dimension blocks we will just look at the the short chain at the chunks and so the so the short chains they produce the shorts they produce chunks at some time intervals and so we're gonna select time interval 0 time interval 1 time interval 2 etc so what we want to happen is in an optimistic case where two sharks do not skip chunks which in reality is going to be the case most of the time assuming that the the uptime is sufficient of the validators and they're not skipping skipping bits we want to achieve the following that if a transaction that touches multiple shirts arrives at certain heights would set height zero in one short so that's transaction then the receipt of the transaction which effectively executed the second part of the transaction arrives to the sec to the next chart at the very next block that sounds like it should be very simple and doable but there is a challenge there's a problem and the problem is the following the the to understand the problem let's first see how how blocks are processed and produced and and what is the actual timeline of producing a block right so if we if withdraw if this X is this time and you look at the blocks and what happens and there's a particular moment in time what are the checks right not blocks there's a particular moment in time when the chunk for for shards ero was produced and then the the question is whether the block producer or chunk producer who produced the chunk validated the transactions in the chunk before sending it out and so for example in bit in Bitcoin if you produce a block you do validate transactions before you send them send the block it has it has a problem it has a problem that if if the if the block producer of chunk 0 validated transactions before and computed the new state before sending the chunk then it means that any other chunk producer so let's say sham producer 1 they cannot start validating the same chunk before chunk producer or offer of this chunk finished validating because it wasn't sent before it was validated right and so these two events the chime producer validating a chunk and any other recipient in the system any other validator for example chunk producer for the next height validating the chunk they they end up being serialized one after another but naturally the chunk producer of shard one cannot produce chunk at height one and you'll be validated the chunk of height zero there are two sharks right oh those are that's one shortened to chunk producer story so that strong producer one jump register for height zero and chunk producer for height one but it's within the same shard right so if you do validate transactions before you send out the chunk what ends up happening is you create a chunk you validate it then you send it out the next chunk producer has to receive it validated before they can produce the next chunk and then the same happens again right the zeroth chunk produced receives the chunk validates it before producing the next of their own I tried to sorry this is one and so therefore the willit validation happens serialize twice and validation is actually pretty expensive it may be that the biggest bottleneck in the system but it does take time and so that ideally should be removed and so instead of that near and many other block chains but near specifically which is going to be relevant what Peretz in a different way where when you produce a chunk you do a very basic validation of transactions specifically when the validate that the transaction issuer has money to cover the gas price accumulate transactions new chunk and immediately brought broadcasted and that chunk is considered valid even if it hasn't valid transaction valid transaction just charges the gas but but remains in the chunk right and why it is important it is important because the chunk producer when the broadcast the chunk they don't know the post state route they don't know the state truth as of after applying the transactions and so therefore that posted cannot be stored in the chunk and that also means that the receipts that are going to be produced as a result of applying this chunk they are not included on the chunk as well right 30 sheets will only be known when everybody else receives the cheque and processes it right and so this is where the challenge happens is that by the time now let's consider another shot right so these another chunk produced or let's call engine producer - and they're producing in a different chunks are so so that so this is charge 0 that's good as 0 this is s 1 over 0 and this is a short one so when they receive the chunk or like some information about chunk that was produced for the shard 0 they do not know yet they don't know the digits but also they cannot apply it why because they don't see the full shard the full chunk in a sense that if there is 100 shirts it is infeasible for every chunk produced and every shorter send the full chunk to every other shirt right so effectively the chunk produced in short one will not see the full time from charge 0 they cannot see the full full chunk from every shirt so all the receive is they receive some header and some information with it and so in particular they cannot they cannot receive the receipts from Charlotte from this chap from this shirt but also they can not reproduce the receipts because they cannot apply the Qiang they don't see the full jack they don't even know if it will have any they do know if the shank is relevant when the block is produced like when the mention Church mentioned block is produced so this is the main chain block another main chain block but the time by the time they receive the main chain block they know all the chance which include it so at least they know that the tank is actually is included on the main chain and assuming heavy load you probably expect most of the shorts ending list it's the most of the shirts so the no track is included they they sort of know that probably there are you see it's coming from that from the chunk but they don't know I didn't know what what they are right and so coming back to this picture now that we discussed that problem so what happens is in this chart whomever is going to be producing this chunk by the time they produced chunk they have no way of knowing these sheets as of applying this chunk right and that's the biggest problem there is no way for us to do that if if we did go with the approach where the chunk is fully applied before before it is sent that problem would be solved because then the chunk producer would have known the receipts as of applying the chunk and so whatever message they sending to the other shirt that message would just include these sheets but again that that becomes significantly slower right okay so what what can we do we definitely cannot without some magic with as we just discussed what definitely cannot know the disease by the time we creating the chunk but also we don't know it we don't need to know this it's by the time we creating the chunk we need to know the disease by the time we executing it right so in reality and so let's say this this chanc produces produces chunk one for the short one right they don't need and so later down the road someone else is applying it in reality we don't need to know receive this is at this point when we create the chunk we do need to know the issues by the time we apply the chunk right and so let's make sense cool and so the way it is done today is the following when when a chunk producers in this case one one of the chunk registers which are zero produces the chunk we already have to distribute small parts of the chunk to every block producer in every shot this is called date availability unless it works right so when they do that they also actually let's use one as an example one is a better example so by the time chain producer created the chunk one the very the very last thing they did before that is they applied chunk 0 right so they just they received chunk 0 they had the state they applied it they know they know they knew post title and they know all the new receipts so when they create a new chunk chunk a tight one they do the following first of all the header of this chunk will contain pre state route which is the post state route for the previous chanc but it will also include the receipt the receipt a miracle morkul root of all the receipts produced as of after applying 0 right so we don't know yet the easiest which will be produced after applying one but we do know this is the two produced after playing zero so there is a miracle root of all those receipts and also those this is all sorted by the destination sharda G and so you can prove any subset of those receipts go into this to a single shard in a single miracle proof and so when they when they when they like cut this little chunk into small pieces to send to every validator for data availability together with those little pieces they also send all the receipts relevant to the particular block producer for their chart right so when this little little thing it goes to this chunk producer in the short one all these sheets that go from short zero to third one as of after applying this chunk they will be included in the message going to chunk number look forward yes so in time in time so okay so it will not get yeah it will not get include it into this chunk right because this shank and this string they produce concurrent yes right so yeah so you're right so it goes like in time it it will end around here right now what's important is that when you receive a block a particular block and you see chunk headers in it that block is considered orphaned I'm kill for average for every shirt and for every child concluded you either have the food chunk if that's some short you validate or you have this little one part if it's not a short you validate and there are protections in place which protect against lazy behavior so you cannot pretend you know it if you pretend you know it is a good chance you will be slashed there is a protection in place so you will not unorthodox it will not consider the block valid until you have those little one parts for every chunk that is included and that also means that you have all these sheets for every shirt and the receipts are provable because there's a moral route here right in the header that header is on the block and and you have the Merkel proof against that you send all the relevant receipts for the visa for the destination person for with it with the with the part that goes to that person yes right and so now by the time I need to apply chanc one I would only apply chunk one if I receive the block which has shrunk one right so if if we draw these chunks well unfortunately I don't use the short idea right so so let's use so it's as 0 as 0 as 0 0 and this is all this one right so this 0 1 and this 1 1 right so this is the chunk 1 for char 0 this is junk 1 for short one I will only apply this chunk when I processed this block I only processed this block if it is not an orphan it is only not an orphan if I have one part for every chunk included including the chunk chunk 1 for short 0 and so those by the time I'm playing this chunk I don't know the receipt right so we guarantee that by the time you are playing chunk at height 1 you have all the receipts from all the chunks that included in the same height right so every every block producer this is a subset of shorts they care about as the subset of shorts that they validate but there's another sub sort of short way larger that you don't validate and so you need the full chunk for every shot you fully validate and you need just one part with the receipts for the shirts that you do not validate either way you will have the receipt if you have one part that receipt was sent to you with the Merkel proof if you have the full chunk and you validate the shirt then naturally you applied the previous chunk so you you have this locally because you computed them right so either way you have all the receipts and so that guarantees a that that that gives you one block cross card transactions right oh sorry this is 0 because the the receipt which was created as a result of applying this chunk will be processed already as of the time this chunk is applied so this is exactly 1 block between the first and the second hope of the transaction and the same applies if it sends a further cross card transaction it will also be applied on the very next block and moreover we guarantee that pieces don't get lost this is another problem that many block chains face today that the Charlotte block chance is that they don't have any guarantee the digits will be applied here if the receipt is not sent if it's not part of the moral proof that's a /hreul behavior because every other participant in the same short chain they will also apply this chunk they will also get the issues they will also the merkel proof the merkel proof doesn't match the miracle proof included in the header that's easily provable cryptographically and that's a slash whole behavior so everybody will arrive to the same proof every recipient and every other char they they will check against the prove they will know they have all the receipts so uses cannot get lost risk of guaranteed delivery and on the last problem which we're not going to discuss very deeply today is that there is a problem that if all the shorts and uses to a single chart that will spend the short ride so we're not going to go very deep into that but this is also partially solved because you can accumulate the receipts but you don't have to apply all of them at once you can put them into the queue and then you just process the first 103 sheets that got into the queue the the earliest and then the only problem is that how you prevent the queue from growing indefinitely and i think the only way to do that is to fail transaction civic useful right so by the time you apply the chunk the queue the destination queue for shard 1 is full you will fail in a transaction that tries to go to third one cool so that covers the receipts you have more questions awesome this your guarantee right I mean it basically allows you to say when we have the chance that we care about or we have like one part of whatever we not care about yeah but it includes receipts yes that's correct supposed to be like like this what allows chardon because you care about all the smoke all the shards right and everything else you kind of don't here so it's like a little bit with the warhead so I have a question one it's actually a little bit of the overhead because if we have a system where we have many shards and most of the transactions across our transactions it would like let's say we have financial system people just any money between each other like on your charts right I mean most of the transactions are going to be cross our transactions which means like the content of the blog of the chunk is going to be half receipts hard half transaction to just drive right the question is do they do all of the dishes go to the same chart because this one part it doesn't contain all the receipts it only contains receipts which go to the charts that they just receiving person cares about right so basically care about one charge then on average all the receipts accumulated from all one part says I do not care about approval gonna be on the same volume as yes yes so if the system is not skewed if it's well balanced and then you will be receiving as many issues as you see of transactions which is definitely viable it is still a problem though that if you're assured that the super popular you might be getting way too many receipts that can be solved in many ways that we did not discuss like you can you can limit how many issues can go to a particular shirt to some constant like you know team 3x something like one over a number of chars x to you something like that yeah cool more questions no okay so that covers our first lunch serious thanks everyone for listening","transcript_synced_at":"2026-11-04T04:28:15.355Z","segments":[{"start_seconds":5,"text":"okay so we will talk today about receipts in Charlotte blockchain","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=5s"},{"start_seconds":12,"text":"specifically how to make receipts arrive from one blockchain from one short-chain to another search in in exactly one block","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=12s"},{"start_seconds":20,"text":"so first let's see let's see what the problem is and I will use nightshade which is near sharding designed for the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=20s"},{"start_seconds":27,"text":"food example so in in nightshade there's","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=27s"},{"start_seconds":37,"text":"a main chain which produces blocks every well that's a few seconds in each of","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=37s"},{"start_seconds":47,"text":"those blocks for every short contains 1 or 0 we call them chunks so for example","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=47s"},{"start_seconds":55,"text":"it said is exactly 4 shards and every","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=55s"},{"start_seconds":61,"text":"every block will contain 1 or 0 chunks for each shirt those chunks they build","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=61s"},{"start_seconds":72,"text":"on top of the last chunk that that was produced for the chart and so affected those chunks they kinda represent a","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=72s"},{"start_seconds":80,"text":"short chain right so this chunk in the in the in the first chart and the third block is that is building on top of the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=80s"},{"start_seconds":87,"text":"chunk that was included last time for the same shirt yeah","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=87s"},{"start_seconds":96,"text":"okay and so for simplicity of this of this presentation we will not look at the and dimension blocks we will just","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=96s"},{"start_seconds":104,"text":"look at the the short chain at the chunks and so the so the short chains","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=104s"},{"start_seconds":114,"text":"they produce the shorts they produce chunks at some time intervals and so we're gonna select time interval 0 time","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=114s"},{"start_seconds":122,"text":"interval 1 time interval 2 etc so what we want to happen is in an","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=122s"},{"start_seconds":131,"text":"optimistic case where two sharks do not skip chunks which in reality is going to be the case most of the time assuming","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=131s"},{"start_seconds":138,"text":"that the the uptime is sufficient of the validators and they're not skipping skipping bits we want to achieve the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=138s"},{"start_seconds":147,"text":"following that if a transaction that touches multiple shirts arrives at certain heights would set height zero in one short so that's transaction then the receipt","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=147s"},{"start_seconds":156,"text":"of the transaction which effectively executed the second part of the transaction arrives to the sec to the next chart at the very next block that","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=156s"},{"start_seconds":166,"text":"sounds like it should be very simple and doable but there is a challenge there's a problem and the problem is the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=166s"},{"start_seconds":173,"text":"following the the to understand the problem let's first see how how blocks","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=173s"},{"start_seconds":180,"text":"are processed and produced and and what is the actual timeline of producing a block right so if we if withdraw if this","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=180s"},{"start_seconds":189,"text":"X is this time and you look at the blocks and what happens and there's a particular moment in time what are the checks right not blocks there's a","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=189s"},{"start_seconds":196,"text":"particular moment in time when the chunk for for shards ero was produced and then","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=196s"},{"start_seconds":204,"text":"the the question is whether the block producer or chunk producer who produced","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=204s"},{"start_seconds":210,"text":"the chunk validated the transactions in the chunk before sending it out and so for example in bit in Bitcoin if you produce a block you do validate transactions before you send them send","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=210s"},{"start_seconds":219,"text":"the block it has it has a problem it has a problem that if if the if the block","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=219s"},{"start_seconds":226,"text":"producer of chunk 0 validated transactions before and computed the new state before sending the chunk then it","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=226s"},{"start_seconds":234,"text":"means that any other chunk producer so let's say sham producer 1 they cannot start validating the same chunk before","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=234s"},{"start_seconds":243,"text":"chunk producer or offer of this chunk finished validating because it wasn't sent before it was validated right and","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=243s"},{"start_seconds":251,"text":"so these two events the chime producer validating a chunk and any other recipient in the system any other validator for example chunk producer for the next height validating the chunk","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=251s"},{"start_seconds":259,"text":"they they end up being serialized one after another but naturally the chunk producer of shard one cannot produce chunk at height","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=259s"},{"start_seconds":266,"text":"one and you'll be validated the chunk of height zero there are two sharks right","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=266s"},{"start_seconds":274,"text":"oh those are that's one shortened to chunk producer story so that strong producer one jump register for height zero and chunk producer for height one","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=274s"},{"start_seconds":282,"text":"but it's within the same shard right so if you do validate transactions before you send out the chunk what ends up happening is you create a chunk you","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=282s"},{"start_seconds":289,"text":"validate it then you send it out the next chunk producer has to receive it validated before they can produce the next chunk and then the same happens","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=289s"},{"start_seconds":298,"text":"again right the zeroth chunk produced receives the chunk validates it before producing the next of their own I tried","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=298s"},{"start_seconds":306,"text":"to sorry this is one and so therefore the willit validation happens serialize","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=306s"},{"start_seconds":314,"text":"twice and validation is actually pretty expensive it may be that the biggest bottleneck in the system but it does take time and so that ideally should be","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=314s"},{"start_seconds":322,"text":"removed and so instead of that near and many other block chains but near specifically which is going to be relevant what Peretz in a different way where","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=322s"},{"start_seconds":330,"text":"when you produce a chunk you do a very basic validation of transactions specifically when the validate that the transaction issuer has money to cover","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=330s"},{"start_seconds":337,"text":"the gas price accumulate transactions new chunk and immediately brought broadcasted and that chunk is considered valid even if it hasn't valid","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=337s"},{"start_seconds":345,"text":"transaction valid transaction just charges the gas but but remains in the chunk right and why it is important it is important because the chunk producer","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=345s"},{"start_seconds":354,"text":"when the broadcast the chunk they don't know the post state route they don't know the state truth as of after applying the transactions and so therefore that posted cannot be","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=354s"},{"start_seconds":362,"text":"stored in the chunk and that also means that the receipts that are going to be produced as a result of applying this chunk they are not included on the chunk","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=362s"},{"start_seconds":369,"text":"as well right 30 sheets will only be known when everybody else receives the cheque and processes it right and so","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=369s"},{"start_seconds":378,"text":"this is where the challenge happens is that by the time now let's consider another shot right so these another chunk produced or let's call engine","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=378s"},{"start_seconds":386,"text":"producer - and they're producing in a different chunks are so so that so this","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=386s"},{"start_seconds":393,"text":"is charge 0 that's good as 0 this is s 1 over 0 and this is a short","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=393s"},{"start_seconds":398,"text":"one so when they receive the chunk or like some information about chunk that","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=398s"},{"start_seconds":406,"text":"was produced for the shard 0 they do not know yet they don't know the digits but also they cannot apply it why because","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=406s"},{"start_seconds":415,"text":"they don't see the full shard the full chunk in a sense that if there is 100 shirts it is infeasible for every chunk","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=415s"},{"start_seconds":422,"text":"produced and every shorter send the full chunk to every other shirt right so effectively the chunk produced in short one will not see the full time from","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=422s"},{"start_seconds":429,"text":"charge 0 they cannot see the full full chunk from every shirt so all the receive is they receive some header and some information with it and so in","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=429s"},{"start_seconds":437,"text":"particular they cannot they cannot receive the receipts from Charlotte from this chap from this shirt but also they can not reproduce the receipts because","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=437s"},{"start_seconds":445,"text":"they cannot apply the Qiang they don't see the full jack they don't even know","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=445s"},{"start_seconds":452,"text":"if it will have any they do know if the shank is relevant when the block is produced like when the mention Church","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=452s"},{"start_seconds":459,"text":"mentioned block is produced so this is the main chain block another main chain block but the time by the time they","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=459s"},{"start_seconds":468,"text":"receive the main chain block they know all the chance which include it so at least they know that the tank is actually is included on the main chain and assuming heavy load you probably","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=468s"},{"start_seconds":477,"text":"expect most of the shorts ending list it's the most of the shirts so the no track is included they they sort of know that probably there are you see it's coming from that from the chunk but they","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=477s"},{"start_seconds":486,"text":"don't know I didn't know what what they are right and so coming back to this picture now that we discussed that","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=486s"},{"start_seconds":494,"text":"problem so what happens is in this chart whomever is going to be producing this chunk by the time they produced chunk","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=494s"},{"start_seconds":500,"text":"they have no way of knowing these sheets as of applying this chunk right and","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=500s"},{"start_seconds":509,"text":"that's the biggest problem there is no way for us to do that if if we did go with the approach where the chunk is","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=509s"},{"start_seconds":517,"text":"fully applied before before it is sent that problem would be solved because then the chunk producer would have known the receipts as of applying the chunk and so whatever message they sending to","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=517s"},{"start_seconds":526,"text":"the other shirt that message would just include these sheets but again that that becomes significantly slower right okay so what what can we do","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=526s"},{"start_seconds":534,"text":"we definitely cannot without some magic with as we just discussed what definitely cannot know the disease by","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=534s"},{"start_seconds":542,"text":"the time we creating the chunk but also we don't know it we don't need to know this it's by the time we creating the chunk we need to know the disease by the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=542s"},{"start_seconds":548,"text":"time we executing it right so in reality and so let's say this this chanc","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=548s"},{"start_seconds":557,"text":"produces produces chunk one for the short one right they don't need and so later down the road someone else is","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=557s"},{"start_seconds":564,"text":"applying it in reality we don't need to know receive this is at this point when we create the chunk we do need to know","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=564s"},{"start_seconds":572,"text":"the issues by the time we apply the chunk right and so let's make sense cool","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=572s"},{"start_seconds":579,"text":"and so the way it is done today is the following when when a chunk producers in","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=579s"},{"start_seconds":589,"text":"this case one one of the chunk registers which are zero produces the chunk we already have to distribute small parts of the chunk to every block producer in","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=589s"},{"start_seconds":598,"text":"every shot this is called date availability unless it works right so when they do that they also actually","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=598s"},{"start_seconds":606,"text":"let's use one as an example one is a better example so by the time chain producer created the chunk one the very","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=606s"},{"start_seconds":614,"text":"the very last thing they did before that is they applied chunk 0 right so they just they received chunk 0 they had the state they applied it they know they","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=614s"},{"start_seconds":622,"text":"know they knew post title and they know all the new receipts so when they create a new chunk chunk a tight one they do the following first of all the header of","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=622s"},{"start_seconds":631,"text":"this chunk will contain pre state route which is the post state route for the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=631s"},{"start_seconds":638,"text":"previous chanc but it will also include the receipt the receipt a miracle morkul root of all the receipts produced as of after applying 0 right so we don't","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=638s"},{"start_seconds":647,"text":"know yet the easiest which will be produced after applying one but we do know this is the two produced after playing zero so there is a miracle root of all those receipts and also those this is all sorted by the destination","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=647s"},{"start_seconds":656,"text":"sharda G and so you can prove any subset of those receipts go into this to a single shard in a single miracle proof and so when they when they when they","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=656s"},{"start_seconds":664,"text":"like cut this little chunk into small pieces to send to every validator for data availability together with those","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=664s"},{"start_seconds":672,"text":"little pieces they also send all the receipts relevant to the particular block producer for their chart right so when this little little thing it goes to","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=672s"},{"start_seconds":679,"text":"this chunk producer in the short one all these sheets that go from short zero to third one as of after applying this chunk they will be included in the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=679s"},{"start_seconds":687,"text":"message going to chunk number look","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=687s"},{"start_seconds":697,"text":"forward yes so in time in time so okay so it will not get yeah it will not get","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=697s"},{"start_seconds":706,"text":"include it into this chunk right because this shank and this string they produce concurrent yes right so yeah so you're right so it goes like in time it it will end around here right now what's","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=706s"},{"start_seconds":716,"text":"important is that when you receive a block a particular block and you see chunk headers in it that block is considered orphaned","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=716s"},{"start_seconds":722,"text":"I'm kill for average for every shirt and for every child concluded you either have the food chunk if that's some short you validate or you have this little one","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=722s"},{"start_seconds":731,"text":"part if it's not a short you validate and there are protections in place which protect against lazy behavior so you cannot pretend you know it if you","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=731s"},{"start_seconds":739,"text":"pretend you know it is a good chance you will be slashed there is a protection in place so you will not unorthodox it will not consider the block valid until you","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=739s"},{"start_seconds":747,"text":"have those little one parts for every chunk that is included and that also means that you have all these sheets for every shirt and the receipts are","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=747s"},{"start_seconds":754,"text":"provable because there's a moral route here right in the header that header is on the block and and you have the Merkel","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=754s"},{"start_seconds":762,"text":"proof against that you send all the relevant receipts for the visa for the destination person for with it with the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=762s"},{"start_seconds":771,"text":"with the part that goes to that person yes right and so now by the time I need to apply chanc one I would only apply","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=771s"},{"start_seconds":779,"text":"chunk one if I receive the block which has shrunk one right so if if we draw these chunks well unfortunately I don't use the short idea right so so let's use","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=779s"},{"start_seconds":787,"text":"so it's as 0 as 0 as 0 0 and this is all","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=787s"},{"start_seconds":794,"text":"this one right so this 0 1 and this 1 1 right so","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=794s"},{"start_seconds":802,"text":"this is the chunk 1 for char 0 this is junk 1 for short one I will only apply this chunk when I","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=802s"},{"start_seconds":809,"text":"processed this block I only processed this block if it is not an orphan it is only not an orphan if I have one part for every chunk included including the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=809s"},{"start_seconds":817,"text":"chunk chunk 1 for short 0 and so those by the time I'm playing this chunk I don't know the receipt right so we","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=817s"},{"start_seconds":825,"text":"guarantee that by the time you are playing chunk at height 1 you have all the receipts from all the chunks that","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=825s"},{"start_seconds":831,"text":"included in the same height right so","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=831s"},{"start_seconds":841,"text":"every every block producer this is a subset of shorts they care about as the subset of shorts that they validate but there's another sub sort of short way","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=841s"},{"start_seconds":849,"text":"larger that you don't validate and so you need the full chunk for every shot you fully validate and you need just one part with the receipts for the shirts","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=849s"},{"start_seconds":857,"text":"that you do not validate either way you will have the receipt if you have one part that receipt was sent to you with","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=857s"},{"start_seconds":865,"text":"the Merkel proof if you have the full chunk and you validate the shirt then naturally you applied the previous chunk so you you have this locally because you","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=865s"},{"start_seconds":872,"text":"computed them right so either way you have all the receipts and so that guarantees a that that that gives you","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=872s"},{"start_seconds":880,"text":"one block cross card transactions right oh sorry this is 0 because the the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=880s"},{"start_seconds":888,"text":"receipt which was created as a result of applying this chunk will be processed already as of the time this chunk is","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=888s"},{"start_seconds":896,"text":"applied so this is exactly 1 block between the first and the second hope of the transaction and the same applies if it sends a further cross card","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=896s"},{"start_seconds":904,"text":"transaction it will also be applied on the very next block and moreover we guarantee that pieces don't get lost this is another problem that many block","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=904s"},{"start_seconds":912,"text":"chains face today that the Charlotte block chance is that they don't have any guarantee the digits will be applied here if the receipt is not sent if it's not part of the moral proof that's a","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=912s"},{"start_seconds":921,"text":"/hreul behavior because every other participant in the same short chain they will also apply this chunk they will also get the issues they will also","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=921s"},{"start_seconds":929,"text":"the merkel proof the merkel proof doesn't match the miracle proof included in the header that's easily provable cryptographically and that's a slash whole behavior so everybody will arrive","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=929s"},{"start_seconds":938,"text":"to the same proof every recipient and every other char they they will check against the prove they will know they have all the receipts so uses cannot get","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=938s"},{"start_seconds":944,"text":"lost risk of guaranteed delivery and on the last problem which we're not going to discuss very deeply today is that there is a problem that if all the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=944s"},{"start_seconds":953,"text":"shorts and uses to a single chart that will spend the short ride so we're not going to go very deep into that but this is also partially solved because you can","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=953s"},{"start_seconds":960,"text":"accumulate the receipts but you don't have to apply all of them at once you can put them into the queue and then you just process the first 103 sheets that","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=960s"},{"start_seconds":968,"text":"got into the queue the the earliest and then the only problem is that how you prevent the queue from growing indefinitely and i think the only way to","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=968s"},{"start_seconds":977,"text":"do that is to fail transaction civic useful right so by the time you apply the chunk the queue the destination queue for shard 1 is full you will fail in a transaction that tries to go to","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=977s"},{"start_seconds":985,"text":"third one cool so that covers the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=985s"},{"start_seconds":990,"text":"receipts you have more questions awesome","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=990s"},{"start_seconds":997,"text":"this your guarantee right I mean it","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=997s"},{"start_seconds":1002,"text":"basically allows you to say when we have the chance that we care about or we have","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1002s"},{"start_seconds":1010,"text":"like one part of whatever we not care about yeah but it includes receipts yes that's correct supposed to be like like","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1010s"},{"start_seconds":1017,"text":"this what allows chardon because you care about all the smoke all the shards right and everything else you kind of don't here so it's like a little bit","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1017s"},{"start_seconds":1026,"text":"with the warhead so I have a question one it's actually a little bit of the overhead because if we have a system","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1026s"},{"start_seconds":1035,"text":"where we have many shards and most of the transactions across our transactions it would like let's say we have financial system people just any money","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1035s"},{"start_seconds":1043,"text":"between each other like on your charts right I mean most of the transactions are going to be cross our transactions which means like the content of the blog","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1043s"},{"start_seconds":1053,"text":"of the chunk is going to be half receipts hard half transaction to just drive right the question is do they do","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1053s"},{"start_seconds":1061,"text":"all of the dishes go to the same chart because this one part it doesn't contain all the receipts it only contains receipts which go to the charts that they just receiving person cares about","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1061s"},{"start_seconds":1070,"text":"right so basically care about one charge","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1070s"},{"start_seconds":1076,"text":"then on average all the receipts accumulated from all one part says I do not care about approval gonna be on the","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1076s"},{"start_seconds":1084,"text":"same volume as yes yes so if the system is not skewed if it's well balanced and then you will be receiving as many issues as you see of transactions which is definitely viable it is still a","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1084s"},{"start_seconds":1093,"text":"problem though that if you're assured that the super popular you might be getting way too many receipts that can be solved in many ways that we did not","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1093s"},{"start_seconds":1101,"text":"discuss like you can you can limit how many issues can go to a particular shirt to some constant like you know team 3x","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1101s"},{"start_seconds":1112,"text":"something like one over a number of chars x to you something like that yeah cool more questions no okay so that","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1112s"},{"start_seconds":1121,"text":"covers our first lunch serious thanks everyone for listening","url":"https://www.youtube.com/watch?v=mhJXsOKoSdg&t=1121s"}],"youtube_url":"https://youtube.com/watch?v=mhJXsOKoSdg","url":"https://near-pedia.xyz/videos/mhJXsOKoSdg"}