Exploring the Neighborhood with Dora to Expedite Software Maintenance Emily Hill, Lori Pollock, K. Vijay-Shanker University of Delaware.

Slides:



Advertisements
Similar presentations
Chapter 5: Introduction to Information Retrieval
Advertisements

Introduction to Information Retrieval
INSTRUCTOR: DR.NICK EVANGELOPOULOS PRESENTED BY: QIUXIA WU CHAPTER 2 Information retrieval DSCI 5240.
WWW 2014 Seoul, April 8 th SNOW 2014 Data Challenge Two-level message clustering for topic detection in Twitter Georgios Petkos, Symeon Papadopoulos, Yiannis.
Data Mining Methodology 1. Why have a Methodology  Don’t want to learn things that aren’t true May not represent any underlying reality ○ Spurious correlation.
Developing and Evaluating a Query Recommendation Feature to Assist Users with Online Information Seeking & Retrieval With graduate students: Karl Gyllstrom,
CONQUER: A Tool for NL-based Query Refinement & Contextualizing Code Search Results Manuel Roldan-Vega, Greg Mallet, Emily Hill, Jerry Alan Fails.
CMU SCS : Multimedia Databases and Data Mining Lecture #16: Text - part III: Vector space model and clustering C. Faloutsos.
Ranking models in IR Key idea: We wish to return in order the documents most likely to be useful to the searcher To do this, we want to know which documents.
Introduction to Information Retrieval (Manning, Raghavan, Schutze) Chapter 6 Scoring term weighting and the vector space model.
Information Retrieval Ling573 NLP Systems and Applications April 26, 2011.
Query Operations: Automatic Local Analysis. Introduction Difficulty of formulating user queries –Insufficient knowledge of the collection –Insufficient.
Economic Perspectives in Test Automation: Balancing Automated and Manual Testing with Opportunity Cost Paper By – Rudolf Ramler and Klaus Wolfmaier Presented.
Using Natural Language Program Analysis to Locate and understand Action-Oriented Concerns David Shepherd, Zachary P. Fry, Emily Hill, Lori Pollock, and.
Carnegie Mellon 1 Maximum Likelihood Estimation for Information Thresholding Yi Zhang & Jamie Callan Carnegie Mellon University
Introducing Natural Language Program Analysis Lori Pollock, K. Vijay-Shanker, David Shepherd, Emily Hill, Zachary P. Fry, Kishen Maloor.
T.Sharon - A.Frank 1 Internet Resources Discovery (IRD) IR Queries.
Ch 4: Information Retrieval and Text Mining
Computer comunication B Information retrieval. Information retrieval: introduction 1 This topic addresses the question on how it is possible to find relevant.
1 CS 430 / INFO 430 Information Retrieval Lecture 3 Vector Methods 1.
Introduction to Language Models Evaluation in information retrieval Lecture 4.
Scalable Text Mining with Sparse Generative Models
Flash talk by: Aditi Garg, Xiaoran Wang Authors: Sarah Rastkar, Gail C. Murphy and Gabriel Murray.
Chapter 5: Information Retrieval and Web Search
Finding Advertising Keywords on Web Pages Scott Wen-tau YihJoshua Goodman Microsoft Research Vitor R. Carvalho Carnegie Mellon University.
Improving Automatic Abbreviation Expansion within Source Code to Aid in Program Search Tools Zak Fry.
Query session guided multi- document summarization THESIS PRESENTATION BY TAL BAUMEL ADVISOR: PROF. MICHAEL ELHADAD.
Developing Natural Language-based Software Analyses and Tools to Expedite Software Maintenance Lori Pollock Collaborators: K. Vijay-Shanker, Emily Hill,
272: Software Engineering Fall 2012 Instructor: Tevfik Bultan Lecture 17: Code Mining.
Challenges in Information Retrieval and Language Modeling Michael Shepherd Dalhousie University Halifax, NS Canada.
1 Announcements Research Paper due today Research Talks –Nov. 29 (Monday) Kayatana and Lance –Dec. 1 (Wednesday) Mark and Jeremy –Dec. 3 (Friday) Joe and.
Class Specification Implementation Graph By: Njume Njinimbam Chi-Chang Sun.
Classification Technology at LexisNexis SIGIR 2001 Workshop on Operational Text Classification Mark Wasson LexisNexis September.
1. Department of Arts and Sciences, Georgia State University 2. Department of Electrical and Computer Engineering, Texas Tech University 3. Department.
PAUL ALEXANDRU CHIRITA STEFANIA COSTACHE SIEGFRIED HANDSCHUH WOLFGANG NEJDL 1* L3S RESEARCH CENTER 2* NATIONAL UNIVERSITY OF IRELAND PROCEEDINGS OF THE.
Query Routing in Peer-to-Peer Web Search Engine Speaker: Pavel Serdyukov Supervisors: Gerhard Weikum Christian Zimmer Matthias Bender International Max.
A Probabilistic Graphical Model for Joint Answer Ranking in Question Answering Jeongwoo Ko, Luo Si, Eric Nyberg (SIGIR ’ 07) Speaker: Cho, Chin Wei Advisor:
Mining the Web to Create Minority Language Corpora Rayid Ghani Accenture Technology Labs - Research Rosie Jones Carnegie Mellon University Dunja Mladenic.
17/10/2015Dr Andy Brooks1 MSc Software Maintenance MS Viðhald hugbúnaðar Fyrirlestrar 37 og 38 Program Exploration with Dora.
Xiaoying Gao Computer Science Victoria University of Wellington Intelligent Agents COMP 423.
Chapter 6: Information Retrieval and Web Search
Debug Concern Navigator Masaru Shiozuka(Kyushu Institute of Technology, Japan) Naoyasu Ubayashi(Kyushu University, Japan) Yasutaka Kamei(Kyushu University,
Introduction to Digital Libraries hussein suleman uct cs honours 2003.
University of Malta CSA3080: Lecture 6 © Chris Staff 1 of 20 CSA3080: Adaptive Hypertext Systems I Dr. Christopher Staff Department.
LANGUAGE MODELS FOR RELEVANCE FEEDBACK Lee Won Hee.
Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University July 21, 2008WODA.
Retroactive Answering of Search Queries Beverly Yang Glen Jeh.
Vector Space Models.
Automatically detecting and describing high level actions within methods Presented by: Gayani Samaraweera.
Intelligent Database Systems Lab 國立雲林科技大學 National Yunlin University of Science and Technology 1 Improving the performance of personal name disambiguation.
Mining Dependency Relations for Query Expansion in Passage Retrieval Renxu Sun, Chai-Huat Ong, Tat-Seng Chua National University of Singapore SIGIR2006.
CIS 530 Lecture 2 From frequency to meaning: vector space models of semantics.
1 Adaptive Subjective Triggers for Opinionated Document Retrieval (WSDM 09’) Kazuhiro Seki, Kuniaki Uehara Date: 11/02/09 Speaker: Hsu, Yu-Wen Advisor:
Information Retrieval Techniques MS(CS) Lecture 7 AIR UNIVERSITY MULTAN CAMPUS Most of the slides adapted from IIR book.
Date: 2013/4/1 Author: Jaime I. Lopez-Veyna, Victor J. Sosa-Sosa, Ivan Lopez-Arevalo Source: KEYS’12 Advisor: Jia-ling Koh Speaker: Chen-Yu Huang KESOSD.
Term Weighting approaches in automatic text retrieval. Presented by Ehsan.
DISTRIBUTED INFORMATION RETRIEVAL Lee Won Hee.
Xiaoying Gao Computer Science Victoria University of Wellington COMP307 NLP 4 Information Retrieval.
Information Retrieval Lecture 3 Introduction to Information Retrieval (Manning et al. 2007) Chapter 8 For the MSc Computer Science Programme Dell Zhang.
Differentiating Roles of Program Elements in Action-Oriented Concerns Triggers Connectors Actions Emily Lori Pollock, and Vijay-Shanker.
Plan for Today’s Lecture(s)
Name: Sushmita Laila Khan Affiliation: Georgia Southern University
David Shepherd, Zachary P. Fry, Emily Hill, Lori Pollock, and K
Reading: Pedro Domingos: A Few Useful Things to Know about Machine Learning source: /cacm12.pdf reading.
Multimedia Information Retrieval
Mining and Analyzing Data from Open Source Software Repository
Applying Key Phrase Extraction to aid Invalidity Search
Semantic Similarity Methods in WordNet and their Application to Information Retrieval on the Web Yizhe Ge.
Bug Localization with Combination of Deep Learning and Information Retrieval A. N. Lam et al. International Conference on Program Comprehension 2017.
Presentation transcript:

Exploring the Neighborhood with Dora to Expedite Software Maintenance Emily Hill, Lori Pollock, K. Vijay-Shanker University of Delaware

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Program Exploration for Maintenance You are here Relevant Neighborhood

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Running Example Scenario Exploration Task: Locate code related to ‘add auction’ trigger Starting point: DoAction() method, from prior knowledge eBay auction sniping (bidding) program has bug in add auction event trigger

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware DoNada() Exploring with only structural information Looking for: ‘add auction’ trigger DoAction() has 40 callees And what if you wanted to explore more than one edge away? DoAction()  Locates locally relevant items  But too many irrelevant Only 2/40 methods relevant DoNada() DoAdd() DoPasteFromClipboard()

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Alternative: Exploring with only lexical information Looking for: ‘add auction’ trigger in 1902 methods (159 files, 23KLOC) Use lexical information from comments & identifiers Search with query ‘add*auction’ 91 query matches in 50 methods Only 2/50 methods are relevant  Locates globally relevant items  But too many irrelevant

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Dora gets it right… Looking for: ‘add auction’ trigger Structural:guide exploration from starting point Lexical: prunes irrelevant edges DoNada() Relevant Neighborhood DoAction() DoPasteFromClipboard() DoAdd()

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Software Maintenance: Dora to the rescue Developers spend more time finding and understanding code than actually fixing bugs [Kersten & Murphy 2005, Ko et al. 2005] Critical need for automated tools to help developers explore and understand today’s large & complex software  Key Contribution: Automated tools can use program structure and identifier names to save the developer time and effort

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Dora the Program Explorer * * Dora comes from exploradora, the Spanish word for a female explorer. Dora Natural Language Query Maintenance request Expert knowledge Query expansion Natural Language Query Maintenance request Expert knowledge Query expansion Relevant Neighborhood Program Structure Representation Current: call graph Seed starting point Program Structure Representation Current: call graph Seed starting point Relevant Neighborhood Subgraph relevant to query Query

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware The Dora Approach 1. Obtain set of methods one call edge away from seed 2. Determine each method’s relevance to query  Calculate lexical-based relevance score 3. Prune low-scored methods from neighborhood, using threshold 4. Recursively explore Prune irrelevant structural edges from seed

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware The Dora Approach 1. Obtain set of methods one call edge away from seed 2. Determine each method’s relevance to query  Calculate lexical-based relevance score 3. Prune low-scored methods from neighborhood, using threshold 4. Recursively explore Prune irrelevant structural edges from seed  Calculate lexical-based relevance score

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Calculating Relevance Score: Term Frequency Score based on number of occurrences of query terms in the method Intuition: The more query terms in a method, the more likely it is relevant Query: ‘add auction’ 6 query term occurrences Only 2 occurrences

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Calculating Relevance Score: Inverse Document Frequency What about terms that appear all over the program? Use inverse document frequency (idf) Intuition: Highly weight terms that appear in few documents/methods Terms appearing all over program not good discriminators Don’t separate relevant from irrelevant methods =Number of methods / number of methods containing the term 1902 Methods public idf = 1902/1311 = 1.45 auction idf = 1902/415 = 4.58 add idf = 1902/258 = 7.37 password idf = 1902/29 = Methods public idf = 1902/1311 = 1.45 auction idf = 1902/415 = 4.58 add idf = 1902/258 = 7.37 password idf = 1902/29 = Query: ‘add auction’

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Calculating Relevance Score: TF-IDF Score based on method query term frequency (tf) Multiplied by natural log of inverse document frequency (idf) Query: ‘add auction’ 6 query term occurrences tf-idf = 4  ln(7.37) + 2  ln(4.58) = query term occurrences tf-idf = 4  ln(7.37) + 2  ln(4.58) = AddAuction Only 2 occurrences tf-idf = 2  ln(4.58) = 3.04 Only 2 occurrences tf-idf = 2  ln(4.58) = 3.04 Auction

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Weigh term frequency (tf-idf) based on location: Method name more important than body Method body statements normalized by length Calculating Relevance Score: What about location? ? Query: ‘add auction’

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Factors ∑ tf-idf for each query term in the method name ∑ tf-idf for each query term in the method body the number of statements in the method How to determine weights? Applied logistic regression Trained on methods from 9 concerns in previous concern location tool evaluation [Shepherd et al. 2007] (A concern is a conceptual unit of the software, such as a feature, requirement, design idiom, or implementation mechanism [Robillard & Murphy 2007].) For details, see paper Dora’s Relevance Score

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Example: Dora explores ‘add auction’ trigger Scores from DoAction() seed: Identified as relevant with 0.5 threshold DoAdd() (0.93) DoPasteFromClipboard() (0.60) With only one false positive DoSave() (0.52) DoNada() DoAction() DoPasteFromClipboard() DoAdd() DoSave()

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Experimental Evaluation: Research Questions Does an integrated lexical- and structural-based approach outperform a purely structural approach? Is a sophisticated lexical scoring technique required, or are naïve lexical scoring techniques sufficient to identify the relevant neighborhood?

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Experimental Evaluation: Design Gold Set: 8 concerns from 4 Java programs, manually mapped by 3 independent developers [Robillard et al. 2007] Compare 4 exploration techniques: 1 structural, 3 lexical + structural Structural: Suade [Robillard 2005] Automatically generates exploration suggestions from seed set Elements that have few connections outside the seed set are more relevant Uses caller/callee & field def-use information to make recommendations Lexical + Structural: Dora (sophisticated) Lexical + Structural: boolean AND (naïve) Lexical + Structural: boolean OR (naïve)

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Experimental Evaluation: Design Gold Set: 8 concerns from 4 Java programs, manually mapped by 3 independent developers [Robillard et al. 2007] Compare 4 exploration techniques: 1 structural, 3 lexical + structural Measures: Precision (P), Recall (R), & F Measure (F) P = (Are the results returned actually relevant?) R = (How close are the returned results to the gold set?) F = (High when P & R are similarly high) TP TP+FP TP TP+FN 2PR P+R

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Experimental Evaluation: Design Gold Set: 8 concerns from 4 Java programs, manually mapped by 3 independent developers [Robillard et al. 2007] Compare 4 exploration techniques: 1 structural, 3 lexical + structural Measures: Precision (P), Recall (R), & F Measure (F) Methodology For each exploration technique t For each method m in the gold set  Score each caller & callee of m with t  Calculate P, R, & F for m with t 160 seed methods, 1885 call edges (with overlap)

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Results: All Concerns Dora outperforms Suade with statistical significance (  = 0.05) Dora, OR, and Suade perform significantly better than AND Dora and Suade not significantly different from OR (  = 0.05) OR > Suade, p = 0.43 Dora > OR, p = Dora > Suade, p = Dora achieves 100% P & R for 25% of the data  more than any other technique

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Results: By Concern Overall trend also seen for most concerns Exceptions: 9 & 12 AND had much higher precision Relevant methods contained both query terms

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Experimental Evaluation: Result Summary Does an integrated lexical- and structural-based approach (Dora) outperform a purely structural approach (Suade)?  Dora outperforms Suade with statistical significance (  = 0.05) Is a sophisticated lexical scoring technique required, or are naïve lexical scoring techniques sufficient to identify the relevant neighborhood?  Although not statistically significant, Dora outperforms OR  Dora, Suade, & OR outperform AND (  = 0.05)  Integrated lexical- and structural-based approaches can outperform purely structural, but not all lexical scoring mechanisms are sufficient to do so

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Related Work Automated Program Exploration Using program structure from seed starting element Slicing [Tip 1995, Xu et al. 2005, Sridharan et al. 2007] Suade [Robillard 2005] Using lexical information in comments and identifiers Regular expressions: grep, Eclipse Search Advanced IR: FindConcept [Shepherd et al. 2007], LSI [Marcus et al. 2004], Google Eclipse Search [Poshyvanyk et al. 2006] Additional work in paper

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Future Work Automatically find starting seeds Use more sophisticated lexical information Synonyms, topic words (currency, price related to bidding) Abbreviation expansion Evaluate on slicing

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Conclusion  Integrated lexical- and structural-based approaches outperform purely structural ones This work was supported by an NSF Graduate Research Fellowship and Award CCF

Appendix Additional Materials

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Dora’s Relevance Score The model: Where… bin = binary (1 if java file exists, 0 otherwise) name = ∑ tf-idf for each query term in the method name statement = ∑ tf-idf for each query term in a method statement the number of statements in the method Developing the relevance score Used logistic regression: predicts values between 0 and 1 Logistic regression outputs ‘x’ of the score Training the model Used methods from 9 concerns in previous concern location tool evaluation [Shepherd 2007]

Exploring the Neighborhood with DoraASE 2007Emily Hill  University of Delaware Results: Threshold