10.9GTMay 4
A Unified Framework and Comparative Study of Decentralized Finance Derivatives ProtocolsLuca Pennella, Pietro Saggese, Fabio Pinelli et al.
Decentralized Finance (DeFi) applications introduce novel financial instruments replicating and extending traditional ones through blockchain-based smart contracts. Among these applications, DeFi derivatives protocols enable the creation and trading of decentralized derivative instruments whose value depends on underlying cryptoassets, indices, or other reference variables. Despite their growing significance, however, they remain relatively understudied compared to other DeFi protocols, such as lending protocols and decentralized exchanges. This paper systematically analyzes DeFi derivatives protocols, categorized into perpetuals, options, and synthetics, with the aim of comparing their instrument structures, protocol mechanisms, operational dynamics, and economic agents. We provide a formal characterization of the main classes of decentralized derivative instruments and develop a protocol-agnostic framework that connects instrument-level specifications, market-state variables, and protocol-level mechanisms. We complement the analytical framework with numerical simulations that evaluate how derivative positions evolve under varying economic conditions, including changes in underlying asset prices, volatility, protocol-specific fees, and leverage. Overall, this study provides a structured analytical framework for understanding and comparing the design and functioning of decentralized finance derivatives protocols.
CRMar 28, 2024
Detecting Financial Bots on the Ethereum BlockchainThomas Niedermayer, Pietro Saggese, Bernhard Haslhofer
The integration of bots in Distributed Ledger Technologies (DLTs) fosters efficiency and automation. However, their use is also associated with predatory trading and market manipulation, and can pose threats to system integrity. It is therefore essential to understand the extent of bot deployment in DLTs; despite this, current detection systems are predominantly rule-based and lack flexibility. In this study, we present a novel approach that utilizes machine learning for the detection of financial bots on the Ethereum platform. First, we systematize existing scientific literature and collect anecdotal evidence to establish a taxonomy for financial bots, comprising 7 categories and 24 subcategories. Next, we create a ground-truth dataset consisting of 133 human and 137 bot addresses. Third, we employ both unsupervised and supervised machine learning algorithms to detect bots deployed on Ethereum. The highest-performing clustering algorithm is a Gaussian Mixture Model with an average cluster purity of 82.6%, while the highest-performing model for binary classification is a Random Forest with an accuracy of 83%. Our machine learning-based detection mechanism contributes to understanding the Ethereum ecosystem dynamics by providing additional insights into the current bot landscape.
STMar 23, 2024
Investigating Similarities Across Decentralized Financial (DeFi) ServicesJunliang Luo, Stefan Kitzler, Pietro Saggese
We explore the adoption of graph representation learning (GRL) algorithms to investigate similarities across services offered by Decentralized Finance (DeFi) protocols. Following existing literature, we use Ethereum transaction data to identify the DeFi building blocks. These are sets of protocol-specific smart contracts that are utilized in combination within single transactions and encapsulate the logic to conduct specific financial services such as swapping or lending cryptoassets. We propose a method to categorize these blocks into clusters based on their smart contract attributes and the graph structure of their smart contract calls. We employ GRL to create embedding vectors from building blocks and agglomerative models for clustering them. To evaluate whether they are effectively grouped in clusters of similar functionalities, we associate them with eight financial functionality categories and use this information as the target label. We find that in the best-case scenario purity reaches .888. We use additional information to associate the building blocks with protocol-specific target labels, obtaining comparable purity (.864) but higher V-Measure (.571); we discuss plausible explanations for this difference. In summary, this method helps categorize existing financial products offered by DeFi protocols, and can effectively automatize the detection of similar DeFi services, especially within protocols.
CRNov 5, 2021
Disentangling Decentralized Finance (DeFi) CompositionsStefan Kitzler, Friedhelm Victor, Pietro Saggese et al.
We present a measurement study on compositions of Decentralized Finance protocols, which aim to disrupt traditional finance and offer services on top of distributed ledgers, such as Ethereum. DeFi compositions may impact the development of ecosystem interoperability, are increasingly integrated with web technologies, and may introduce risks through complexity. Starting from a dataset of 23 labeled DeFi protocols and 10,663,881 associated Ethereum accounts, we study the interactions of protocols and associated smart contracts. From a network perspective, we find that decentralized exchanges and lending protocols have high degree and centrality values, that interactions among protocol nodes primarily occur in a strongly connected component, and that known community detection methods cannot disentangle DeFi protocols. Therefore, we propose an algorithm to decompose a protocol call into a nested set of building blocks that may be part of other DeFi protocols. With a ground truth dataset we have collected, we can demonstrate the algorithm's capability by finding that swaps are the most frequently used building blocks. As building blocks can be nested, i.e., contained in each other, we provide visualizations of composition trees for deeper inspections. We also present a broad picture of DeFi compositions by extracting and flattening the entire nested building block structure across multiple DeFi protocols. Finally, to demonstrate the practicality of our approach, we present a case study that is inspired by the recent collapse of the UST stablecoin in the Terra ecosystem. Under the hypothetical assumption that the stablecoin USD Tether would experience a similar fate, we study which building blocks and, thereby, DeFi protocols would be affected. Overall, our results and methods contribute to a better understanding of a new family of financial products.
GNSep 22, 2021
Who are the arbitrageurs? Empirical evidence from Bitcoin traders in the Mt. Gox exchange platformPietro Saggese, Alessandro Belmonte, Nicola Dimitri et al.
We mine the leaked history of trades on Mt. Gox, the dominant Bitcoin exchange from 2011 to early 2014, to detect the triangular arbitrage activity conducted within the platform. The availability of user identifiers per trade allows us to focus on the historical record of 440 investors, detected as arbitrageurs, and consequently to describe their trading behavior. We begin by showing that a considerable difference appears between arbitrageurs when indicators of their expertise are taken into account. In particular, we distinguish between those who conducted arbitrage in a single or in multiple markets: using this element as a proxy for trade ability, we find that arbitrage actions performed by expert users are on average non-profitable when transaction costs are accounted for, while skilled investors conduct arbitrage at a positive and statistically significant premium. Next, we show that specific trading strategies, such as splitting orders or conducting arbitrage non aggressively, are further indicators of expertise that increase the profitability of arbitrage. Most importantly, we exploit within-user (across hours and markets) variation and document that expert users make profits on arbitrage by reacting quickly to plausible exogenous variations on the official exchange rates. We present further evidence that such differences are chiefly due to a better ability of the latter in incorporating information, both on the transactions costs and on the exchange rates volatility, eventually resulting in a better timing choice at small time scale intervals. Our results support the hypothesis that arbitrageurs are few and sophisticated users.