34 research outputs found
Code2Que: A Tool for Improving Question Titles from Mined Code Snippets in Stack Overflow
Stack Overflow is one of the most popular technical Q&A sites used by
software developers. Seeking help from Stack Overflow has become an essential
part of software developers' daily work for solving programming-related
questions. Although the Stack Overflow community has provided quality assurance
guidelines to help users write better questions, we observed that a significant
number of questions submitted to Stack Overflow are of low quality. In this
paper, we introduce a new web-based tool, Code2Que, which can help developers
in writing higher quality questions for a given code snippet. Code2Que consists
of two main stages: offline learning and online recommendation. In the offline
learning phase, we first collect a set of good quality
pairs as training samples. We then train our model on these training samples
via a deep sequence-to-sequence approach, enhanced with an attention mechanism,
a copy mechanism and a coverage mechanism. In the online recommendation phase,
for a given code snippet, we use the offline trained model to generate question
titles to assist less experienced developers in writing questions more
effectively. At the same time, we embed the given code snippet into a vector
and retrieve the related questions with similar problematic code snippets.Comment: arXiv admin note: text overlap with arXiv:2005.1015
Assisted Specification of Code Using Search
We describe an intelligent assistant based on mining existing software
repositories to help the developer interactively create checkable
specifications of code. To be most useful we apply this at the subsystem level,
that is chunks of code of 1000-10000 lines that can be standalone or integrated
into an existing application to provide additional functionality or
capabilities. The resultant specifications include both a syntactic description
of what should be written and a semantic specification of what it should do,
initially in the form of test cases. The generated specification is designed to
be used for automatic code generation using various technologies that have been
proposed including machine learning, code search, and program synthesis. Our
research goal is to enable these technologies to be used effectively for
creating subsystems without requiring the developer to write detailed
specifications from scratch
CoNCRA: A Convolutional Neural Network Code Retrieval Approach
Software developers routinely search for code using general-purpose search
engines. However, these search engines cannot find code semantically unless it
has an accompanying description. We propose a technique for semantic code
search: A Convolutional Neural Network approach to code retrieval (CoNCRA). Our
technique aims to find the code snippet that most closely matches the
developer's intent, expressed in natural language. We evaluated our approach's
efficacy on a dataset composed of questions and code snippets collected from
Stack Overflow. Our preliminary results showed that our technique, which
prioritizes local interactions (words nearby), improved the state-of-the-art
(SOTA) by 5% on average, retrieving the most relevant code snippets in the top
3 (three) positions by almost 80% of the time. Therefore, our technique is
promising and can improve the efficacy of semantic code retrieval