Under the folder, transactions are already categorised into the corresponding tables based on their call functions.įor our example, we will be utilising 3 tables: UniswapV2Pair_event_Swap, UniswapV2Pair_event_Burn (removing liquidity) & UniswapV2Pair_event_Mint (supplying liquidity). Bigquery Ethereum ETL offers a convenient entrypoint for us to analyze historical blockchain activities.įrom Bigquery, Uniswap transactions can be retrieved from the blockchain-etl.ethereum_uniswap directory. Uniswap data can be retrieved by directly syncing an Ethereum node and filtering on the address of interest or by querying from Bigquery. We also leverage Motif, our open-source graph exploration tool to interactively explore the patterns and behaviours. We use Neo4j as its property graph model allows us to model the rich relationships present in Uniswap data. In order to get a sense of the usual patterns or activities that take place on the graph, we need tools to help us easily query and visualize such rich graph structures. This gives a rich multi-edge graph with multiple node and edge properties. Each of these actions also contain additional information such as the number of tokens received or transferred. The bulk of Uniswap transactions is made up of these 3 call functions: Supply Liquidity, Remove Liquidity and Swap. We model wallets or smart contract addresses as nodes and contract calls as edges. For smart contract analysis, we take a similar approach to understand activities through a semantic graph structure. In a previous post, we showed how graph analysis can be used to understand the structure of exchanges on the Ethereum chain. Traders also pay trading fees which goes to the platform and the liquidity providers. On the other side, traders swap tokens, based on prices mathematically determined by the liquidity pool. They are also able to withdraw their liquidity at any given time. Liquidity providers loan their crypto to the liquidity pool in return for attractive yield. To keep the trading system liquid at all times, Uniswap relies on 2 groups of users. Unlike CEX, users are in custody of their own funds and digital assets can be traded in a permissionless and automatic way without any Know Your Customer (KYC). Like centralised exchange (CEX) counterparts like Binance or Robinhood, it provides crypto trading services to users. As of June 2021, it claims to have facilitated 54 million trades with an all time volume of $290 billion. Uniswap is a collection of smart contract programs that functions as a decentralized exchange (DEX) on the Ethereum chain. In this article, we will be analysing Uniswap in greater detail. This has brought on many real-world applications, highlighted in the quote above, to the Ethereum network, due to the cost efficiency and simplicity for businesses. In short, smart contracts allow for self-execution of tasks based on the rules/codes defined, removing the need for a middleman. While Bitcoin first introduced the idea of blockchain to the masses, Ethereum aims to revolutionize the world by bringing in smart contracts. The possibilities are really only limited to the bounds of human ingenuity.” “However, not only does the blockchain act as a public ledger for every financial transaction on the bitcoin network, it can also be adapted to suit other needs such as file storage, property ownership, trading of assets, or even verifying the manufacturing process of medicine. In this article, we expound on some of the exploratory techniques used in blockchain forensics and how we can analyse decentralized finance activities with Neo4j and Motif. Our previous articles showcase some of the risks involved with some protocols. These include the likes of Uniswap, a decentralized exchange or Aave, a decentralized lending platform. These twin properties of trusted execution without a centralized authority has attracted the growth of decentralized finance activities. This means that the entire historical data and activities on the blockchain are readily available and cannot be manipulated mathematically. Transactions are recorded in a distributed ledger (aka blockchain) and are immutable. Blockchain technology like Bitcoin and Ethereum provides a decentralized environment for financial transactions.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |