WeiDai MCD upgrade path and new features!

The most anticipated DeFi event of the year is upon us: MakerDAO is upgrading Dai to a multi-collateral system, pending a vote on 18 November 2019, 16:00 UTC.

This article is aimed at two audiences: those who are new to WeiDai and those who hold what is now the Sai version of WeiDai and wish to understand the upgrade steps they need to take. Before getting into shepherding the early adopters, we’ll look at some changes to WeiDai that are going give it a bit more thriftpower.

If you’re brand new to WeiDai, check out the next evolution in stablecoins.

Before carrying on, let’s settle on some naming conventions to make the read easier. MakerDAO is changing the name of the Ether only version of Dai to Sai. As of the MCD launch, the new multicollateral Dai will just be called Dai. The ‘S’ in Sai refers to the single collateral: Eth.

Since WeiDai wraps Dai, we’ll re-use this convention for familiarity. In this article, the version of WeiDai that wraps the version of Dai which is going to be called Sai from November 18th will be referred to as WeiSai. WeiDai will refer to the new wrapper of Dai. With that nomenclature detour out of the way, let’s see what WeiDai promises in this next exciting round of DeFi.

WeiDai holders will automatically benefit from the DSR!

Courtesy of Michael Longmire, Unsplash

In WeiSai, the Dai used to create WeiDai was deposited into a Reserve smart contract by the Patience Regulation Engine. Think of the Reserve as analogous to the vault that held gold during the gold standard. The Reserve could then report the redeem rate as the Dai in reserve divided by the total supply of WeiSai. If the Dai in reserve increases, the redeem rate increases. Similarly if the WeiSai in circulation decreases through burning, the redeem rate increases. The driving purpose of WeiSai was to act as a proof of concept for the power of burning as an incentive for thrifty behaviour and indeed it was a success: In the first few weeks of existence, the WeiSai redeem rate grew by eighteen percent! That’s quite a return for early adopters. Based on feedback, users were happy to use it as a savings vehicle and one user in particular managed to time his exit just in time to scoop up Bitcoin on the cheap before a bull run.

The story of burning doesn’t end there. Indeed thriftcoin burning is about to go through a very exciting phase when the first upcoming WeiDai powered dapp encourages “mutually beneficial burning” that all holders will benefit from as a positive externality. The WeiDai community will then self select into speculators and thrifty holders. Natural fragmentation along the lines of risk aversion of this kind is very healthy for the growth of a dapp ecosystem as I’ve written about before.

Before the era of ambient burning dawns, one or two people eager for an even faster growth in the redeem rate have pointed out that if the redeem rate grows from increasing the Reserve holding of Dai, wouldn’t it make sense to plug that Reserve into a DeFi dapp like Compound.finance to earn interest (WeicDai)? While this is an obvious redeem rate hack, it does bring in more dependencies and increases the overall fragility of WeiDai, somewhat. A system is only as secure as the systems it relies on. For instance, the software industry is only as robust as the underlying electricity and internet providers and no more so. Each layer added to a stack increases dynamism at the cost of systemic fragility.

WeiSai and WeiDai are dependent on the healthy workings of the Dai Stablecoin System and Ethereum in general. Beyond that, nothing else on Ethereum can bring WeiDai down. Fortunately, in addition to MC Dai, Maker is launching a Dai Savings Rate (DSR) which is intrinsic to the very operation of Dai. Holders of Dai can now deposit their Dai into a Savings contract and earn interest. The mechanics are beyond the scope of this article and you can find a full technical dive here but the basic idea is that some of the interest paid on Dai which is borrowed into existence is given to savers in the form of the DSR. This DSR will be dynamically set by MakerDAO as a monetary policy instrument necessary to keep the price of Dai stable.

Burning + DSR = Maximum Thrift

Since the DSR is at the core of the stability of Dai, taking advantage of it in WeiDai wouldn’t increase the systemic risk of holding WeiDai. For this reason, the DSR has been selected as a risk free addition to WeiDai. Going forward, Dai placed in the Reserve will immediately be deposited into the Savings contract, meaning that if absolutely no burning happens on WeiDai, the redeem rate will grow at the DSR!

This also means that instead of leaving your Dai locked where you can’t use it, WeiDai will wrap this mechanism into a token you can send and receive like any ERC20 token. Dai holders won’t have to choose between the DSR and WeiDai.

Incubation adjustment will be (far) less aggressive

Time is at the heart of thriftiness and as such, WeiDai explicitly mines patience to convert Dai into WeiDai by making creators endure an incubation period. The Patience Regulation Engine dynamically adjusts the duration of incubation in response to how patient users are. In other words, if most people can hold out the full duration before claiming, the incubation duration is increased but if people claim early (suffering an early claim penalty), the duration is decreased. This is to simulate the dynamic difficulty adjustments of proof of work cryptocurrencies such as Bitcoin.

As the duration grows, secondary WeiDai markets will pop up for those who wish to buy it immediately without waiting. Patient creators (and time travellers) stand to make time arbitrage profits from these markets.

In WeiSai the duration is doubled or halved, starting at a minimum of 20 blocks. Bitcoin also adjusts the difficulty number by orders of magnitude. After some reflection and some real world testing, it became clear that there’s a massive distinguishing factor between time and electricity: supply response. Time is dealt out in fixed small proportions that cannot respond to changes in demand. Electricity can be dynamically increased to match demand through increased production. When the demand for a commodity in fixed supply rises, the price rises at the same rate. Since patience is the cost premium users pay for WeiDai, exponentially doubling the incubation duration doubles the cost with no matching “supply response” from time. For this reason, the WeiDai duration will now change linearly in batches of 20 blocks.

To see the difference, suppose the incubation duration increases 10 times. Under WeiDai, the duration would increase by (20x10=) 200 blocks. Under WeiSai, the duration would increase to (20x2¹⁰=) 20480 blocks. If each Ethereum block is roughly 20 seconds in duration this means WeiSai would take 4.7 days to incubate in this example! Meanwhile WeiDai will only take just over an hour.

New Logo

Dai is launching with a new Dai logo. WeiDai’s logo has always been a shield with the Dai logo at the centre, indicating that WeiDai is the protection for Dai from inflation (Wei is Chinese for guard). To indicate the continuity of the core WeiDai mission while also conveying that we mean Dai and not Sai, the logo will retain its original shield while getting the new Dai logo as its central adornment. Once the edge location for the CDN refreshes in your location, you’ll see the site decorated with the new logo.

Upgrade Path for WeiSai holders: Order 66

If you’re eager to get into WeiDai, please make sure the new version is live. It would be unfortunate if you purchase WeiSai just before the switch over and then have to go through the upgrade hoop. At the time of writing, we’re still in WeiSai. If you want to keep informed when this happens, you can either subscribe to this publication to receive an email, join the discord channel or follow my personal twitter account. Don’t worry, there will be no spamming from any of those platforms.

Finally, the part all the early adopters have been waiting for, upgrade. Initially, I played with the idea of having a single click action that would redeem your existing WeiSai for Sai, use Maker’s contracts to convert it into Dai and then shortcut past the Patience Regulation Engine to instantly create new WeiDai. This whole process would be a user experience dream come true but it comes with many downsides, unfortunately. The first is that going through all those smart contracts is very gassy and it’s likely your transaction would be rejected numerous times or take very long to complete. The next is that bit about circumventing the Patience Regulation Engine. It would seem to require me to insert a loophole into the WeiDai system, just for this one time event. In smart contract design every loophole added introduces new governance and attack risks.

Instead, I decided to make the website handle most of the schlep without compromising the coherency of the smart contracts. When you as a WeiSai holder visit the site after the new WeiDai is launched, a modal popup will inform you that you have old WeiDai that needs to be upgraded. There’ll be a button linked to smart contract script on the Version Controller which in one transaction will claim any incubating WeiSai and then redeem your entire holdings for Sai. You won’t be able to circumvent this modal popup and indeed if you are an Ethereum command line pro, you will find that WeiSai creation has been disabled at the smart contract level.

Example of Modal Popup requesting you to claim any incubating WeiSai and then redeem in one transaction.

Once the claimAndRedeem transaction has been mined, the site will return the original site you remember (you may need to refresh your browser). The Dai balance on the right now refers to MCD, not Sai. If something goes wrong or is unclear, please let me know at this discord channel.



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Justin Goro

Justin Goro

Creator of WeiDai and 92 times emperor of Tsuranuanni