Modeling the Ownership of Source Code Topics

Modeling the Ownership of Source Code Topics

Appearing in the 20th IEEE International Conference
on Program Comprehension (http://icpc12.sosy-lab.org/)

Modeling the Ownership of Source Code Topics
Christopher S. Corley, Elizabeth A. Kammer, and Nicholas A. Kraft
(University of Alabama, USA)

Abstract
Exploring linguistic topics in source code is a program comprehension activity that shows promise in helping a developer to become familiar with an unfamiliar software system. Examining ownership in source code can reveal complementary information, such as who to contact with questions regarding a source code entity, but the relationship between linguistic topics and ownership is an unexplored area. In this paper we combine software repository mining and topic modeling to measure the ownership of linguistic topics in source code. We conduct an exploratory study of the relationship between linguistic topics and ownership in source code using 10 open source Java systems. We find that classes that belong to the same linguistic topic tend to have similar ownership characteristics, which suggests that conceptually related classes often share the same owner(s). We also find that similar topics tend to share the same ownership characteristics, which suggests that the same developers own related topics.

02498ca4cb73f57dc33c2642cd70fef2?s=128

Christopher Corley

June 13, 2012
Tweet

Transcript

  1. 1.

    C.S. Corley, E. A. Kammer, and N. A. Kraft Department

    of Computer Science, The University of Alabama ICPC’12 Modeling the Ownership of Source Code Topics
  2. 3.

    top· ic /ˈtɒpɪk/ noun A matter dealt with in a

    text, discourse, or conversation; a subject
  3. 8.
  4. 9.
  5. 10.
  6. 17.
  7. 21.
  8. 30.
  9. 32.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 >
  10. 33.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 > topic FooBarYak: < 5, 34, 9, 2, 2 >
  11. 36.
  12. 37.

    Document Document Document Document Document Document Document Document Document Document

    Document Document Document Document Document Document Document Document Documents Subtopics Supertopics System topic
  13. 39.

    ! ! ! ! ! ! ! ! ! !

    ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! 0.0 0.5 1.0
  14. 40.

    ! ! ! ! ! ! ! 0.0 0.5 1.0

    Ant ArgoUML CAROL GWT iText JabRef jEdit JHotDraw Subversive Vuze
  15. 41.
  16. 42.
  17. 44.

    Document Document Document Document Document Document Document Document Document Document

    Document Document Document Document Document Document Document Document Documents Subtopics Supertopics System topic
  18. 47.
  19. 53.

    Thanks! C.S. Corley, E. A. Kammer, and N. A. Kraft

    Department of Computer Science, The University of Alabama Images used: http://flic.kr/y/my4BeJ Modeling the Ownership of Source Code Topics History miner: http://github.com/software-eng-ua-edu/ohm
  20. 54.

    address port network inet tcp socket udp proxy admin nat

    host protocol bind local socks addresses server interface exception http
  21. 56.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 > topic FooBarYak: < 5, 34, 9, 2, 2 >
  22. 57.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 > topic FooBarYak: < 5, 34, 9, 2, 2 >
  23. 58.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 > topic FooBarYak: < 5, 34, 9, 2, 2 > 0.956
  24. 59.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 > topic FooBarYak: < 5, 34, 9, 2, 2 > 0.956
  25. 60.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 > topic FooBarYak: < 5, 34, 9, 2, 2 > 0.956
  26. 61.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 > topic FooBarYak: < 5, 34, 9, 2, 2 > 0.956 0.04
  27. 62.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 > topic FooBarYak: < 5, 34, 9, 2, 2 > 0.956 0.04
  28. 63.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 > topic FooBarYak: < 5, 34, 9, 2, 2 > 0.956 0.04
  29. 64.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 > topic FooBarYak: < 5, 34, 9, 2, 2 > 0.956 0.0 0.04
  30. 65.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 > topic FooBarYak: < 5, 34, 9, 2, 2 > 0.956 0.0 0.04
  31. 66.

    class Foo: < 4, 32, 9, 0, 0 > class

    Bar: < 0, 2, 0, 0, 0 > class Yak: < 1, 0, 0, 2, 2 > topic FooBarYak: < 5, 34, 9, 2, 2 > 0.956 0.0 0.04 0.332
  32. 67.

    package edu.ua.eng.software.ohm; /* This is our Brick class. It will

    represent bricks * we can use to build things with. Bricks are cool. */ class Brick { private int width; private int height; public Brick(int width, int height){ // Set this brick's dimensions this.width = width; this.height = height; } public String toString(){ return "Brick is " + width + " wide and " + height + " tall!"; } }
  33. 68.

    package edu.ua.eng.software.ohm; /* This is our Brick class. It will

    represent bricks * we can use to build things with. Bricks are cool. */ class Brick { private int width; private int height; public Brick(int width, int height){ // Set this brick's dimensions this.width = width; this.height = height; } public String toString(){ return "Brick is " + width + " wide and " + height + " tall!"; } }
  34. 69.

    package edu.ua.eng.software.ohm; /* This is our Brick class. It will

    represent bricks * we can use to build things with. Bricks are cool. */ class Brick { private int width; private int height; public Brick(int width, int height){ // Set this brick's dimensions this.width = width; this.height = height; } public String toString(){ return "Brick is " + width + " wide and " + height + " tall!"; } }
  35. 70.

    package edu.ua.eng.software.ohm; /* This is our Brick class. It will

    represent bricks * we can use to build things with. Bricks are cool. */ class Brick { private int width; private int height; public Brick(int width, int height){ // Set this brick s dimensions this width = width; this.height = height; } public String to String(){ return "Brick is " + width + " wide and " + height + " tall!"; } }
  36. 71.

    package edu.ua.eng.software.ohm; /* this is our brick class. it will

    represent bricks * we can use to build things with. bricks are cool. */ class brick{ private int width; private int height; public brick(int width, int height){ // set this brick s dimensions this width = width; this height = height; } public String to string(){ return "brick is " + width + " wide and " + height + " tall!"; } }
  37. 72.

    package edu.ua.eng.software.ohm; /* this is our brick class. it will

    represent bricks * we can use to build things with. bricks are cool. */ class brick{ private int width; private int height; public brick(int width, int height){ // set this brick s dimensions this width = width; this height = height; } public String to string(){ return "brick is " + width + " wide and " + height + " tall!"; } }
  38. 74.

    ! ! ! ! ! ! ! ! ! !

    ! 0.0 0.5 1.0
  39. 77.

    ! ! ! ! ! ! ! ! ! !

    ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! 0.0 0.5 1.0
  40. 81.

    ! ! ! ! ! ! ! ! ! !

    ! ! ! 0.0 0.5 1.0
  41. 82.

    ! ! ! ! ! ! ! ! ! !

    ! 0.0 0.5 1.0
  42. 83.

    ! ! ! ! ! ! ! ! ! !

    ! 0.0 0.5 1.0