Model Training Part for Solidity vulnerability Detection based on GPT (torch backen)
Paper "SolGPT: a GPT-Based Static Vulnerability Detection Model for Enhancing Smart Contract Security" has published in ICA3PP 2023.
Author: Shengqiang Zeng, Hongwei Zhang, Jinsong Wang, and Kai Shi.
Online Link SolGPT: a GPT-Based Static Vulnerability Detection Model for Enhancing Smart Contract Security.
Paper Manuscript already upload as "SolGPT.9.17.2023".
- python3
- torch1(https://pytorch.org/get-started/locally/)
- transformers
This repository contains the smart contract dataset of source code and processed code fragment. As to the source code, we crawled the source code of the smart contract from the Ethereum by using the crawler tool. Besides, we have collected some data from some other websites. At the same time, we also designed and wrote some smart contract codes with reentrancy vulnerabilities.
Note: crawler tool is available here.
Original Ethereum smart contracts: Etherscan_contract
The train data after normalization in dataset
.
Training contain two part
- TAPT training
- finetunnng
You can see the instruction in train_tapt.sh and train_finetune.sh to learn how to train this model
- Rechecker for Normalized dataset: https://github.com/Messi-Q/ReChecker
- This Project already stops maintained, this is a branch that I keep maintaining.
- https://github.com/PoilZero/ReChecker