用SVM+滑窗投票法精准定位代码中的语言特性,提升开发与教学效率。
Design, Implementation and Evaluation of a Novel Programming Language Topic Classification Workflow
- 结合滑窗与投票策略的多标签SVM方法
- 平均F1达0.90,代码片段定位准确率0.75
- 适合代码分析、教育工具开发人员使用
随着软件系统规模和复杂性增加,理解源码中编程语言主题的分布对技术决策、新人入职引导及工具与教育设计至关重要。本文提出并评估了一种新型编程语言主题分类工作流。该方法结合多标签支持向量机(SVM)与滑动窗口及投票策略,实现对运算符重载、虚函数、继承、模板等核心语言概念的细粒度定位。模型在IBM Project CodeNet数据集上训练,平均F1得分为0.90,代码-主题高亮准确率为0.75。研究结果为代码分析与数据驱动的软件工程提供了实证依据和可复用的流水线。
原文摘要 · Abstract (English)
As software systems grow in scale and complexity, understanding the distribution of programming language topics within source code becomes increasingly important for guiding technical decisions, improving onboarding, and informing tooling and education. This paper presents the design, implementation, and evaluation of a novel programming language topic classification workflow. Our approach combines a multi-label Support Vector Machine (SVM) with a sliding window and voting strategy to enable fine-grained localization of core language concepts such as operator overloading, virtual functions, inheritance, and templates. Trained on the IBM Project CodeNet dataset, our model achieves an average F1 score of 0.90 across topics and 0.75 in code-topic highlight. Our findings contribute empirical insights and a reusable pipeline for researchers and practitioners interested in code analysis and data-driven software engineering.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。