SlideShare a Scribd company logo
QwalKeko,
a History Querying Tool
         Reinout Stevens
       resteven@vub.ac.be
        @ReinoutStevens
Context




  Program
Comprehension

                2
Was this method pulled up?
Who introduced
  this class?
                                  Who has made changes to
                                        my classes?

         History Questions
                                   How often is this method
Why were these changes                    changed?
     introduced?         Template-based Reconstruction of Complex Refactorings
                         Kyle Prete, Napol Rachatasumrit, Nikita Sudan, Miryung Kim
                         International Conference on Software Maintenance (ICSM), p.1--10, 2010

                         Using Information Fragments to Answer the Questions Developers Ask
                         Thomas Fritz and Gail C. Murphy
                         International Conference on Software Engineering (ICSE), p.175--184, 2010
                                3
Was this method pulled up?
Who introduced
  this class?
                                  Who has made changes to
                                        my classes?

         History Questions
                                   How often is this method
Why were these changes                    changed?
     introduced?         Template-based Reconstruction of Complex Refactorings
                         Kyle Prete, Napol Rachatasumrit, Nikita Sudan, Miryung Kim
                         International Conference on Software Maintenance (ICSM), p.1--10, 2010

                         Using Information Fragments to Answer the Questions Developers Ask
                         Thomas Fritz and Gail C. Murphy
                         International Conference on Software Engineering (ICSE), p.175--184, 2010
                                3
Pulled up Method
1   pull_up_method(fShortName, tChildFullName, tParentFullName) :-
2     move_method(fShortName, tChildFullName, tParentFullName) ^
3     before_subtype(tParentFullName, tChildFullName)




                               Template-based Reconstruction of Complex Refactorings
                               Kyle Prete, Napol Rachatasumrit, Nikita Sudan, Miryung Kim
                               International Conference on Software Maintenance (ICSM), p.1--10, 2010

                                      4
Pulled up Method
1   pull_up_method(fShortName, tChildFullName, tParentFullName) :-
2     move_method(fShortName, tChildFullName, tParentFullName) ^
3     before_subtype(tParentFullName, tChildFullName)




1   move_method(mShortName, t1Fullname, t2FullName) :-
2     deleted_method(mFullName, mShortName, t1FullName) ^
3     added_method(newmName, mShortName, t2FullName) ^
4     similarbody(newmName, newmBody, mFullName, mBody)




                               Template-based Reconstruction of Complex Refactorings
                               Kyle Prete, Napol Rachatasumrit, Nikita Sudan, Miryung Kim
                               International Conference on Software Maintenance (ICSM), p.1--10, 2010

                                      4
Version Control Systems
                          Version   Version
                            3a        4a




                                              Version
  Version 1   Version 2                          5




                          Version   Version
                            3b        4b




                          5
History Query Tool
        Pr                Graph Query
          og                Language
            ra
         La m




                                                     od ry
           ng Q           Move through the




                                                       sto
                                                       el
             ua ue        version graph




                                                  Hi
               ge ry




                                                    M
                                             Source code of each version
Specify characteristics                      Commit information
in a single version                          Entity tracking
                                             ...




                                 6
QwalKeko
Pr             Graph Query
  og             Language
    ra
 La m




                              od ry
   ng Q           Qwal




                                sto
                                el
     ua ue




                             Hi
       ge ry




                             M
 Ekeko                        +




                    7
Applicative LMP
... specify code characteristics through Ekeko relations,
leave search to core.logic
                            collection of all substitutions for ?s and ?e


       (run* [?s ?e]
           (ast :ReturnStatement ?s)
           (has :expression ?s ?e)
           (ast :NullLiteral ?e))


                             such that the following Ekeko relations hold:
                                  ast/2 holds for :ReturnStatement, ?s        ?e is the value of the
                                                                                     property
                                  has/3 holds for :expression, ?s, and ?e
                                                                              named :expression of
([?s1 ?e2] ... [?sn ?en])         ast/2 holds for :NullLiteral, ?e                 ASTNode ?s


                ([#<ReturnStatement return null;
                  #<NullLiteral null>]
                 ...
                                                                        actual search performed by
                 [#<ReturnStatement return null;                        core.logic
                  #<NullLiteral null>])     8
Qwal
               foo       bar      baz




1   (run* [?end]
2     (qwal graph :foo ?end
3       []
4       (qcurrent [curr] (has-info curr :foo))




                         9
Qwal
               foo       bar      baz




1   (run* [?end]
2     (qwal graph :foo ?end
3       []
4       (qcurrent [curr] (has-info curr :foo))
5       q=>
6       (qcurrent [curr] (has-info curr :bar))




                         9
Qwal
               foo          bar      baz




1   (run* [?end]
2     (qwal graph    :foo ?end
3       []
4       (qcurrent    [curr] (has-info curr :foo))
5       q=>
6       (qcurrent    [curr] (has-info curr :bar))
7       q=>
8       (qcurrent    [curr] (has-info curr :baz)))




                            9
Introduced Subclasses
  1   (qwal graph start ?end [?parent ?child]
  2     (qin-current
  3       (ast :TypeDeclaration ?parent))
  4     (q=>+) ;;skip >= 1 versions
  5     (qin-current
  6       (subclass ?parent ?child)
  7       (introduced ?child)))




                      10
Same Predicate
(defn same [?entity ?other-entity]
  ...)

       Ground in a previous version

                   Ground in current version



                   11
Same Predicate
(defn same [?entity ?other-entity]
  ...)


       1   (defn introduced [?entity]
       2     (fresh [?same]
       3       q<=
       4       (not (same ?entity ?same)))




                         12
Recall...
1   pull_up_method(fShortName, tChildFullName, tParentFullName) :-
2     move_method(fShortName, tChildFullName, tParentFullName) ^
3     before_subtype(tParentFullName, tChildFullName)




1   move_method(mShortName, t1Fullname, t2FullName) :-
2     deleted_method(mFullName, mShortName, t1FullName) ^
3     added_method(newmName, mShortName, t2FullName) ^
4     similarbody(newmName, newmBody, mFullName, mBody)




                                   13
Pulled up Method
1       (defn pulled-up [?method ?pulled]
2         (fresh [?m-class ?p-class]
3           (method-moved ?method ?pulled)
4           (declaring-class ?method ?m-class)
5           (declaring-class ?pulled ?p-class)
6           (superclass ?m-class ?p-class)))


    1   (defn method-moved [?moved ?to]
    2     (removed ?moved) ;;implemented using same
    3     (ast :MethodDeclaration ?to)
    4     (== ?moved ?to) ;;unify when same signature
    5     (has-similar-body ?moved ?to)))




                           14
Pulled up Method

1 (qwal graph root ?end [?method ?pulled]
2   (qin-current
3     (ast :MethodDeclaration ?method))
4   q=> ;;go to next version
5   (qin-current
6     (pulled-up ?method ?pulled)))




                     15
Generalized Rule

1 (qwal graph root ?end [?method ?pulled]
2   (qin-current
3     (ast :MethodDeclaration ?method))
4   (q=>+) ;;skip >=1 versions
5   (qin-current
6     (pulled-up ?method ?pulled)))




                     16
Questions

               Reinout Stevens
             resteven@vub.ac.be
               @ReinoutStevens
http://github.com/ReinoutStevens/damp.qwal
  http://github.com/cderoove/damp.ekeko




                    17

More Related Content

What's hot

Refactoring Edit History of Source Code
Refactoring Edit History of Source CodeRefactoring Edit History of Source Code
Refactoring Edit History of Source Code
Shinpei Hayashi
 
Introduction to julia
Introduction to juliaIntroduction to julia
Introduction to julia
岳華 杜
 
Metaprogramming in julia
Metaprogramming in juliaMetaprogramming in julia
Metaprogramming in julia
岳華 杜
 
Commit ускоривший python 2.7.11 на 30% и новое в python 3.5
Commit ускоривший python 2.7.11 на 30% и новое в python 3.5Commit ускоривший python 2.7.11 на 30% и новое в python 3.5
Commit ускоривший python 2.7.11 на 30% и новое в python 3.5
PyNSK
 
OOP and FP
OOP and FPOOP and FP
OOP and FP
Mario Fusco
 
Automatic Task-based Code Generation for High Performance DSEL
Automatic Task-based Code Generation for High Performance DSELAutomatic Task-based Code Generation for High Performance DSEL
Automatic Task-based Code Generation for High Performance DSEL
Joel Falcou
 
Attention mechanisms with tensorflow
Attention mechanisms with tensorflowAttention mechanisms with tensorflow
Attention mechanisms with tensorflow
Keon Kim
 
Cbse marking scheme 2006 2011
Cbse marking scheme 2006  2011Cbse marking scheme 2006  2011
Cbse marking scheme 2006 2011
Praveen M Jigajinni
 
901230 lecture5&6
901230 lecture5&6901230 lecture5&6
901230 lecture5&6
Enad Almasri
 
Chapter03
Chapter03Chapter03
Chapter03
春男 洪
 
Pf congres20110917 data-structures
Pf congres20110917 data-structuresPf congres20110917 data-structures
Pf congres20110917 data-structuresnorm2782
 
Structure and interpretation of computer programs modularity, objects, and ...
Structure and interpretation of computer programs   modularity, objects, and ...Structure and interpretation of computer programs   modularity, objects, and ...
Structure and interpretation of computer programs modularity, objects, and ...
bdemchak
 
C++ questions And Answer
C++ questions And AnswerC++ questions And Answer
C++ questions And Answer
lavparmar007
 
Boost.Dispatch
Boost.DispatchBoost.Dispatch
Boost.Dispatch
Joel Falcou
 
Logic programming a ruby perspective
Logic programming a ruby perspectiveLogic programming a ruby perspective
Logic programming a ruby perspective
Norman Richards
 
Clojure: The Art of Abstraction
Clojure: The Art of AbstractionClojure: The Art of Abstraction
Clojure: The Art of Abstraction
Alex Miller
 
Cp0675 03 may-2012-rm04
Cp0675 03 may-2012-rm04Cp0675 03 may-2012-rm04
Cp0675 03 may-2012-rm04Parth Mudgal
 
The Ring programming language version 1.4 book - Part 3 of 30
The Ring programming language version 1.4 book - Part 3 of 30The Ring programming language version 1.4 book - Part 3 of 30
The Ring programming language version 1.4 book - Part 3 of 30
Mahmoud Samir Fayed
 
Chapter 5 - THREADING & REGULAR exp - MAULIK BORSANIYA
Chapter 5 - THREADING & REGULAR exp - MAULIK BORSANIYAChapter 5 - THREADING & REGULAR exp - MAULIK BORSANIYA
Chapter 5 - THREADING & REGULAR exp - MAULIK BORSANIYA
Maulik Borsaniya
 

What's hot (20)

Refactoring Edit History of Source Code
Refactoring Edit History of Source CodeRefactoring Edit History of Source Code
Refactoring Edit History of Source Code
 
Introduction to julia
Introduction to juliaIntroduction to julia
Introduction to julia
 
Metaprogramming in julia
Metaprogramming in juliaMetaprogramming in julia
Metaprogramming in julia
 
Commit ускоривший python 2.7.11 на 30% и новое в python 3.5
Commit ускоривший python 2.7.11 на 30% и новое в python 3.5Commit ускоривший python 2.7.11 на 30% и новое в python 3.5
Commit ускоривший python 2.7.11 на 30% и новое в python 3.5
 
OOP and FP
OOP and FPOOP and FP
OOP and FP
 
Automatic Task-based Code Generation for High Performance DSEL
Automatic Task-based Code Generation for High Performance DSELAutomatic Task-based Code Generation for High Performance DSEL
Automatic Task-based Code Generation for High Performance DSEL
 
Attention mechanisms with tensorflow
Attention mechanisms with tensorflowAttention mechanisms with tensorflow
Attention mechanisms with tensorflow
 
Cbse marking scheme 2006 2011
Cbse marking scheme 2006  2011Cbse marking scheme 2006  2011
Cbse marking scheme 2006 2011
 
901230 lecture5&6
901230 lecture5&6901230 lecture5&6
901230 lecture5&6
 
Chapter03
Chapter03Chapter03
Chapter03
 
Pf congres20110917 data-structures
Pf congres20110917 data-structuresPf congres20110917 data-structures
Pf congres20110917 data-structures
 
Structure and interpretation of computer programs modularity, objects, and ...
Structure and interpretation of computer programs   modularity, objects, and ...Structure and interpretation of computer programs   modularity, objects, and ...
Structure and interpretation of computer programs modularity, objects, and ...
 
Meta Object Protocols
Meta Object ProtocolsMeta Object Protocols
Meta Object Protocols
 
C++ questions And Answer
C++ questions And AnswerC++ questions And Answer
C++ questions And Answer
 
Boost.Dispatch
Boost.DispatchBoost.Dispatch
Boost.Dispatch
 
Logic programming a ruby perspective
Logic programming a ruby perspectiveLogic programming a ruby perspective
Logic programming a ruby perspective
 
Clojure: The Art of Abstraction
Clojure: The Art of AbstractionClojure: The Art of Abstraction
Clojure: The Art of Abstraction
 
Cp0675 03 may-2012-rm04
Cp0675 03 may-2012-rm04Cp0675 03 may-2012-rm04
Cp0675 03 may-2012-rm04
 
The Ring programming language version 1.4 book - Part 3 of 30
The Ring programming language version 1.4 book - Part 3 of 30The Ring programming language version 1.4 book - Part 3 of 30
The Ring programming language version 1.4 book - Part 3 of 30
 
Chapter 5 - THREADING & REGULAR exp - MAULIK BORSANIYA
Chapter 5 - THREADING & REGULAR exp - MAULIK BORSANIYAChapter 5 - THREADING & REGULAR exp - MAULIK BORSANIYA
Chapter 5 - THREADING & REGULAR exp - MAULIK BORSANIYA
 

Viewers also liked

QwalKeko, a History Querying Tool
QwalKeko, a History Querying ToolQwalKeko, a History Querying Tool
QwalKeko, a History Querying Tool
stevensreinout
 
Query History of a Software Project
Query History of a Software ProjectQuery History of a Software Project
Query History of a Software Project
stevensreinout
 
QwalKeko, a History Querying Tool
QwalKeko, a History Querying ToolQwalKeko, a History Querying Tool
QwalKeko, a History Querying Toolstevensreinout
 
Reasoning over the evolution of source code using QRPE
Reasoning over the evolution of source code using QRPEReasoning over the evolution of source code using QRPE
Reasoning over the evolution of source code using QRPEstevensreinout
 
Querying the History of Software Projects using QwalKeko
Querying the History of Software Projects using QwalKekoQuerying the History of Software Projects using QwalKeko
Querying the History of Software Projects using QwalKeko
stevensreinout
 
SEO: Getting Personal
SEO: Getting PersonalSEO: Getting Personal
SEO: Getting Personal
Kirsty Hulse
 
Lightning Talk #9: How UX and Data Storytelling Can Shape Policy by Mika Aldaba
Lightning Talk #9: How UX and Data Storytelling Can Shape Policy by Mika AldabaLightning Talk #9: How UX and Data Storytelling Can Shape Policy by Mika Aldaba
Lightning Talk #9: How UX and Data Storytelling Can Shape Policy by Mika Aldaba
ux singapore
 
Succession “Losers”: What Happens to Executives Passed Over for the CEO Job?
Succession “Losers”: What Happens to Executives Passed Over for the CEO Job? Succession “Losers”: What Happens to Executives Passed Over for the CEO Job?
Succession “Losers”: What Happens to Executives Passed Over for the CEO Job?
Stanford GSB Corporate Governance Research Initiative
 

Viewers also liked (8)

QwalKeko, a History Querying Tool
QwalKeko, a History Querying ToolQwalKeko, a History Querying Tool
QwalKeko, a History Querying Tool
 
Query History of a Software Project
Query History of a Software ProjectQuery History of a Software Project
Query History of a Software Project
 
QwalKeko, a History Querying Tool
QwalKeko, a History Querying ToolQwalKeko, a History Querying Tool
QwalKeko, a History Querying Tool
 
Reasoning over the evolution of source code using QRPE
Reasoning over the evolution of source code using QRPEReasoning over the evolution of source code using QRPE
Reasoning over the evolution of source code using QRPE
 
Querying the History of Software Projects using QwalKeko
Querying the History of Software Projects using QwalKekoQuerying the History of Software Projects using QwalKeko
Querying the History of Software Projects using QwalKeko
 
SEO: Getting Personal
SEO: Getting PersonalSEO: Getting Personal
SEO: Getting Personal
 
Lightning Talk #9: How UX and Data Storytelling Can Shape Policy by Mika Aldaba
Lightning Talk #9: How UX and Data Storytelling Can Shape Policy by Mika AldabaLightning Talk #9: How UX and Data Storytelling Can Shape Policy by Mika Aldaba
Lightning Talk #9: How UX and Data Storytelling Can Shape Policy by Mika Aldaba
 
Succession “Losers”: What Happens to Executives Passed Over for the CEO Job?
Succession “Losers”: What Happens to Executives Passed Over for the CEO Job? Succession “Losers”: What Happens to Executives Passed Over for the CEO Job?
Succession “Losers”: What Happens to Executives Passed Over for the CEO Job?
 

Similar to QwalKeko, a History Querying Tool

Extracting Executable Transformations from Distilled Code Changes
Extracting Executable Transformations from Distilled Code ChangesExtracting Executable Transformations from Distilled Code Changes
Extracting Executable Transformations from Distilled Code Changes
stevensreinout
 
Profiling Ruby
Profiling RubyProfiling Ruby
Profiling Ruby
Ian Pointer
 
Mksong proposal-slide
Mksong proposal-slideMksong proposal-slide
Mksong proposal-slidemksong
 
JavaScript OOPs
JavaScript OOPsJavaScript OOPs
JavaScript OOPs
Johnson Chou
 
If You Think You Can Stay Away from Functional Programming, You Are Wrong
If You Think You Can Stay Away from Functional Programming, You Are WrongIf You Think You Can Stay Away from Functional Programming, You Are Wrong
If You Think You Can Stay Away from Functional Programming, You Are WrongMario Fusco
 
Python for Chemistry
Python for ChemistryPython for Chemistry
Python for Chemistrybaoilleach
 
Python for Chemistry
Python for ChemistryPython for Chemistry
Python for Chemistryguest5929fa7
 
Threading Is Not A Model
Threading Is Not A ModelThreading Is Not A Model
Threading Is Not A Modelguest2a5acfb
 
Pune Clojure Course Outline
Pune Clojure Course OutlinePune Clojure Course Outline
Pune Clojure Course Outline
Baishampayan Ghose
 
Python 3.6 Features 20161207
Python 3.6 Features 20161207Python 3.6 Features 20161207
Python 3.6 Features 20161207
Jay Coskey
 
OracleCode One 2018: Java 5, 6, 7, 8, 9, 10, 11: What Did You Miss?
OracleCode One 2018: Java 5, 6, 7, 8, 9, 10, 11: What Did You Miss?OracleCode One 2018: Java 5, 6, 7, 8, 9, 10, 11: What Did You Miss?
OracleCode One 2018: Java 5, 6, 7, 8, 9, 10, 11: What Did You Miss?
Henri Tremblay
 
Lisp Macros in 20 Minutes (Featuring Clojure)
Lisp Macros in 20 Minutes (Featuring Clojure)Lisp Macros in 20 Minutes (Featuring Clojure)
Lisp Macros in 20 Minutes (Featuring Clojure)
Phil Calçado
 
Hands-on Learning with KubeFlow + Keras/TensorFlow 2.0 + TF Extended (TFX) + ...
Hands-on Learning with KubeFlow + Keras/TensorFlow 2.0 + TF Extended (TFX) + ...Hands-on Learning with KubeFlow + Keras/TensorFlow 2.0 + TF Extended (TFX) + ...
Hands-on Learning with KubeFlow + Keras/TensorFlow 2.0 + TF Extended (TFX) + ...
Chris Fregly
 
Introduction to Julia
Introduction to JuliaIntroduction to Julia
Introduction to Julia
岳華 杜
 
String Comparison Surprises: Did Postgres lose my data?
String Comparison Surprises: Did Postgres lose my data?String Comparison Surprises: Did Postgres lose my data?
String Comparison Surprises: Did Postgres lose my data?
Jeremy Schneider
 
r,rstats,r language,r packages
r,rstats,r language,r packagesr,rstats,r language,r packages
r,rstats,r language,r packagesAjay Ohri
 
Introduction to source{d} Engine and source{d} Lookout
Introduction to source{d} Engine and source{d} Lookout Introduction to source{d} Engine and source{d} Lookout
Introduction to source{d} Engine and source{d} Lookout
source{d}
 
MODEL OF A PROGRAM AS MULTITHREADED STOCHASTIC AUTOMATON AND ITS EQUIVALENT T...
MODEL OF A PROGRAM AS MULTITHREADED STOCHASTIC AUTOMATON AND ITS EQUIVALENT T...MODEL OF A PROGRAM AS MULTITHREADED STOCHASTIC AUTOMATON AND ITS EQUIVALENT T...
MODEL OF A PROGRAM AS MULTITHREADED STOCHASTIC AUTOMATON AND ITS EQUIVALENT T...
Sergey Staroletov
 
Continuation Passing Style and Macros in Clojure - Jan 2012
Continuation Passing Style and Macros in Clojure - Jan 2012Continuation Passing Style and Macros in Clojure - Jan 2012
Continuation Passing Style and Macros in Clojure - Jan 2012
Leonardo Borges
 
NOSQL and Cassandra
NOSQL and CassandraNOSQL and Cassandra
NOSQL and Cassandrarantav
 

Similar to QwalKeko, a History Querying Tool (20)

Extracting Executable Transformations from Distilled Code Changes
Extracting Executable Transformations from Distilled Code ChangesExtracting Executable Transformations from Distilled Code Changes
Extracting Executable Transformations from Distilled Code Changes
 
Profiling Ruby
Profiling RubyProfiling Ruby
Profiling Ruby
 
Mksong proposal-slide
Mksong proposal-slideMksong proposal-slide
Mksong proposal-slide
 
JavaScript OOPs
JavaScript OOPsJavaScript OOPs
JavaScript OOPs
 
If You Think You Can Stay Away from Functional Programming, You Are Wrong
If You Think You Can Stay Away from Functional Programming, You Are WrongIf You Think You Can Stay Away from Functional Programming, You Are Wrong
If You Think You Can Stay Away from Functional Programming, You Are Wrong
 
Python for Chemistry
Python for ChemistryPython for Chemistry
Python for Chemistry
 
Python for Chemistry
Python for ChemistryPython for Chemistry
Python for Chemistry
 
Threading Is Not A Model
Threading Is Not A ModelThreading Is Not A Model
Threading Is Not A Model
 
Pune Clojure Course Outline
Pune Clojure Course OutlinePune Clojure Course Outline
Pune Clojure Course Outline
 
Python 3.6 Features 20161207
Python 3.6 Features 20161207Python 3.6 Features 20161207
Python 3.6 Features 20161207
 
OracleCode One 2018: Java 5, 6, 7, 8, 9, 10, 11: What Did You Miss?
OracleCode One 2018: Java 5, 6, 7, 8, 9, 10, 11: What Did You Miss?OracleCode One 2018: Java 5, 6, 7, 8, 9, 10, 11: What Did You Miss?
OracleCode One 2018: Java 5, 6, 7, 8, 9, 10, 11: What Did You Miss?
 
Lisp Macros in 20 Minutes (Featuring Clojure)
Lisp Macros in 20 Minutes (Featuring Clojure)Lisp Macros in 20 Minutes (Featuring Clojure)
Lisp Macros in 20 Minutes (Featuring Clojure)
 
Hands-on Learning with KubeFlow + Keras/TensorFlow 2.0 + TF Extended (TFX) + ...
Hands-on Learning with KubeFlow + Keras/TensorFlow 2.0 + TF Extended (TFX) + ...Hands-on Learning with KubeFlow + Keras/TensorFlow 2.0 + TF Extended (TFX) + ...
Hands-on Learning with KubeFlow + Keras/TensorFlow 2.0 + TF Extended (TFX) + ...
 
Introduction to Julia
Introduction to JuliaIntroduction to Julia
Introduction to Julia
 
String Comparison Surprises: Did Postgres lose my data?
String Comparison Surprises: Did Postgres lose my data?String Comparison Surprises: Did Postgres lose my data?
String Comparison Surprises: Did Postgres lose my data?
 
r,rstats,r language,r packages
r,rstats,r language,r packagesr,rstats,r language,r packages
r,rstats,r language,r packages
 
Introduction to source{d} Engine and source{d} Lookout
Introduction to source{d} Engine and source{d} Lookout Introduction to source{d} Engine and source{d} Lookout
Introduction to source{d} Engine and source{d} Lookout
 
MODEL OF A PROGRAM AS MULTITHREADED STOCHASTIC AUTOMATON AND ITS EQUIVALENT T...
MODEL OF A PROGRAM AS MULTITHREADED STOCHASTIC AUTOMATON AND ITS EQUIVALENT T...MODEL OF A PROGRAM AS MULTITHREADED STOCHASTIC AUTOMATON AND ITS EQUIVALENT T...
MODEL OF A PROGRAM AS MULTITHREADED STOCHASTIC AUTOMATON AND ITS EQUIVALENT T...
 
Continuation Passing Style and Macros in Clojure - Jan 2012
Continuation Passing Style and Macros in Clojure - Jan 2012Continuation Passing Style and Macros in Clojure - Jan 2012
Continuation Passing Style and Macros in Clojure - Jan 2012
 
NOSQL and Cassandra
NOSQL and CassandraNOSQL and Cassandra
NOSQL and Cassandra
 

Recently uploaded

Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
Cheryl Hung
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
Product School
 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Inflectra
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
Alison B. Lowndes
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance
 
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Product School
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMsTo Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
Paul Groth
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
Sri Ambati
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
KatiaHIMEUR1
 
Leading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdfLeading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdf
OnBoard
 
Connector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonConnector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a button
DianaGray10
 
Knowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and backKnowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and back
Elena Simperl
 
Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*
Frank van Harmelen
 
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Jeffrey Haguewood
 
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Ramesh Iyer
 
Assuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyesAssuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyes
ThousandEyes
 
Generating a custom Ruby SDK for your web service or Rails API using Smithy
Generating a custom Ruby SDK for your web service or Rails API using SmithyGenerating a custom Ruby SDK for your web service or Rails API using Smithy
Generating a custom Ruby SDK for your web service or Rails API using Smithy
g2nightmarescribd
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Product School
 

Recently uploaded (20)

Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
 
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
From Daily Decisions to Bottom Line: Connecting Product Work to Revenue by VP...
 
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualitySoftware Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
 
Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........Bits & Pixels using AI for Good.........
Bits & Pixels using AI for Good.........
 
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdfFIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
FIDO Alliance Osaka Seminar: Passkeys at Amazon.pdf
 
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMsTo Graph or Not to Graph Knowledge Graph Architectures and LLMs
To Graph or Not to Graph Knowledge Graph Architectures and LLMs
 
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
GenAISummit 2024 May 28 Sri Ambati Keynote: AGI Belongs to The Community in O...
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
 
Leading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdfLeading Change strategies and insights for effective change management pdf 1.pdf
Leading Change strategies and insights for effective change management pdf 1.pdf
 
Connector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonConnector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a button
 
Knowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and backKnowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and back
 
Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*
 
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
Slack (or Teams) Automation for Bonterra Impact Management (fka Social Soluti...
 
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...
 
Assuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyesAssuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyes
 
Generating a custom Ruby SDK for your web service or Rails API using Smithy
Generating a custom Ruby SDK for your web service or Rails API using SmithyGenerating a custom Ruby SDK for your web service or Rails API using Smithy
Generating a custom Ruby SDK for your web service or Rails API using Smithy
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
 

QwalKeko, a History Querying Tool

  • 1. QwalKeko, a History Querying Tool Reinout Stevens resteven@vub.ac.be @ReinoutStevens
  • 3. Was this method pulled up? Who introduced this class? Who has made changes to my classes? History Questions How often is this method Why were these changes changed? introduced? Template-based Reconstruction of Complex Refactorings Kyle Prete, Napol Rachatasumrit, Nikita Sudan, Miryung Kim International Conference on Software Maintenance (ICSM), p.1--10, 2010 Using Information Fragments to Answer the Questions Developers Ask Thomas Fritz and Gail C. Murphy International Conference on Software Engineering (ICSE), p.175--184, 2010 3
  • 4. Was this method pulled up? Who introduced this class? Who has made changes to my classes? History Questions How often is this method Why were these changes changed? introduced? Template-based Reconstruction of Complex Refactorings Kyle Prete, Napol Rachatasumrit, Nikita Sudan, Miryung Kim International Conference on Software Maintenance (ICSM), p.1--10, 2010 Using Information Fragments to Answer the Questions Developers Ask Thomas Fritz and Gail C. Murphy International Conference on Software Engineering (ICSE), p.175--184, 2010 3
  • 5. Pulled up Method 1 pull_up_method(fShortName, tChildFullName, tParentFullName) :- 2 move_method(fShortName, tChildFullName, tParentFullName) ^ 3 before_subtype(tParentFullName, tChildFullName) Template-based Reconstruction of Complex Refactorings Kyle Prete, Napol Rachatasumrit, Nikita Sudan, Miryung Kim International Conference on Software Maintenance (ICSM), p.1--10, 2010 4
  • 6. Pulled up Method 1 pull_up_method(fShortName, tChildFullName, tParentFullName) :- 2 move_method(fShortName, tChildFullName, tParentFullName) ^ 3 before_subtype(tParentFullName, tChildFullName) 1 move_method(mShortName, t1Fullname, t2FullName) :- 2 deleted_method(mFullName, mShortName, t1FullName) ^ 3 added_method(newmName, mShortName, t2FullName) ^ 4 similarbody(newmName, newmBody, mFullName, mBody) Template-based Reconstruction of Complex Refactorings Kyle Prete, Napol Rachatasumrit, Nikita Sudan, Miryung Kim International Conference on Software Maintenance (ICSM), p.1--10, 2010 4
  • 7. Version Control Systems Version Version 3a 4a Version Version 1 Version 2 5 Version Version 3b 4b 5
  • 8. History Query Tool Pr Graph Query og Language ra La m od ry ng Q Move through the sto el ua ue version graph Hi ge ry M Source code of each version Specify characteristics Commit information in a single version Entity tracking ... 6
  • 9. QwalKeko Pr Graph Query og Language ra La m od ry ng Q Qwal sto el ua ue Hi ge ry M Ekeko + 7
  • 10. Applicative LMP ... specify code characteristics through Ekeko relations, leave search to core.logic collection of all substitutions for ?s and ?e (run* [?s ?e] (ast :ReturnStatement ?s) (has :expression ?s ?e) (ast :NullLiteral ?e)) such that the following Ekeko relations hold: ast/2 holds for :ReturnStatement, ?s ?e is the value of the property has/3 holds for :expression, ?s, and ?e named :expression of ([?s1 ?e2] ... [?sn ?en]) ast/2 holds for :NullLiteral, ?e ASTNode ?s ([#<ReturnStatement return null; #<NullLiteral null>] ... actual search performed by [#<ReturnStatement return null; core.logic #<NullLiteral null>]) 8
  • 11. Qwal foo bar baz 1 (run* [?end] 2 (qwal graph :foo ?end 3 [] 4 (qcurrent [curr] (has-info curr :foo)) 9
  • 12. Qwal foo bar baz 1 (run* [?end] 2 (qwal graph :foo ?end 3 [] 4 (qcurrent [curr] (has-info curr :foo)) 5 q=> 6 (qcurrent [curr] (has-info curr :bar)) 9
  • 13. Qwal foo bar baz 1 (run* [?end] 2 (qwal graph :foo ?end 3 [] 4 (qcurrent [curr] (has-info curr :foo)) 5 q=> 6 (qcurrent [curr] (has-info curr :bar)) 7 q=> 8 (qcurrent [curr] (has-info curr :baz))) 9
  • 14. Introduced Subclasses 1 (qwal graph start ?end [?parent ?child] 2 (qin-current 3 (ast :TypeDeclaration ?parent)) 4 (q=>+) ;;skip >= 1 versions 5 (qin-current 6 (subclass ?parent ?child) 7 (introduced ?child))) 10
  • 15. Same Predicate (defn same [?entity ?other-entity] ...) Ground in a previous version Ground in current version 11
  • 16. Same Predicate (defn same [?entity ?other-entity] ...) 1 (defn introduced [?entity] 2 (fresh [?same] 3 q<= 4 (not (same ?entity ?same))) 12
  • 17. Recall... 1 pull_up_method(fShortName, tChildFullName, tParentFullName) :- 2 move_method(fShortName, tChildFullName, tParentFullName) ^ 3 before_subtype(tParentFullName, tChildFullName) 1 move_method(mShortName, t1Fullname, t2FullName) :- 2 deleted_method(mFullName, mShortName, t1FullName) ^ 3 added_method(newmName, mShortName, t2FullName) ^ 4 similarbody(newmName, newmBody, mFullName, mBody) 13
  • 18. Pulled up Method 1 (defn pulled-up [?method ?pulled] 2 (fresh [?m-class ?p-class] 3 (method-moved ?method ?pulled) 4 (declaring-class ?method ?m-class) 5 (declaring-class ?pulled ?p-class) 6 (superclass ?m-class ?p-class))) 1 (defn method-moved [?moved ?to] 2 (removed ?moved) ;;implemented using same 3 (ast :MethodDeclaration ?to) 4 (== ?moved ?to) ;;unify when same signature 5 (has-similar-body ?moved ?to))) 14
  • 19. Pulled up Method 1 (qwal graph root ?end [?method ?pulled] 2 (qin-current 3 (ast :MethodDeclaration ?method)) 4 q=> ;;go to next version 5 (qin-current 6 (pulled-up ?method ?pulled))) 15
  • 20. Generalized Rule 1 (qwal graph root ?end [?method ?pulled] 2 (qin-current 3 (ast :MethodDeclaration ?method)) 4 (q=>+) ;;skip >=1 versions 5 (qin-current 6 (pulled-up ?method ?pulled))) 16
  • 21. Questions Reinout Stevens resteven@vub.ac.be @ReinoutStevens http://github.com/ReinoutStevens/damp.qwal http://github.com/cderoove/damp.ekeko 17

Editor's Notes

  1. \n
  2. software repositories are a large source of information regarding the history / evolution of a software project\nprogrammers have questions\n
  3. \n
  4. \n
  5. \n
  6. Explain their method -&gt; 2 eclipse projects, create factbase, use prologlike language\nGoal: reimplement these kind of rules, generalize them\nNeed source of information\n
  7. branching\nmerging\nno loops\n
  8. \n
  9. \n
  10. \n
  11. find all returnstatements that return null\n
  12. \n
  13. \n
  14. \n
  15. \n
  16. \n
  17. \n
  18. \n
  19. \n
  20. \n
  21. \n
  22. introduced -&gt; how do you do this?\n
  23. \n
  24. \n
  25. \n
  26. no temporal part yet...\nneeded in qwalkeko\n
  27. \n
  28. \n
  29. \n