Upgrade to Pro — share decks privately, control downloads, hide ads and more …

bancor-token-economy-made-with-ruby

 bancor-token-economy-made-with-ruby

bancor: Token economy made with Ruby

2018.05.31 RubyKaigi 2018
http://rubykaigi.org/2018/

Yuta Kurotaki

May 31, 2018
Tweet

More Decks by Yuta Kurotaki

Other Decks in Programming

Transcript

  1. Crypto currency “SUKISUKI” corps • Introduced OKIMOCHI to Pepabo’s Slack

    • OKIMOCHI: Send bit coins with reaction on Slack • Research and development of Kaleidscope • KVS on IPFS • Web service development using Bancor Protocol • and More ! https://speakerdeck.com/kentaro/wips-for-cryptocurrency-at-pepabo
  2. Outline • Blockchain • Smart Contract • Token Economy •

    Bancor Protocol & Ruby • Conclusion & Future plans
  3. What is Smart Contracts? •A smart contract is the simplest

    form of decentralized automation, and is most easily and accurately defined as follows: a smart contract is a mechanism involving digital assets and two or more parties, where some or all of the parties put assets in and assets are automatically redistributed among those parties according to a formula based on certain data that is not known at the time the contract is initiated. https://blog.ethereum.org/2014/05/06/daos-dacs-das-and-more-an-incomplete-terminology-guide/
  4. Example •A wants to pay $500 to B to build

    a website. The contract would work as follows: A puts $500 into the contract, and the funds are locked up. •When B finishes the website, B can send a message to the contract asking to unlock the funds. If A agrees, the funds are released. •If B decides not to finish the website, B can quit by sending a message to relinquish the funds. •If B claims that he finished the website, but A does not agree, then after a 7-day waiting period it’s up to judge J to provide a verdict in A or B’s favor. https://blog.ethereum.org/2014/05/06/daos-dacs-das-and-more-an-incomplete-terminology-guide/
  5. ICO(Initial Coin Offering) • ALIS ICO Results • 430 million

    yen ! • Openness https://alisproject.github.io/whitepaper/whitepaper_v1.01.pdf
  6. Token Economy • Token economy means economy by token (electronic

    vouchers / substitute money) • Make something of value realized by tokenizing and make it possible to trade
  7. Problems in Minor Token Economy • Coincidence of Wants Problem

    • Agreement on price is required between selling side and buying side • Minor currencies are hard to distribute. I can not sell(buy) it when I want to sell(buy) it ❌ *XBOUUPTFMM GPS *XBOUUPCVZJU GPS Coincidence of Wants Problem
  8. A New Method for Price Discovery • Balance: Reserve Token

    Balance • Supply: Smart Token Supply • CRR: Constant Reserve Ratio https://bravenewcoin.com/assets/Whitepapers/Bancor-Protocol-Whitepaper-en.pdf
  9. Price Calculation Per Transaction • T = Smart tokens received

    in exchange for E (reserve tokens), given R, S and F • E = Reserve tokens received in exchange for T (smart tokens), given R, S and F R - Reserve Token Balance S - Smart Token Supply F - Constant Reserve Ratio (CRR)
  10. Motivation • It takes money (Gas) to do with a

    block chain • It takes time for transactions • It takes cost to understand the structure and language of the block chain
  11. Conclusion • Implementing the Bancor protocol in Ruby makes it

    easy to simulate web applications built with Rails without using smart contracts
  12. Future plans • Decimal point operation • Ethereum World Idea

    implements in Ruby World • Ruby World Ideas implements in Ethereum World • Ruby Ethereum