Abstract:
Blockchain technology has transformed modern digital ecosystems by enabling secure, transparent, and automated transactions through smart contracts. However, the increasing complexity of these contracts introduces significant challenges, including high computational costs, scalability limitations, and difficulties in detecting anomalous behavior. In this study, we propose an AI-based optimization framework that enhances the efficiency and security of blockchain smart contracts. The framework integrates Neural Architecture Search (NAS) to automatically design optimal Convolutional Neural Network (CNN) architectures tailored to blockchain data, enabling effective anomaly detection. To address the challenge of limited labeled data, transfer learning is employed to adapt pre-trained CNN models to smart contract patterns, improving model generalization and reducing training time. Furthermore, Model Compression techniques, including filter pruning and quantization, are applied to minimize the computational load, making the framework suitable for deployment in resource-constrained blockchain environments. Experimental results on Ethereum transaction datasets demonstrate that the proposed method achieves significant improvements in anomaly detection accuracy and computational efficiency compared to conventional approaches, offering a practical and scalable solution for smart contract monitoring and optimization.