DAGfans / TranStudy

Study By Translation
https://DAGfans.org
64 stars 40 forks source link

Incentives and Trade-offs in Transaction Selection in DAG-based Protocols #8

Open forchain opened 6 years ago

forchain commented 6 years ago

A translation project collaborating with NPC. I finished the first two paragraphs, you may try the rest.

https://github.com/npc-network/translator-website/issues/9

Any questions just follow this thread

forchain commented 6 years ago

I have recorded the transcript by watching the video as pasted below. If you find anything missing in what noted in ScalingBitcoin, you may reference it. However, there may be some mistakes within, so feel free to ask me or check in the video once entering something hard to understand.


okay okay okay thank you so my name is Yonatan Sompolinsky I'm a PhD student in Hebrew University under the supervision of Aviv Zohar which talked previously and also I'm a co-founder and scientist at DAGlabs which is a commercial effort to implement DAG based protocols and I feel comfortable here to say that we're not doing an ICO ---- it's a regular company okay so this proposal was was prepared together with Yoad Lewenberg my colleague both in Hebrew University and in DAG labs okay so a bit of background about DAG based protocols so the the background to this work is a line of works we've done in the Hebrew University my colleagues again Yoad Lewenberg and Aviv Zohar my supervisor and this idea of block dag is a modification of the layer 1 of a Bitcoin, of blockchain thanks and so it's a generalization of the chain structure of the blockchain and as such okay thanks so it's orthogonal to any layer two solutions so lightning Network and all micropayment channel channels etc so we're scaling up layer 1 you guys are scaling out there two these are complementary solutions and this talk will be a focused on an idea that we develop in the inclusive blockchain paper in 2015 and we kind of revisited these ideas now because we're heading up to to scale up to implement these block DAG protocols so roughly what is a blockchain versus the block DAG so the first difference is that in a chain you maintain a single chain and obviously in a dag you maintain an entire graph of blocks the second a difference would be that in a chain you ignore anything that's off chain any any data that wasn't then appear in the chain whereas in the DAG you use all this information of you you harvest all information from all blocks and the third implication is that in a change in a chain paradigm you try to suppress the throughput so that Forks are rare spontaneous Forks are rare in the system whereas in a block that system Forks are the common phenomena of the system the common development of the system is that many many Forks are created in parallel and as you can imagine this this is essentially a matter of information in a chain paradigm you ignore everything that's off chain in a dag paradigm you use in this entire information and this information can be used for more scalability more security more fairness but the fact that is it can be used to these stuff doesn't mean that every block that protocol uses these stuff so just to drop a name Ethereum a ghost version mostly uses ghost for fairness less for scalability cases just to give an example of a dag based protocol that doesn't use these entire features ok so what's the role to

scaling up layer 1 using Dags the first step would be simply to speed up block creation so instead of one block for 10 minutes as in Bitcoin or one block per 21 seconds as in Ethereum imagine 10 blocks per second 50 blocks per second maybe more so that's step number one and of course the immediate implication is that we have spontaneous forks to the chain many many Forks and so then the second step would be to modify the mining protocol and now instead of every block extending a single chain you want every block referencing these entire blocks all the tips that it sees integrating these Folks into one graph so as you can see you have this massive cool graph this is a DAG directed a static graph so everything seems very simple so far

but we haven't reached yet that final step the third step which is the most crucial one namely extracting a consistent set of transactions from this graph so this graph which contains conflicts many conflicts possibly and we must take this graph and somehow extract from it in order this is the main challenge of a block dag effort and we developed a SPECTRE protocol to address this challenge I actually spoke about SPECTRE two years ago in scaling bitcoin Hong Kong we didn't call it Spectre we call it I think a past future past future something like that so this will not be a talk about SPECTRE and just highlighting that this is the main challenge

in developing unblock that protocol the consistency rule and in light of that I want to clear some misconception that block DAG is not a solution it's merely a framework above which one could design good protocols or bad protocols so you can't just say I'm using a block dag solution this is not defined well and consequently not all block DAGs that are created equal I already mentioned Ethereum uses some notion of a dag partially and other you can design other variants and I like to think of a DAG versus a chain you know the chain is like a slow one single lane road in a small town where's the DAG is a highway super-powerful highway and the first implication of this is that if you don't know what you're doing you'll you'll have a mess okay so you have to somehow think very carefully about what what you do with your DAG hopefully you arrive at a state where you have this ordered Highway everything's clear a large throughput a good utilization of your DAG and if you're very lucky or very thoughtful you can arrive at a protocol which also has fast confirmation times at least for some some transactions and this will be the topic of this talk okay so to wrap up the the preface of this talk scaling up blockchain users using DAGs opens up various challenges so the again the first one in the main one would be consistency rule but once you solve that you have to also address confirmation times storage how much storage do you want miners or full notes to to store and for how long so think of a thousand transactions per second at least 86 gigabytes per day do we want everyone to store this forever or not these are kind of challenges we are addressing fee structure of fairness how to maintain the Decentralization etc etc but in this talk I wanted to focus on just one challenge and this is how to utilize the DAG fully so that the entire throughput or at least we are close to the entire throughput that the DAG can supply so I will show now why this is not a trivial challenge okay so we have two scenarios for that let's say we have imagine many blocks per second right but for simplicity let's say we are two miners in the system just for a moment you're a miner one and I am miner two - and we have four transactions to confirm so I'm creating my block you're creating your block and we are unaware of each other's Block because this is in real time ten blocks per second there's no time to coordinate and there's there's two scenarios here right the first scenario the less optimistic one is the red scenario where you selected the TX 1 TX 2 from the mempool I selected the TX 1 TX 2 From the mempool and what happens in this case is because these transactions are not conflicting they're just a duplication of the same transaction then no harm was done in the sense that these both of these transactions are approved by the system by the DAG however we wasted space okay so two
transactions TX 1 TX 2 took the space of 4 transactions over 2 blocks so this is just a very simple example and of course the optimistic scenario or the green scenario on your left hand side would be that you somehow selected TX 1 TX 2 and I somehow selected TX 3 T X 4 and now we have a good division of the four for transactions covered a spot of four transactions in the block DAG and the main question of our research here is how do we make sure that we are closer to the green area than to the red area namely let's say yes let's assume we have a good block DAG protocol that has a good consistency rule how do we make sure and under what conditions the dag is utilized and transactions not merely duplicated across chains okay so this is the main research question and just to have that to the first proposition of this research is if you don't do anything if you just let miners mind greedily or naively the top transactions that they see in their mem pool then the DAG gains nothing in terms of throughput okay so what you see here is the simulation results just a simple set up generated by Yoad my colleague so what you see is the green curve is the throughput of a DAG under a naive greedy mining policy where every miner selects the top transactions from the mem pool and the yellow curve represents a chain structure
with the same parameters and you can see that the chain throughput and the dag throughput are almost identical so if we miner evilly transactions into blocks dag gains us nothing in terms of throughput it does gain us in terms of confirmation times but I won't touch it now and of course these you can see that these two curves are very far from optimal we can gain much more by the dag and has much more capacity if we were more wise and used more sophisticated schemes to coordinate between miners okay so here's the good news and perhaps the the main thing I want to message to this main message I want to convey to you is that miners are incentivized to some extent to avoid collisions to avoid transaction duplication and to contribute unique transactions and increase the throughput so this is a natural incentive of miners to to contribute to the healthiness of the system and the reason is simple because if we collide on the same transaction if you both choose the same transaction for our blocks then the split will need to split the fee between us as you will get half of the fee or or some other portion I will get the other portion but we can't pay the fee twice right so if some user said I'm willing to pay one milliBitcoin for my transaction and we both embedded this Transaction in our block then only one of us will get a transaction or maybe we can split it but but we won't be able to to extract from the user two milliBitcoin so there is some incentive system to coordinate and to avoid collisions so this is a good news and and now we're heading to a for a more formal a treatment of this problem so I hope the chicken game is a is known to at least most of you the chicken game is a very famous game to model conflicts so you have two parties driving towards each other and heading on collision and the first one to swerve and
chicken out is the chicken and the one to stay right ahead on track is the the Dare and of course if if if I dare and you chicken out then I win vice versa you win but if you both dare then there's a collision not good so the inclusive game in the DAG transaction selection game is quite similar there is some difference which I won't touch on now but it's quite similar right let's say we have TX 1 TX 2 in the mem pool and one of the transaction is is more expensive tx1 it pays us let's say - Two millibitcoins and TX2 pays us only 1 MilliBitcoin and now we need to decide how how to let numbers should be different I'd say tx1 3 milli Bitcoin and TX 2 would be 2 milli Bitcoin and that would be better so if we both the select Tx 1 the most high paying transaction then we will collide and we will need to divide the fee between us but if we both select TX 2 we need to divide a lower fee between us so we have to coordinate some how to select transaction - for you to select TX 1 I will select TX2 - or vice versa this will be the optimal setup so in the game theoretic terminology you have the table the Matrix of payment to the players and every seller corresponds to one scenario and strategies in this game this is the important point you have in game theory pure strategies which is simply which transaction to select and you have mixed strategies which is using randomness to select transactions okay so in a mixed strategy setup I can toss a coin and using the result of this coin I will decide which transactions to select and this is the well established fact in game theory that using randomness we can achieve much better results for all players ok so what this practically means is that we are looking at a set up in a DAG where miners will randomize over the mempool to select the transactions for their blocks so whereas in Bitcoin miners simply selects the top transaction for its block in advance we will have a situation where the best thing for you to do is to randomize over the mem pool according to some probability distribution and use this to maximize your throughput okay so how do we solve this game this this chicken Or this inclusive game as common and game theory there several approaches economic agendas how to approach a game so that the the top left scenario is that adversarial setup where you are a mining pool and you're paranoid and you think everyone just wants to sabotage your your profits everyone just wants you to - your revenues to drop and in that scenario you have a safety level solution which is essentially means I just want to guarantee myself the best response against everyone else that wants to sabotage and lower my profits okay so this is quite adversarial and it does not fit the loving Bitcoin community so we we might consider more more cooperative setups so the selfish setup is the more common one this is a corresponds to the famous Nash equilibrium model where every party pursues its own interests but somehow the invisible hand gain brings us into equilibrium under which no one gains from deviating yes so so this is a common concept there's also a very interesting equilibrium concept invented by Robert Oman he's a novelist from the Hebrew University and this is a correlated equilibrium so still everyone is selfish but we have some signal that enables us some coordination so in terms of mining you can think of a signal as the randomness from previous blocks right so perhaps we can use some randomness from previous blocks to select more wisely transactions to our mempool this is a hope when hope for our research and then there's the most altruistic setup where everyone is playing just for the sake of of the healthiness of the system seriously you can think of it of bitcoins early days as a set up where the only concern of everyone was a maximized social welfare so we had mining pools confirms zero Fee transactions why just to maximize social welfare there were less incentives back then okay so we can visit several of these idea there won't be time to revisit all these solutions but let's let's begin with the maximum Social Welfare this is the most simplest and also the most optimistic and sort of kind atmosphere solution so what's so what would be the maximum Social Welfare let's just let's say all the miners are cooperative they just ask us we don't we don't know how to coordinate but please design a mechanism under which the dag is utilized and we won't collide and we will increase the throughput to the maximum so actually the solution in that's in that case is rather simple and the construction to the miners will be just select the transaction unit in random uniformly from your mem pool so let's say you have six transactions or of course you can have thousands you just toss a fair coin Between them until some threshold and and you accept all transactions uniformly I won't touch to the the threshold is simply what's the capacity of the DAG you can't you can't of course overcome this capacity and it's it's a very famous and very simple result from queuing theory that says that that implies actually that you won't have any collisions in the system so the buckets the transactions will be sparse enough that collisions will be very negligible so essentially you have
maximally utilized dag so again the take-home message here is if everyone's cooperating the best thing the way to utilize the block dag optimally is to flecked? transactions uniformly but of course this is a bit naive and what's the catch so there are two catches first of all this is strategically unstable we're assuming everyone's interested in maximal social welfare this is not always the case but moreover there's a more inherent problem with this approach and this is and this is that it does not allow for differential service to urgent transactions so I can't prioritize transactions as a user I'm unable to signal to miners you know I really need the transactions fast I'm willing to pay more just put it in there I won't be able because they would just pick uniformly from the mempool and I will wait for for a long time so what you see here is everyone waits the same time there are some transactions here and left-hand side area which are never approved but but all those that are approved wait at the same time and you can think of it in the terms of a highway where everyone is stuck in the same traffic okay and you're not sure as a system designer that that's what you want to achieve okay you are more opted to choose a system where there are Express lanes and express lanes simply allow us for some people to say I'm willing to pay more I know there's like taking more riders but assume there's a payment for the express lane at least in some areas so I'm willing to pay more in order to to get to work fast etc so that's a more healthy design of the system and then will you have this curve that says the larger you pay the the faster you get inside so this this is a one thing you want to design a system according to and there's a nice trade-off here which is unfortunate or inevitable I always like Thomas Souls quote there's no there are no solutions there are only trade-offs so what's a trade-off here if you have high utilization of the dag if you if you avoid collisions then essentially you can't serve these Express lanes you can't have prioritized transactions because you you have to signal
to miners to back off from these expensive transactions in order not to collide so this is a this is on the one hand on the one end and on the other extreme if you if you allow for if you allow for fast confirmation times you will inevitably suffer from collisions so what you see here is simply the function of how long have the number of collisions of a transaction as a function of the of the of its waiting time and you see that only transactions that allow themselves to wait a long time the buffer suffer no collisions whereas transaction that want to be confirmed fast will be confirmed by various miners in parallel and will suffer collisions bomb line shorter waiting times for transactions or at least for priority transactions implies more collisions and less utilization of the DAG and this is inevitable and me? to trade off it wisely okay so so with this let me go on to describe the Nash the Nash equilibrium solution so what happens in real world when we have this chicken state of affairs so the the problem here is is intractable so usually in these kinds of game Nash equilibrium is computationally hard to find but the spirit of the Nash equilibrium would be something in the form of if I see you cooperating then I will cooperate but if you are greedy and you always pick the highest-paying transactions for your blocks I will retaliate and I will sabotage you and I will also be greedy and pick the highest-paying as transactions until you back off so I apologize for the militaristic tone but this is a tit-for-tat known strategy there's a family of strategy
tit-for-tat and very interesting to understand how how mining pools will will behave so just think of the you know mining pool as long as it's not anonymous if it's anonymous then of course this is the question mark I put here if the mine pool is somehow hiding its identity then it's it's much it's we're skeptic about whether you can you can penalize you can penalize maybe everyone but this this becomes really very intractable
to understand what happens but but in a world where mining pools do not hide their identity then if a mining pool really will be greedy then the community of other at least of other mining pools will will start sabotaging this pool by colliding with its transactions so it's a very interesting game theoretic framework to think of this sort of situation and also of general situation in the world this chicken dare scenario is not is not unique to two mining a block DAG transactions okay so I said it's intractable to to compute the Nash equilibrium so we did a more modest we achieve a more modest goal namely we computed the Nash equilibrium for the single shot game we only play once what will be the Nash equilibria we have a nice formula I won't go over it now but the good news is it just may be the qualitative message of the Nash you can see here that we pick high paying fees with high probability so if a user wants us to to embed his transactions very fast we he will put a large fee and then we will use we will all sort of collide but not not necessarily you can see that the curve does not reach probability one so even if I'm paying a high fee no one will be too greedy to pick it with height with a certain probability so this is a good feature of the system and more good news for you is that Nash performs quite well meaning the utilization of the dag under a Nash equilibrium so even if everyone is selfish the utilization of the dag is not bad so not that here means around 72% and this on this graph so 70% of the dag contains unique content unique transactions so it's a very surprising result you could have thought that if everyone were selfish then you know we will revert back to the greedy scenario no you won't be you won't be greedy even if you're selfish because you want to randomize over your mempool in order to avoid collisions very good news but still maybe we can improve literalization a bit more another interesting graph that we
must talk about is sorry the quality of service levels so as I said the problem with the maximal social welfare solution is that you can't prioritize transactions so what you see here is the tall gray bars represent the maximum social welfare strategy so everyone waits equally the same time in a very long one and then the blue bars represent the Nash equilibria where you approve less transactions so only transactions with a fee from three here three milli Bitcoin the precise numbers do not matter of course it's just a dummy model but as you as increased the fee you wait less we want you want this feature right we want high paying transactions to pay less and we have other strategies that exponential allergy and if you can discern the yellow bars the very little ones over there they say if everyone's greedy then you will only approve a very small set of transactions from 4.30 etc this is a good a good illustration of the problem of the challenge two more points first of all correlated equilibrium as I said perhaps with coordination between miners we can achieve better utilization than Nash and the the coordination would be using previous blocks randomness okay so instead of tossing a coin with the natural ability we will do something more sophisticated and preliminary result results show that indeed we are able to utilize the dag a better but this needs to be more investigated and last point of a general point about scaling and incentives so selfish mining and Bitcoin selfish mining is a known strategic attack on deviation from the mining protocol and in Bitcoin this attack is really sophisticated it's risky it only works in a long term after two weeks at least and so arguably the reason we didn't see Selfish mining in Bitcoin turn now or at least not in non negligible amount is because playing with your mining node just to withhold your blocks and risking losing it all is too risky and miners won't engage in such a behavior unfortunately in a dag deviating from the mining protocol is much more available to you you just need to select transactions in a certain way or withhold your blocks for a few seconds recall that everything is integrated into the dag right so if if I'm withholding your my block and you created two blocks then I'm not I'm not discarded forever so it's a very it's a much more granular decision how to optimize my mining protocol and the risks are less for the miner but also the results the harm to the system is is marginal relatively marginal so this is in a pointed point and also lazy selfish mining so I have a pool that let's say that it occurs to the mining protocol whatever it is but it doesn't invest in communication infrastructure so it has a low bandwidth deliberately or just by laziness it doesn't propagate blocks fast enough so what's the effect at network again this pool may may not lose too much profits and other miners might be harmed this is a very interesting topic for us so we're investigating it and to wrap up when implementing block DAG protocols incentives really matter so again in Bitcoin the one block for 10 minutes things are are pretty robust at least in the mining at least as you stay in the same chain but in DAG things are very sensitive and with that I will end my talk thank you

SkyeOreo commented 6 years ago

Scaling up layer 1 using DAGs

使用~DAGs~(DAG: 这里s表负数, 不是缩写)扩展第1层

The first step would be to speed up block rate. Instead of 1 block every 10 minutes or 1 block every 21 seconds, imagine 50 blocks per second or maybe more. That's step one. So we need spontaneous forks of the chain. The second step is to modifying the mining protocol where instead of extending a chain, you want to reference previous blocks and all the tips that it sees, and integrating the forks into one graph so that you have this massive cool graph which ~his~is directed acyclic graph. Seems so simple so far.

第一步将提高出块率。相比每10分钟或每21秒生成一个块,设想每秒生成50个块或者更多。这就是第一步。因此我们需要链的自发的分叉。第二步是在你想要引用之前的块以及它看到的所有~提示~(末端: tips是指没有被引用过的新块)的位置修改~挖掘~(挖矿: 专用术语)协议,而不是扩展链,并将分叉集成到一个图中,这样你就可以获得这个非常棒的图,~这个图是它的有向无环图形~(即有向无环图: 这个ScalingBitcoin的脚本有错误, 因为他们也是听录, 所以有好多错误, 也不全, 所以我才自己听了一遍. 如果遇到比较不好理解的地方, 可以参考我上面的译文)。到目前为止似乎很简单。

The third step is the most crucial, though. Which is extracting a consistent set of transactions from this graph. The graph might contain conflicts and you want to extract from it and order it and make it work. This is the main challenge of a blockDAG effort. We developed the SPECTRE method to deal with this as discussed 2 years ago in Hong Kong. The consistency rule is the main challenge.

不过,第三步是最重要的。从该图中提取一组一致的交易。图可能包含~冲突~(冲突的交易),你希望从中提取~冲突~(冲突的交易)并对其进行排序,使其正常工作。这是blockDAG工作的主要挑战。正如两年前在香港讨论的那样,我们提出了~SPECTER~(SPECTRE)方法来解决这个问题。保持交易一致性规则是主要挑战。

I want to clarify that blockDAG is not a solution, it's merely a framework on top of which someone can develop on top of. Consequently, not all blockDAGs are that are created equal I mentioned etheruem ues some notion of a DAG partially. You can design other variants. I like to think of DAG vs chain as chain is slow single one lane road in a small town and a DAG is a highway and the first implicaiton of this is that if you don't know what you're doing, you'll have a ~traffic jam~ mess and you have to think carefully about what you are doing with your DAG. So you want an ordered highway, everything is clear, and high throughput. If you are very lucky, or very thoughtful, you can evolve a protocol with fast confirmations at least for some transactions, which is the topic of this talk.

我想说明一下blockDAG不是解决方案,它只是一个框架,人们可以基于它~发展~(开发)。因此,并非所有的blockDAG都是相同的,我提到过~以太网~(以太坊: 市值第二大的币)部分地使用了一些DAG的概念。你可以设计其他变形。我认为DAG VS 区块链,就好像区块链是一个小镇的单一低速的车道,而DAG是一条高速公路,~这个比喻的最先表明的是如果你不知道自己要做什么,那么你就会在上面遇到交通堵塞,~(这首先意味着如果你不知道你在做什么, 你会弄得一团糟: 看到不懂的地方可以参考我听录的脚本)然后你必须仔细考虑你要在你的DAG上做些什么。所以你想要一个有序的高速公路,一切都很清晰,吞吐量很高。如果你非常幸运或是非常有想法,至少对于某些交易而言,你可以通过快速确认来~演化~(改进: 这里取进化或者改进比较合适)一个协议,这是本次演讲的主题。

To scale up blockchains using DAGs opens up various challenges. The first challenge is the consistency rule. You also have to address confirmations time, how much storage you want miners or full nodes to store and for how long, so think of 1000 tx/second, at least 86 gigabytes per day, do you want to store this forever or not? These are challenges that need to be addressed. Fee structure, fairness, how to maintain decentralization, etc.

使用DAG扩展区块链会带来各种挑战。第一个挑战是一致性规则。你还必须~知道~(处理)确认时间,你希望矿工或~整个节点~(全节点: 专有名词)存储多少空间以及存储多长时间,~因此请考虑1000tx每秒~(设想下每秒1000笔交易: tx指transaction),至少86千兆字节每天,你是否想永远存储~这个~(它们: 通顺点)?这些是需要被解决的挑战,收费结构,公平性,如何维持~权力下放~(去中心化: 专有名词)等。

How do you utilize the DAG fully so that the entire throughput or at least we're close to the entire throughput that the DAG can supply? I will show you why this is not a trivial challenge. We have two scenarios for a DAG. Imagine many blocks per second But for simplicity just say two miners. You're mining 1 and you are mining 2.

如何充分利用DAG的全部吞吐量或至少接近DAG可以提供的全部吞吐量?我会告诉你为什么这不是一个~微不足道~(简单: 通顺点)的挑战。我们有两种DAG情况。设想每秒产生许多块,但为简单起见,只假设有两名矿工。一个是矿工1,另一个是矿工2.

We are mining 4 transactions. We both create blocks because it's real time and there's no time to coordinate and there are two scenarios. The less optimistic scenario is where you select tx 1, tx 2, and I select tx 1, tx 2 from the ~minepool~(mempool) and what happens in this case is that ~cause~(because) these transactions are not ~conflicatin~(conflicting), then no harm was done in the sense that both transactions were approved by the ~systme~(system). However you wasted space. So tx 1 and tx 2 took the space of 4 transactions. So this is just a very simple example and of course the optimistic scenario or the green scenario on your left hand side would be that you somehow selected tx 1, 2, and the other miner picked tx 3, and tx 4. So this is a good outcome.

我们正在挖掘4笔交易。我们都创建了块,因为它是实时的,没有时间进行协调,并且有两种情况。不太乐观的情况是你选择~tx 1~(交易1),~tx 2~(交易2),我也从~矿区~(内存池: 专有名词)中选择~tx 1~(交易1),~tx 2~(交易2),这种情况下会~导致~(因为)这些交易不会发生冲突,那么两者都没有造成任何伤害~由系统批准交易~(,因此, 两笔交易都被系统批准)。然而,你浪费了空间。因此~tx 1~(交易1)和~tx 2~(交易2)占用了四4个交易的空间。这仅仅是一个非常简单的例子,当然以你的角度,乐观一些的情况或者是绿色的情况(左手边的绿色区块: 这里很明显用到了图, 建议从pdf中把相应的图提取出来, 否则读者无法理解)是你以某种方式选择了~tx 1~(交易1),~tx 2~(交易2),而另一个矿工选择了~tx 3~(交易3)和~tx 4~(交易4)。所以这是一个很好的结果。

The main question of our research here is how do we make sure that we are closer to the green area than the red area? Assume we have a good consistency rule and a good blockDAG protocol. How can we make sure that transactions are not duplicated across chains? 我们这里研究的主要问题是我们如何确保我们更接近绿色区域?假设我们有良好的一致性规则和~DAG区块~(区块DAG: 保持一致性, 要么按照你前文那样直接不翻译, 照搬blockDAG, 要么就翻译成blockDAG)协议。我们如何能确保交易不会~跨链~(在多条链之间: 跨链这里没错, 但是由于是专有名词, 容易产生歧义)重复?

If you don't do anything and let miners mine ~greedly~(greedily) the top transactions in their ~minepool~(mempool), then the DAG gains nothing in terms of throughput. We did a simple solution generated by my colleague. The green curve is this throughput of a DAG. By using a greedy mining policy where every miner selects the top transactions from the ~minepool~(mempool). The yellow curve represents a chain structure with the same parameters. The chain throughput and the DAG throughput are almost identical. So DAG gains us nothing in terms of throughput, but it does gain us something in terms of confirmation time. These curves are very far from optimal. We can ain much more-- DAG has more capacity if we were more wise and used a better scheme to coordinate between miners.

如果你不做任何事情而让矿工贪婪地挖掘他们~矿区~(内存池)的~最高~(手续费最高的: 直译成最高, 读者无法理解)交易,那么DAG在吞吐量方面没有任何~收获~(提升: 通顺)。我们做了一个由我的同事提出的简单解决方案。绿色曲线(同样这里需要图)是DAG的吞吐量。通过使用贪婪的~采矿政策~(挖矿策略: 以后统一用挖矿),每个矿工选择矿区的~最高~(手续费最高的)交易。 黄色曲线表示具有相同参数的链结构。链吞吐量和DAG吞吐量几乎相同。所以DAG在吞吐量方面没有给我们带来任何好处,但它确实在确认时间方面有所~收获~(提升: 通顺)。这些曲线远非最佳。我们可以做得更多————如果我们更明智并且使用更好的方案来协调矿工之间,DAG将有更多能力。

So here's the good news and perhaps the main thing I want to message to convey to you. The miners are incentivized to some extent to avoid collisions and avoid tx duplication and contribute unique transactions and increase throughput. So this is a natural incentive of miners to contribute to the healthiness of the system.The reason is simple. If we collide in th same system, if we choose the same tx for our blocks, then we need to split the fee, you will get half of the fee or some other portion I will get the other portion but we can't pay the fee twice. And we both embedded the tx in our block. only one of us will get the fee or maybe we will split it but we won't be able to extract the entire fee twice. So there's incentive to coordinate and avoid collisions.

所以这是好消息,也许是我想传达给你的主要内容。矿工们在某种程度上受到激励,以避免冲突和重复,并提供独特的交易和提高吞吐量。因此,~矿工的自然激励~(这种对矿工天然的激励)有助于系统的健全。原因是简单的。如果我们在同一系统中发生冲突,如果我们为我们的区块选择相同的~tx~(交易),那么我们需要~分摊费用~(平分手续费: 翻译成分摊费用给人的感觉是矿工挖矿还要给人手续费, 事实上矿工是收取手续费的),你将~分担一半的费用~(收取一半的手续费),而我将在其他部分~分担~(收取)另一半~费用~(手续费),但我们不能支付两次费用。(由于)我们都在我们的块中加入了~tx~(这笔交易)。我们中只有一个人会收取费用,或者我们会~分开~(平分)它,但我们将无法提取全部费用两次。因此,~协调和避免冲突是激励性的~(是存在激励来协调和避免冲突的)。

SkyeOreo commented 6 years ago

The sentences (in paragraph 3 and 8 with ...) may be not accurate...

SkyeOreo commented 6 years ago

Chicken game

胆小鬼博弈

And now we're headed to a more formal treatment of this problem. I hope the chicken game is known to most of you. It's a famous game to model conflicts. You have two parties driving towards each other and heading to collision. And the first one to swerve and chicken out is the chicken and the one to stay the course is the winner and daredevil.And of course, if either you chicken out then the other party wins. And if we both dare then there's a collision. The transaction selection game in blockDAG is quite similar. We have tx1, tx2 in the mem pool and one of the transactions is more expensive (tx1) let's say it pays 2 millibitcoins and tx2 pays 50% as much. So now we have to decide how to let numbers should be different I'd say tx1, 3 millibitcoin and tx2 would be 2 millibitcoin.If we both select tx1, the most high paying transaction, we will collide and need to divide the fee between us. But if we both select tx2, we need to divide a lower fee between us. So we need to coordinate and select the transactions. This would be the optimal setup. ~The strategy in this game- you have game theory pure strategy which is which transaction to select or you can use randomness to pick transactions.~ (Strategies in this game is the important point you have in game theory. Pure strategies which is simply which transaction to select, and you have mixed strategies which is using randomness to select) In a mixed strategy setup I can toss a coin and then decide which transactions to select. In game theory, using randomness you can achieve much better results for all players. In practical terms, we are looking at setup in a DAG where miners will randomize over the mempool to select transactions. In bitcoin, a miner selects the top transactions. But in a DAG, the best thing for you to do is to randomize over the mempool according to some distribution and then use this to maximize your throughput.

而现在我们正在对这个问题进行更~正式~(形式化: 专有术语, 可以简单理解为论证)的处理。我~希望~(猜)大多数人知道胆小鬼博弈。这是一个模拟冲突的著名游戏。你有两队,都朝着对方行驶并(即将)碰撞。第一个转向(并)胆怯的人是胆小鬼,另一个继续行驶的人是胜利者并且是胆大妄为的。当然,如果一队退缩,那么另一队就会赢。如果两队都敢一直前进,那么就会有碰撞。blockDAG中的交易选择游戏与胆小鬼博弈非常相似。我们在内存池中有交易1和交易2,其中一个交易是贵一些的(交易1)假设它支付 2毫比特币的手续费,交易2只支付交易1的50%。所以现在我们必须决定如何让数字变得不同,假设交易1支付3豪比特币的手续费,交易2支付2豪比特币的手续费。如果我们都选择交易1,支付最高手续费的交易,我们会冲突并且我们之间需要平分手续费。但是如果我们都选择了交易2,我们之间需要平分一笔更低的手续费。所以我们需要协调和选择交易。这将是最佳方案。~在这个游戏中的策略————你有游戏的纯理论策略,选择哪个交易或你可以使用随机选择交易。~ (在博弈论中, 博弈策略是非常重要的, 纯策略只是简单地选择交易, 而你也可以使用混合策略来随机选择: 纯策略和混合策略是博弈论中的两种策略https://zh.wikipedia.org/wiki/%E7%AD%96%E7%95%A5_(%E5%8D%9A%E5%BC%88%E8%AB%96)) 在混合策略方案中,我可以掷硬币,然后决定选择哪些交易。在博弈论中,使用随机性可以为所有玩家获得更好的结果。实际上,我们正在寻找DAG中的方案,~矿工将通过~(让矿工从: 通顺)内存池随机选择交易。在比特币中,矿工选择手续费最高的交易。但是在DAG中,最好的办法是根据某些分布随机~化内存池~(从内存池中选择交易: 通顺),然后使用它来最大化吞吐量。

How do we solve this chicken game? In game theory, there are several approaches. The top left, scenario is that there's adversarial setup. You are a mining pool, you are paranoid, you think everyone is going to sabotage your profits and they want your revenue to drop. In that scenario, your safe solution is that you just want to guarantee yourself the best response against everyone else that wants to sabotage me and lower my profits. This is quite adversarial and does not fit loving bitcoin community so we might consider more cooperative setups. The selfish setup is a more common one, which is more similar to the Nash equilibrium model where every party pursues their own interest but somehow the invisible hand brings us to equilibrium under which nobody gains from deviating. This is a common concept. There's also an interesting equilibrium concept invented by Robert Oman he's a novelist from the Hebrew University and this is coordinated equilibrium where everyone is selfish but we have signal for some coordination and in mining the signal could be the randomness from previous blocks. ~Perhaps we can use the random beacon randomness to more wisely accept transactions into our mempool or block~ (Perhaps we can use some randomness from previous blocks to select more wisely transactions to our mempool). And then most optimistic, everyone is playing just for the sake of the health of the system. You can think of bitcoin's early day as a setup as where the only concern of everyone was to maximize social welfare, and miners were confirming zero-fee transactions and there were less incentives back then. block.

我们如何解决胆小鬼博弈?在博弈论中,有几个方法。左上角的方法是对抗性的方法。你是一个~采~矿池,你~是偏执的~(很偏执: 通顺),你认为每个人都会破坏你的利润,他们希望你的收入下降。在这种情况下,~您~(你: 一致)的安全解决方案是,~您~(你: 一致)只是想保证自己对其他想要破坏我并降低利润的人做出最好的回应。这是充满对抗性的,不适合和谐的比特币社区,所以我们可能会考虑更多合作性的方法。利己方法是一个更常见的方法,与纳什均衡相似,每个团体都追求自己的利益,但不知何故,无形的手把我们带到了平衡之~下~(中: 通顺),没有人从~偏离~(违规: 通顺)中获益。这是一个常见的概念。罗伯特·阿曼(Robert Oman)提出了一个有趣的均衡概念,他是希伯来大学的小说家。这是(个)协调(的)均衡,每个人都是利己的,但我们有一些协调的信号,而在挖矿过程中,信号可能是先前区块(生成)的随机值。~也许我们可以使用随机信标更明智地接受我们的内存池或块中的事务~(也许我们可以使用上个区块生成的随机数来更明智地选择交易到内存池: 这里这个random beacon 非常晦涩, 所以应该参考我听录的内容)。 然后最乐观的是,每个人都只是为了系统的健康而参与。~您可以将比特币的早期日期视为一个方法,因为每个人唯一关心的是最大限度地提高社区福利和矿工们确认零费用交易~(你可以设想下早期比特币的情景, 每个人唯一关心的就是最大限度地提高社区福利, 并且矿工也会去确认零手续费的交易: 注意理解这句话的意思)。当时的激励措施较少。

SkyeOreo commented 6 years ago

Max social welfare

最大化社区福利

We can visit several of these ideas but let's begin with max social welfare. This is the simplest and most optimistic. What would be the solution here? All the miners are cooperating, they just ask us, we don't know how they coordinate, there's a design mechanism undre which the DAG is utilized and we won't collide and the throughput is at maximum. The solution in this case is rather simple. The construction to the miners would be just select a transaction in uniform distribution from your mempool, so let's say you have 6 transactions or thousands, you do this by tossing a fair coin between them until some threshold, and you accept all transactions uniformy. The threshold is what's the capacity of the DAG, you can't overcome this capacity, and it's very famous and simple result from queueing theory that says that you won't have any collisions in the system. The buckets of transactions would be sparse enough that collisions will be negligible. This setup of course is a bit naive. There's two catches.

我们可以研究其中的几个想法,但让我们从最大的社区福利开始。这是最简单和最乐观的情况,这里有什么解决方案?所有的矿工都在合作,他们只是问我们,我们不知道他们如何协调,有一个基于DAG设计的机制,使我们不会碰撞,吞吐量达到最大。在这种情况下,解决方案相当简单。对矿工的建设只是从你的内存池中选择统一分配的交易。所以假设你有6笔交易或是数千笔,你都可以通过在它们之间抛出一个公平的硬币直到达到某个阈值来实现这一点,并且你接受所有交易统一。阈值是DAG的容量,你不能超过这个容量。这是一个非常着名且非常简单的排队理论结果,它说这实际上意味着你不会在系统中发生任何冲突。交易桶将足够稀疏时冲突可以忽略不计。这个方法当然有点幼稚。有两次捕获。

This is strategically unstable. We're assuming that everyone is maximizing social welfare and this is not always the case. There's a more inherent problem with this approach which is that it does not allow for differential service to urgent transactions. You can't prioritize transactions by fees. So I am not able to signal to miners that I need this tx faster, I am willing to pay more. So if they are not picking transactions by fees, then everyone waits about the same time. And some transactions will never be approved. You can think of this as the highway where everyone is stuck in the same traffic. As a system designer, is that really what you want to achieve? You want a system that has express lanes, where people are willing to pay more. Assume there's a payment for the express lane, of course. They are willing to pay more to get to their destination faster. And then you will have this curve that says the larger you pay, the faster you get inside. So this is one thing you want to design the system according to.

这在战略上是不稳定的。我们假设每个人都在最大化社区福利,但事实并非如此。这种方法存在一个更固有的问题,即它不允许对紧急事务进行差别服务。你无法按手续费确定交易的优先顺序。因此,我无法向矿工发出信号,表示我需要更快地完成交易并且我愿意支付更多手续费。因此,如果他们不按手续费选择交易,那么每个人都会在在同一时间等待。有些交易永远不会被确认。你可以将此视为每个人都陷入同一交通环境的高速公路。作为系统设计师,你真正想要实现的目标是什么?你想要一个人们愿意支付更多手续费拥有快车道的系统。假设有快车道付款,当然,他们愿意支付更多手续费以更快地到达目的地。然后你会得到这条曲线,说明你支付的越多,你就越快开始完成交易。所以这是你设计一个系统所要参考的一件事。

Other strategies

其他策略

If you have high utilization of the DAG with collision avoidance, then you can't serve the express lane and can't have prioritized transactions. You need them to back off from expensive transactions so that they don't collide. And on the other extreme, if you allow for fast confirmation times, then you will inevitably suffer from collisions. So what you see here is simply the function of how long have the numbers of collisions of a transaction as a function of the of the of its waiting time. Only transactions that wait a long time in the buffer suffer no collisions. Transactions that want to be confirmed fast will suffer collisions and would need a higher fee.

如果你对具有避免冲突的DAG有高​​利用率,那么你无法提供快车道服务,也无法确定交易优先级。你需要通知矿工们退出支付费昂贵的交易,这样他们才不会发生冲突。另一个极端,如果你允许快速确认时间,那么你将不可避免地遇到冲突。所以你在这里看到的只是交易冲突的数量与其等待时间的函数有多长的函数。只有在缓冲区中等待很长时间的交易才会发生冲突。想要快速确认的交易将遇到冲突,并且需要更高的手续费。

In the chicken dare situation, what happens in the real world? The problem here is intractable. Usually in these games, nash equilibrium is hard to find. But the spirit of Nash equilibrium is something in the form of if I see you cooperating, then I will cooperat. But if you are greedy and you are always picking the highest transactions for your block, then I will also be greedy and pick the highest paying transactions. I apologize for the militaristic tone, but this is tit-for-tat strategy. And it helps understand how mining pools will behave.

在胆小鬼博弈的情况下,在现实世界中会发生什么?(指的是胆小鬼博弈的理论还是其中不转向退缩的方法)这个问题是棘手的。通常在这些游戏中,很难找到纳什均衡。但是纳什均衡的精髓就是我看到你打算合作,那么我就会合作。但是如果你贪婪而且你总是为你的区块选择最高手续费的交易,那么我也会是贪婪的并选择手续费最高的交易。我为军国主义的语气道歉,但这是针锋相对的策略。它有助于了解矿池的行为方式。

In a world where mining pools don't hide their identity, then other mining pools will start sabotaging that pool by colliding with their transactions. It's an interesting scenario and problem. Chicken dare is not unique to mining DAGs.

在矿池不隐藏其身份的世界中,其他矿池将开始通过与其交易冲突来破坏该池。这是一个有趣的方法和问题。胆小鬼博弈不是采矿DAG独有的。

We did a more modest goal-- namely, we computed the nash equilibrium for the single shot game. We only played once, what would be the nash equilibrium with this nice formula? The good news-- the qualitative message of the nash you can see here that we picked high paying fees with high probability. So if a use wants to embed his transaction fast, he will put a large fee, but then we will all sort of collide but not necessarily. The curve does not reach probability 1. Even if I am paying a high fee nobody will be greedy enough to pick it with certain probability. More good news for you is that nash performs quite well. The utilization of the DAG under nash equilibrium even if everyone is selfish, it wouldn't be so bad. It's around 72% on this graph. So 70% of the graph ocntains unique content and unique transactions. It's a surprising result. If everyone was selfish then we would revert back to the greedy scenario, you wouldn't be greedy even if you're selifhs because you want to randomize over your mempool to avoid collisions.

我们做了一个更适中的目标——即,我们计算了单发射击的纳什均衡。我们只玩了一次,这个漂亮的公式会有什么样的纳什均衡?好消息——你可以在这里看到纳什的定性信息,我们很有可能选择高额手续费的交易。因此,如果一个用户希望快速嵌入他的交易,他将支付大笔手续费,但随后我们有可能会发生冲突但不一定。曲线未达到概率1。即使我支付高额手续费,也没有人会贪婪地以一定的概率选择它。对你来说更好的消息是,纳什均衡的表现相当不错。在纳什均衡下使用DAG即使每个人都是自私的,也不会那么糟糕。在这张图上,它大概是72%。因此,70%的图表只能获得独特的内容和独特的交易。(没理解这句话)这是一个令人惊讶的结果。如果每个人都是自私的,那么我们会回到贪婪的方法,即使你是自私的也不会贪婪,因为你想随机化你的内存池以避免冲突。

SkyeOreo commented 6 years ago

Quality of service

服务质量

Can we improve utilization a bit more? Another interesting graph we must talk about is the quality of service level. As I said, the problem with the maximum social welfare solution is that you can't prioritize transactions. Here the tall grey bars represent max social welfare strategy. Everyone waits the same time. And then the blue bars represent the nash equilibrium where you approve less transactions- only those that have 3 millibitcoin and those exact numbers do not matter of course, it's a dummy model. As you increase the fee, you wait less. We want this feature. We want high-paying transactions to wait less. And we have other strategies like exponential strategy. If everyone is greedy, then you would only approve a small set of transactions. This is a good illustration of the challenge.

我们可以提高一点利用率吗?我们必须讨论的另一个有趣的图表是服务质量水平。正如我所说,最大的社区福利解决方案的问题是你不能划分交易的优先级。这里高的灰色条形代表了最大的社区福利策略。每个人都在等待同一时间。然后蓝色条代表纳什均衡,你批准的交易较少 ——只有那些有3毫比特币的交易,那些确切的数字当然无关紧要,它是一个虚拟模型。随着你增加手续费,你等待的时间更少。我们想要这个功能。我们希望高薪交易而等待时间减少。我们还有其他策略,如指数策略。如果每个人都是贪婪的,那么你只会批准一小部分交易。这是挑战的一个很好的例证。

Correlated equilibrium

相关均衡

Perhaps with coordination between miners we can achive better results than nash. We could use previous block's randomness. Preliminary results show that we are able to utilize the DAG better. Needs further investigation.

也许通过矿工之间的协调,我们可以获得比纳什均衡更好的结果。我们可以使用前一个块的随机值。初步结果表明我们能够更好地利用DAG。需要进一步调查。

Scaling and incentives

扩展和激励

In bitcoin selfish mining is a known attack and deviation on the protocol. It's risky, it only works in the long term. And so arguably the reason why we didn't see selfish mining until now or at least not in notable amounts was that playing with your mining node just to withhold your blocks and risk losing it all is too risky and miners wont engage in such behaior. Unforotunately in a DAG, mining from the mining protocol is much more available to you, you just need to select transactions in a certain way or hold your blocks for a few seconds. So if I am withholding my block for 2 bloks, that's not going to hurt me. It's a much more granular decision for how to optimize my mining, and the risks for the miner are less. The harm to the system is relatively marginal. Also lazy selfish mining is another concern- it might not have communication infrastructure either deliberately or by laziness and doesn't propagate blocks to the network. This pool might not lose too much profit and other miners might be harmed, this is an interesting topic for us so we're investigating it.

在比特币中,自私的采矿是一种已知的攻击和对协议的偏差。它有风险,只能长期才有效。因此可以说,为什么我们直到现在才看到自私的采矿,或者至少没有显着的数量,因为与你的采矿节点一起只是为了扣留你的区块并且冒着失去一切的风险太冒险,矿工们不会参与这样的行为。幸运的是,在DAG中,从采矿协议中采矿更加适合您你,你只需要以某种方式选择交易或者将块保持几秒钟。因此,如果我扣留了我的块中2个,那不会对我造成损失。对于如何优化我的采矿来说,这是一个更为细化的决策,并且矿工的风险更小。对系统的危害相对较小。懒惰的自私采矿也是另一个问题——它可能没有故意或懒惰的通信基础设施,也不会将块传播到网络。这个池可能不会损失太多的利润而其他矿工可能会受到伤害,这对我们来说是一个有趣的话题,所以我们正在研究它。

When implementing blockDAG protocols, the incentives really matter. Bitcoin has 1 block every 10 minutes. Things are are pretty robust at least in the mining at least as you stay in the same chain but in DAG things are very sensitive.

在实施blockDAG协议时,激励措施确实很重要。比特币每10分钟产生1个块。至少在采矿中至少当你留在同一个链条但在DAG时,事情是非常敏感的。至少在你停留在同一个链中采矿,激励措施是非常强大的,但在DAG中,激励措施是非常敏感的。

SkyeOreo commented 6 years ago

Max social welfare

最大化社区福利

We can visit several of these ideas but let's begin with max social welfare. This is the simplest and most optimistic. What would be the solution here? All the miners are cooperating, they just ask us, we don't know how they coordinate, there's a design mechanism undre which the DAG is utilized and we won't collide and the throughput is at maximum. The solution in this case is rather simple. The construction to the miners would be just select a transaction in random uniform distribution from your mempool, so let's say you have 6 transactions or thousands, you do this by tossing a fair coin between them until some threshold, and you accept all transactions uniformy. The threshold is what's the capacity of the DAG, you can't overcome this capacity, and it's very famous and simple result from queueing theory that says that you won't have any collisions in the system. The buckets of transactions would be sparse enough that collisions will be negligible. This setup of course is a bit naive. There's two catches.

我们可以研究其中的几个想法,但让我们从最大的社区福利开始。这是最简单和最乐观的情况,这种情况有什么解决方案?所有的矿工都是合作的,他们只是问我们,我们不知道他们如何协调,有一个基于DAG设计的机制,使我们不会碰撞,吞吐量达到最大。在这种情况下,解决方案相当简单。对矿工的建设只是从你的内存池中选择统一随机分配的交易,所以假设你有六笔交易,当然,可以有成千上万的交易,你都可以通过在它们之间抛出一个公平的硬币直到达到某个阈值来实现这一点,并且你接受所有交易统一。阈值是DAG的容量,你不能超过这个容量。这是一个非常着名且非常简单的排队理论结果,它说这实际上意味着你不会在系统中发生任何冲突。交易分组足够稀疏时碰撞可以忽略不计。当然,这个方法有点幼稚。这个方法有两个缺点。

This is strategically unstable. We're assuming that everyone is maximizing social welfare and this is not always the case. There's a more inherent problem with this approach which is that it does not allow for differential service to urgent transactions. You can't prioritize transactions by fees. So I am not able to signal to miners that I need this tx faster, I am willing to pay more. So if they are not picking transactions by fees, then everyone waits about the same time. And some transactions will never be approved. You can think of this as the highway where everyone is stuck in the same traffic. As a system designer, is that really what you want to achieve? You want a system that has express lanes, where people are willing to pay more. Assume there's a payment for the express lane, of course. They are willing to pay more to get to their destination faster. And then you will have this curve that says the larger you pay, the faster you get inside. So this is one thing you want to design the system according to.

这在战略上是不稳定的。我们假设每个人都在最大化社区福利,但事实并非如此。这种方法本身存在一个问题,即它不允许对紧急事务进行差别服务。你无法按手续费确定交易的优先顺序。因此,我不能告诉矿工,我需要更快地完成交易并且我愿意支付更多手续费。因此,如果他们不按手续费选择交易,那么每个人都会在同一时间等待。有些交易永远不会被确认。你可以将此视为每个人都处于同一交通环境的高速公路。作为系统设计师,你真正想要实现的目标是什么?你想要的系统是人们愿意支付更多手续费拥有快车道。假设快车道需要付款,他们愿意支付更多费用以更快地到达目的地。然后你会得到这条曲线,说明你支付的越多,你就越快开始完成交易。所以这是你设计的系统所要参考的一个方面。

Other strategies

其他策略

If you have high utilization of the DAG with collision avoidance, then you can't serve the express lane and can't have prioritized transactions. Because you need signal to miners to back off from expensive transactions so that they don't collide. And on the other extreme, if you allow for fast confirmation times, then you will inevitably suffer from collisions. So what you see here is simply the function of how long have the numbers of collisions of a transaction as a function of the of the of its waiting time.挖矿 Only transactions that allow themselves to wait a long time the buffer suffer no collisions. Transactions that want to be confirmed fast will suffer collisions and would need a higher fee.

如果你有很高的DAG利用率,并且可以避免碰撞,那么你无法提供快车道服务,也无法确定交易优先级。因为你需要通知矿工们退出高手续费的交易,这样他们才不会发生碰撞。另一个极端,如果你允许快速确认时间,那么你将不可避免地遇到冲突。*所以你在这里看到的只是与交易冲突数和其等待时间的函数有关的函数。只有允许等待很长时间的交易,在缓冲区中不发生碰撞。想要快速确认的交易将遇到碰撞,并且需要更高的手续费。

In the chicken dare situation, what happens in the real world? The problem here is intractable. Usually in these games, nash equilibrium is hard to find. But the spirit of Nash equilibrium is something in the form of if I see you cooperating, then I will cooperat. But if you are greedy and you are always picking the highest transactions for your block, then I will also be greedy and pick the highest paying transactions. I apologize for the militaristic tone, but this is tit-for-tat strategy. And it helps understand how mining pools will behave.

在胆小鬼博弈的场景下,在现实世界中会发生什么?这个问题是棘手的。通常在这些游戏中,很难找到纳什均衡。但是纳什均衡的精髓就是如果我看到你打算合作,那么我就会合作。但是如果你贪婪而且你总是为你的区块选择最高手续费的交易,那么我也会是贪婪的并选择手续费最高的交易。我为自己军国主义的语气道歉,但这是针锋相对的策略。它有助于了解矿池的行为方式。

In a world where mining pools don't hide their identity, if a mining pool really will be greedy, then other mining pools will start sabotaging that pool by colliding with their transactions. It's an interesting game theoretic framework. Chicken dare is not unique to two mining a blockDAG transactions.

在矿池不隐藏其身份的世界中,如果一个挖矿池是贪婪的,其他矿池将开始通过与贪婪挖矿池的交易碰撞来破坏该池。这是一个有趣的博弈论框架。胆小鬼博弈并不是只满足两个矿工挖掘一个blockDAG交易的情况。

We did a more modest goal-- namely, we computed the nash equilibrium for the single shot game. We only played once, what would be the nash equilibrium? The qualitative message of the nash you can see here that we picked high paying fees with high probability. So if a use wants to embed his transaction fast, he will put a large fee, but then we will all sort of collide. The curve does not reach probability 1. Even if I am paying a high fee nobody will be greedy enough to pick it with certain probability. More good news for you is that nash performs quite well. The utilization of the DAG under nash equilibrium even if everyone is selfish, it wouldn't be so bad. It's around 72% on this graph. So 70% of the graph obtains unique content and unique transactions. It's a surprising result. If everyone was selfish then we would revert back to the greedy scenario, you wouldn't be greedy even if you're selifhs because you want to randomize over your mempool to avoid collisions.

我们做了一个更适中的目标——即,我们计算了单发射击的纳什均衡。我们只玩了一次。什么是纳什均衡?你可以看到纳什均衡的定性信息,我们很有可能选择高额手续费的交易。因此,如果一个用户希望快速嵌入他的交易,他将支付大笔手续费,但随后我们有可能会发生冲突。曲线未达到概率1。即使我支付高额手续费,也没有人会贪婪地以一定的概率选择它。对你来说更好的消息是,纳什均衡的表现相当不错。在纳什均衡下使用DAG,即使每个人都是自私的,也不会那么糟糕。在这张图上,它大概是72%。因此,图表中显示70%能获得唯一的内容和唯一的交易。这是一个令人惊讶的结果。如果每个人都是自私的,那么我们会回到贪婪的方法,即使你是自私的也不会贪婪,因为你想随机化你的内存池以避免碰撞。

2018-07-13 12 00 38

Quality of service

服务质量

Can we improve utilization a bit more? Another interesting graph we must talk about is the quality of service level. As I said, the problem with the maximum social welfare solution is that you can't prioritize transactions. Here the tall grey bars represent max social welfare strategy. Everyone waits the same time. And then the blue bars represent the nash equilibrium where you approve less transactions- only those that have 3 millibitcoin and those exact numbers do not matter of course, it's a dummy model. As you increase the fee, you wait less. We want this feature. We want high-paying transactions to wait less. And we have other strategies like exponential strategy. If everyone is greedy, then you would only approve a small set of transactions. This is a good illustration of the challenge.

我们可以提高一点利用率吗?我们必须讨论的另一个有趣的图表是服务质量水平。正如我所说,最大的社区福利解决方案的问题是,你不能划分交易的优先级。这里高的灰色条形代表了最大的社区福利策略。每个人都在等待同一时间。然后蓝色条代表纳什均衡,你批准的交易较少——只有那些有3毫比特币的交易,那些确切的数字当然无关紧要,它是一个虚拟模型。随着你增加手续费,你等待的时间更少。我们想要这个特征。我们希望交易手续费增加而等待时间减少。我们还有其他策略,如指数策略。如果每个人都是贪婪的,那么你只会批准一小部分交易。这是挑战的一个很好的例证。

2018-07-13 1 11 12

Correlated equilibrium

相关均衡

Perhaps with coordination between miners we can achive better results than nash. We could use previous block's randomness. Preliminary results show that we are able to utilize the DAG better. Needs further investigation.

也许通过矿工之间的协调,我们可以获得比纳什均衡更好的结果。我们可以使用前一个块的随机值。初步结果表明我们能够更好地利用DAG。需要进一步调查。

Scaling and incentives

扩展和激励

In bitcoin selfish mining is a known attack and deviation on the protocol. It's risky, it only works in a long term after two weeks at least. And so arguably the reason why we didn't see selfish mining until now or at least not in notable amounts was that playing with your mining node just to withhold your blocks and risk losing it all is too risky and miners wont engage in such behaior. Unforotunately in a DAG, mining from the mining protocol is much more available to you, you just need to select transactions in a certain way or hold your blocks for a few seconds. So if I am withholding my block for 2 bloks, that's not going to hurt me. It's a much more granular decision for how to optimize my mining, and the risks for the miner are less. The harm to the system is relatively marginal. Also lazy selfish mining is another concern- it might not have communication infrastructure either deliberately or by laziness and doesn't propagate blocks to the network. This pool might not lose too much profit and other miners might be harmed, this is an interesting topic for us so we're investigating it.

在比特币中,自私的挖矿是一种已知的攻击和对协议的偏离。它有风险,它至少在两周后才能长期使用。因此可以说,为什么我们直到现在才看到自私的挖矿,或者至少没有显着的数量,因为挖矿节点只是为了扣留你的区块而冒着失去一切的风险太大,矿工们不会参与这样的行为。不幸运是,在DAG中,从挖矿协议中挖矿更加适合你,你只需要以某种方式选择交易或者将块扣留几秒钟。因此,如果我扣留了我的块中2个,那不会对我造成损失。对于如何优化我的挖矿协议来说,这是一个更为细化的决策,并且矿工的风险更小。对系统的危害相对较小。懒惰的自私挖矿也是另一个问题——它可能是故意或因低速的通信设备,没有及时将块传播到网络。这个池可能不会损失太多的利润而其他矿工可能会受到伤害,这对我们来说是一个有趣的话题,所以我们正在研究它。

When implementing blockDAG protocols, the incentives really matter. Bitcoin has 1 block every 10 minutes. Things are are pretty robust at least in the mining at least as you stay in the same chain but in DAG things are very sensitive.

在实施blockDAG协议时,激励措施确实很重要。比特币每10分钟产生1个块。至少在挖矿中至少当你留在同一个链条但在DAG时,事情是非常敏感的。至少在你停留在同一个链中挖矿,激励措施是非常强大的,但在DAG中,激励措施是非常敏感的。

SkyeOreo commented 6 years ago

https://github.com/DAGfans/TranStudy/blob/master/Blogs/Incentives%20and%20Trade-offs%20in%20Transaction%20Selection%20in%20DAG-based%20Protocols

SkyeOreo commented 6 years ago

https://dagfans.org/blog/2018/07/13/Incentives-and-Trade-offs-in-Transaction-Selection-in-DAG-based-Protocols.html