Text Classification
Transformers
PyTorch
English
code
code-classification
graphcodebert
ai-generated-content-detection
Instructions to use FFFFAHHH/NPC_model with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use FFFFAHHH/NPC_model with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="FFFFAHHH/NPC_model")# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("FFFFAHHH/NPC_model", dtype="auto") - Notebooks
- Google Colab
- Kaggle
Update README.md
Browse files
README.md
CHANGED
|
@@ -80,4 +80,23 @@ tokenizer = AutoTokenizer.from_pretrained("microsoft/graphcodebert-base")
|
|
| 80 |
# 3. Initialize the classification model and load weights
|
| 81 |
model = GraphCodeBERTForClassification(base_model)
|
| 82 |
model.load_state_dict(torch.load("Detect_AI.pth", map_location=torch.device('cpu')))
|
| 83 |
-
model.eval()kenizer = AutoTokenizer.from_pretrained("microsoft/graphcodebert-base"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 80 |
# 3. Initialize the classification model and load weights
|
| 81 |
model = GraphCodeBERTForClassification(base_model)
|
| 82 |
model.load_state_dict(torch.load("Detect_AI.pth", map_location=torch.device('cpu')))
|
| 83 |
+
model.eval()kenizer = AutoTokenizer.from_pretrained("microsoft/graphcodebert-base"
|
| 84 |
+
```
|
| 85 |
+
|
| 86 |
+
## 📚 Citation
|
| 87 |
+
|
| 88 |
+
If you use this code or system in your research, please cite our paper:
|
| 89 |
+
|
| 90 |
+
```bibtex
|
| 91 |
+
@conference{icaart26,
|
| 92 |
+
author={Pachanitha Saeheng and Napat Boongaree and Chutweeraya Sriwilailak and Chaiyong Ragkhitwetsagul and Teeradaj Racharak and Ekapol Chuangsuwanich},
|
| 93 |
+
title={NPC: Automated Tool for Detecting and Explaining ChatGPT-Generated Programs},
|
| 94 |
+
booktitle={Proceedings of the 18th International Conference on Agents and Artificial Intelligence - Volume 5: ICAART},
|
| 95 |
+
year={2026},
|
| 96 |
+
pages={4714-4719},
|
| 97 |
+
publisher={SciTePress},
|
| 98 |
+
organization={INSTICC},
|
| 99 |
+
doi={10.5220/0014485500004052},
|
| 100 |
+
isbn={978-989-758-796-2},
|
| 101 |
+
issn={2184-433X},
|
| 102 |
+
}
|