🤖 AI Summary
To address the challenge of identifying developers’ intent in smart contracts—which hinders security assessment and malicious behavior detection—this paper formally introduces the task of developer intent recognition for the first time. We propose SmartIntentNN, an end-to-end deep learning framework that integrates Sentence-BERT for pretrained semantic encoding, a K-means–driven intent feature enhancement mechanism, and a BiLSTM-based multi-label classifier to achieve fine-grained, interpretable intent understanding. Evaluated on a real-world dataset of 42,000 Ethereum smart contracts, SmartIntentNN achieves a macro-F1 score of 0.8633 across ten intent classes, significantly outperforming existing baselines. This work establishes a novel paradigm for smart contract security auditing and enables proactive risk预警—providing both theoretical advancement and practical tooling for intent-aware vulnerability detection.
📝 Abstract
In recent years, research in software security has concentrated on identifying vulnerabilities in smart contracts to prevent significant losses of crypto assets on blockchains. Despite early successes in this area, detecting developers' intents in smart contracts has become a more pressing issue, as malicious intents have caused substantial financial losses. Unfortunately, existing research lacks effective methods for detecting development intents in smart contracts. To address this gap, we propose extsc{SmartIntentNN} (Smart Contract Intent Neural Network), a deep learning model designed to automatically detect development intents in smart contracts. extsc{SmartIntentNN} leverages a pre-trained sentence encoder to generate contextual representations of smart contracts, employs a K-means clustering model to identify and highlight prominent intent features, and utilizes a bidirectional LSTM-based deep neural network for multi-label classification. We trained and evaluated extsc{SmartIntentNN} on a dataset containing over 40,000 real-world smart contracts, employing self-comparison baselines in our experimental setup. The results show that extsc{SmartIntentNN} achieves an F1-score of 0.8633 in identifying intents across 10 distinct categories, outperforming all baselines and addressing the gap in smart contract detection by incorporating intent analysis.