Using developer eye movements to externalize the mental model used in code summarization tasks

Nahla J. Abid, Jonathan I. Maletic and Bonita Sharif

Abstract

Eye movements of developers are used to speculate the mental cognition model (i.e., bottom-up or top-down) applied during program comprehension tasks. The cognition models examine how programmers understand source code by describing the temporary information structures in the programmer's short term memory. The two types of models that we are interested in are top-down and bottom-up. The top-down model is normally applied as-needed (i.e., the domain of the system is familiar). The bottom-up model is typically applied when a developer is not familiar with the domain or the source code. An eye-tracking study of 18 developers reading and summarizing Java methods is used as our dataset for analyzing the mental cognition model. The developers provide a written summary for methods assigned to them. In total, 63 methods are used from five different systems. The results indicate that on average, experts and novices read the methods more closely (using the bottom-up mental model) than bouncing around (using top-down). However, on average novices spend longer gaze time performing bottom-up (66s.) compared to experts (43s.)

Venue
ETRA 2019
Volume
Proceedings of the 11th ACM Symposium on Eye Tracking Research & Applications
DOI
10.1145/3314111.3319834
PDF
https://dl.acm.org/doi/pdf/10.1145/3314111.3319834
Anthology ID
2019.etra.38

Cite

@inproceedings{abid-etal-2019-using,
    title = {{Using developer eye movements to externalize the mental model used in code summarization tasks}},
    author = {Nahla J. Abid and Jonathan I. Maletic and Bonita Sharif},
    booktitle = {Proceedings of the 11th ACM Symposium on Eye Tracking Research \& Applications},
    isbn = {9781450367097},
    year = {2019},
    publisher = {Association for Computing Machinery},
    address = {New York, NY, USA},
    doi = {10.1145/3314111.3319834},
    url = {https://doi.org/10.1145/3314111.3319834},
    abstract = {Eye movements of developers are used to speculate the mental cognition model (i.e., bottom-up or top-down) applied during program comprehension tasks. The cognition models examine how programmers understand source code by describing the temporary information structures in the programmer's short term memory. The two types of models that we are interested in are top-down and bottom-up. The top-down model is normally applied as-needed (i.e., the domain of the system is familiar). The bottom-up model is typically applied when a developer is not familiar with the domain or the source code. An eye-tracking study of 18 developers reading and summarizing Java methods is used as our dataset for analyzing the mental cognition model. The developers provide a written summary for methods assigned to them. In total, 63 methods are used from five different systems. The results indicate that on average, experts and novices read the methods more closely (using the bottom-up mental model) than bouncing around (using top-down). However, on average novices spend longer gaze time performing bottom-up (66s.) compared to experts (43s.)}
}