跳到正文
EasyXiv 检索
投稿 关于 登录

按回车检索 · 直接输入编号(如 1706.03762)可跳转到论文

计算机科学 > 软件工程

arXiv:1809.07945 (cs)
[提交于 2018年9月21日]

标题:SCC: Automatic Classification of Code Snippets

作者:Kamel Alreshedy, Dhanush Dharmaretnam, Daniel M. German, Venkatesh Srinivasan, T. Aaron Gulliver
查看论文《SCC: Automatic Classification of Code Snippets》的 PDF
查看原文 PDF 中文 PDF (下批处理) EasyResearch 阅读
摘要:Determining the programming language of a source code file has been considered in the research community; it has been shown that Machine Learning (ML) and Natural Language Processing (NLP) algorithms can be effective in identifying the programming language of source code files. However, determining the programming language of a code snippet or a few lines of source code is still a challenging task. Online forums such as Stack Overflow and code repositories such as GitHub contain a large number of code snippets. In this paper, we describe Source Code Classification (SCC), a classifier that can identify the programming language of code snippets written in 21 different programming languages. A Multinomial Naive Bayes (MNB) classifier is employed which is trained using Stack Overflow posts. It is shown to achieve an accuracy of 75% which is higher than that with Programming Languages Identification (PLI a proprietary online classifier of snippets) whose accuracy is only 55.5%. The average score for precision, recall and the F1 score with the proposed tool are 0.76, 0.75 and 0.75, respectively. In addition, it can distinguish between code snippets from a family of programming languages such as C, C++ and C#, and can also identify the programming language version such as C# 3.0, C# 4.0 and C# 5.0.
主题: 软件工程 (cs.SE); 机器学习 (cs.LG); 机器学习 (stat.ML)
引用方式: arXiv:1809.07945 [cs.SE]
  (或者 arXiv:1809.07945v1 [cs.SE] 对于此版本)
  https://doi.org/10.48550/arXiv.1809.07945
期刊参考: Working Conference on Source Code Analysis & Manipulation 2018

提交历史

来自:Kamel Alrashedy
[v1] 2018年9月21日 星期五 04:50:40 UTC
全文链接:

访问论文:

  • 查看原文 PDF
  • 中文 PDF (下批处理)
  • EasyResearch 阅读
  • TeX 源文件
  • arXiv 原文页面
查看许可

当前浏览上下文:

cs.SE
< 上一篇   |   下一篇 >
最新 | 近期 | 2018-09
切换浏览方式为:
cs
cs.LG
stat.ML

参考文献与引用

  • Google Scholar
  • Semantic Scholar

BibTeX 格式的引用

EasyXiv 是独立运营的中文预印本站点,与 arXiv 及康奈尔大学无隶属关系。 论文元数据与原文来自 arXiv.org,感谢 arXiv 提供开放获取服务。
关于 · 帮助 · 投稿指南 · 版权 · arXiv 原站