paper-with-me

Papers

Automatic Detection of LLM-generated Code: A Case Study of Claude 3 Haiku

2024-09-02 · Musfiqur Rahman, SayedHassan Khatoonabadi, Ahmad Abdellatif, Emad Shihab

Using Large Language Models (LLMs) has gained popularity among software developers for generating source code. However, the use of LLM-generated code can introduce risks of adding suboptimal, defective, and vulnerable code. This makes it necessary to devise methods for the accurate detection of LLM-generated code. Toward this goal, we perform a case study of Claude 3 Haiku (or Claude 3 for brevity) on CodeSearchNet dataset. We divide our analyses into two parts: function-level and class-level. We extract 22 software metric features, such as Code Lines and Cyclomatic Complexity, for each level of granularity. We then analyze code snippets generated by Claude 3 and their human-authored counterparts using the extracted features to understand how unique the code generated by Claude 3 is. In the following step, we use the unique characteristics of Claude 3-generated code to build Machine Learning (ML) models and identify which features of the code snippets make them more detectable by ML models. Our results indicate that Claude 3 tends to generate longer functions, but shorter classes than humans, and this characteristic can be used to detect Claude 3-generated code with ML models with 82% and 66% accuracies for function-level and class-level snippets, respectively.

📄 PDF Abstract BibTeX arXiv:2409.01382

Code (0)

등록된 구현이 없습니다.

Similar Papers 제목 키워드 기반

Mossad: Defeating Software Plagiarism Detection

2020-10-04 · Breanna Devore-McDonald, Emery D. Berger

Automatic software plagiarism detection tools are widely used in educational settings to ensure that submitted work was not copied. These tools have grown in use together with the rise in enrollments in computer science …

Code Reuse Detection

Automatic Layout Generation with Applications in Machine Learning Engine Evaluation

2019-12-12 · Haoyu Yang, Wen Chen, Piyush Pathak, Frank Gennari 외

Machine learning-based lithography hotspot detection has been deeply studied recently, from varies feature extraction techniques to efficient learning models. It has been observed that such machine learning-based framewo…

BIG-bench Machine LearningLayout Generation

CLIP-VAD: Exploiting Vision-Language Models for Voice Activity Detection

2024-10-18 · Andrea Appiani, Cigdem Beyan

Voice Activity Detection (VAD) is the process of automatically determining whether a person is speaking and identifying the timing of their speech in an audiovisual data. Traditionally, this task has been tackled by proc…

Action DetectionActivity DetectionPrompt Engineering

Towards resilient machine learning for ransomware detection

2018-12-21 · Li Chen, Chih-Yuan Yang, Anindya Paul, Ravi Sahita

There has been a surge of interest in using machine learning (ML) to automatically detect malware through their dynamic behaviors. These approaches have achieved significant improvement in detection rates and lower false…

BIG-bench Machine LearningGenerative Adversarial NetworkMalware Analysis

Automatic Labelling for Low-Light Pedestrian Detection

2025-07-03 · Dimitrios Bouzoulas, Eerik Alamikkotervo, Risto Ojala arxiv

Pedestrian detection in RGB images is a key task in pedestrian safety, as the most common sensor in autonomous vehicles and advanced driver assistance systems is the RGB camera. Low-light pedestrian detection lacks large…

Pedestrian DetectionAutonomous VehiclesObject Detection