Supporting Programmers in Naming Identifiers Surafel Lemma Abebe and Paolo Tonella Software Engineering Research Unit Fondazione Bruno Kessler Trento, Italy TAinSM 2012 Motivation V1.0 V2.0 V3.0 V4.0 V? What name shall I give to this identifier? 2 Identifier Name Suggestion • Candidate name suggestion • Completion • Replacement Example: server Example: file Example: message {content, subject matter, substance} Prefix Ontological relation Synonyms Ontology Term list Candidate sentence Sentence selection Concept and relation extraction 3 Identifier Name Suggestion… • Prioritizing candidates – “Relevance” to a context (X) – Example: X= {mail, sender} 4 GUI Requirements and Evaluation • Reenacting possible activity of developers – Success rate: probability of getting correct suggestions – Average rank: average rank of top concept in a successful suggestion 5 Thank you! 6