# A Bytecode-based Approach for Smart Contract Classification

arXiv: https://arxiv.org/abs/2106.15497 · HTML: https://mlsanity.com/paper/2106.15497/

## Key facts

- No citing papers in the map yet (data through 14 Oct 2026).
- Builds on 6 of its 40 references that are in the map.
- First posted on arXiv 31 May 2021.

## Builds on (most cited first, 6 of 6)

- [XGBoost: A Scalable Tree Boosting System](https://mlsanity.com/paper/1603.02754/) (2016)
- [Effective LSTMs for Target-Dependent Sentiment Classification](https://mlsanity.com/paper/1512.01100/) (2015)
- [Hyperledger Fabric: A Distributed Operating System for Permissioned Blockchains](https://mlsanity.com/paper/1801.10228/) (2018)
- [Relief-Based Feature Selection: Introduction and Review](https://mlsanity.com/paper/1711.08421/) (2017)
- [Data mining for detecting Bitcoin Ponzi schemes](https://mlsanity.com/paper/1803.00646/) (2018)
- [Anomaly Detection in Bitcoin Network Using Unsupervised Learning Methods](https://mlsanity.com/paper/1611.03941/) (2016)

## Abstract (arXiv)

With the development of blockchain technologies, the number of smart contracts deployed on blockchain platforms is growing exponentially, which makes it difficult for users to find desired services by manual screening. The automatic classification of smart contracts can provide blockchain users with keyword-based contract searching and helps to manage smart contracts effectively. Current research on smart contract classification focuses on Natural Language Processing (NLP) solutions which are based on contract source code. However, more than 94% of smart contracts are not open-source, so the application scenarios of NLP methods are very limited. Meanwhile, NLP models are vulnerable to adversarial attacks. This paper proposes a classification model based on features from contract bytecode instead of source code to solve these problems. We also use feature selection and ensemble learning to optimize the model. Our experimental studies on over 3,300 real-world Ethereum smart contracts show that our model can classify smart contracts without source code and has better performance than baseline models. Our model also has good resistance to adversarial attacks compared with NLP-based models. In addition, our analysis reveals that account features used in many smart contract classification models have little effect on classification and can be excluded.
