Recommendation System for Design Patterns in Software Development

  • Slides: 25
Download presentation
Recommendation System for Design Patterns in Software Development: An DPR Overview Proceedings of the

Recommendation System for Design Patterns in Software Development: An DPR Overview Proceedings of the Third International Workshop on Recommendation Systems for Software Engineering. 2012. Francis Palma, Hadi Farzin, E´cole Polytechnique de Montre´al Montr´eal, Canada made by Zhang, Cheng Naouel Moha Universit´e du Qu´ebec `a Montr´eal, Canada

Outline l Introduction l The Methodology l Prototype l Evaluation l Conclusion and Future

Outline l Introduction l The Methodology l Prototype l Evaluation l Conclusion and Future Work made by Zhang, Cheng

Outline l Introduction l The Methodology l Prototype l Evaluation l Conclusion and Future

Outline l Introduction l The Methodology l Prototype l Evaluation l Conclusion and Future Work made by Zhang, Cheng

Introduction • Each pattern describes a problem that occurs over and over again in

Introduction • Each pattern describes a problem that occurs over and over again in software development domain and then describes the core of the solution to that problem, in such a way that we can use this solution many times, without doing it the same way twice • Increasing number of available design patterns should lead to better quality, by proposing good solutions to recurring design problems. • However, it is difficult to follow all new patterns during development and to choose the right patterns when faced with a design problem made by Zhang, Cheng

Introduction • Firstly, recommend a design pattern for a specific problem context (primary-level) •

Introduction • Firstly, recommend a design pattern for a specific problem context (primary-level) • Secondly, recommend one (or more) design pattern(s) suitable for a system with initial models already created by the designer (secondary level). made by Zhang, Cheng

Outline l Introduction l The Methodology l Prototype l Evaluation l Conclusion and Future

Outline l Introduction l The Methodology l Prototype l Evaluation l Conclusion and Future Work made by Zhang, Cheng

Methodology • Methodology for Design Pattern Recommender(DPR) is a selection type of expert system

Methodology • Methodology for Design Pattern Recommender(DPR) is a selection type of expert system and hence a ranking based selection approach for DPR is chosen • DPR is aimed to help designers to find or decide which pattern to use for a particular design problem made by Zhang, Cheng

Methodology • Steps: A. Identify the circumstances in which patterns can be applied B.

Methodology • Steps: A. Identify the circumstances in which patterns can be applied B. Refine the circumstances with sub-conditions C. Formulate questions to ask designers D. Formulate GQM Model with the defined questions made by Zhang, Cheng

A. Identify the circumstances in which patterns can be applied • Prior to constructing

A. Identify the circumstances in which patterns can be applied • Prior to constructing our knowledge base for DPR, we perform knowledge acquisition. • During this phase, the literature on object-oriented software design patterns are reviewed analyzed. made by Zhang, Cheng

B. Refine the circumstances with sub-conditions • In this phase refine each condition into

B. Refine the circumstances with sub-conditions • In this phase refine each condition into possible subconditions, i. e. , from the intents as conditions to the applicabilities as sub-conditions for each pattern. • In this figure, we can see that adapter pattern had two conditions C 1 and C 2 and then again it has three subconditions SC 1, • SC 2 and SC 3. made by Zhang, Cheng

C. Formulate questions to ask designers • Tree representation of knowledge about patterns obtained

C. Formulate questions to ask designers • Tree representation of knowledge about patterns obtained during Step A and B, are the means to derive questions to ask designers. • For example, for Adapter pattern, the first subcondition becomes ‘Do you want to create a reusable class? ’ and the second subcondition ‘Do you need to use several existing subclasses? ’. The result of this step is a set of questions formulated for each tree generated from Step B. made by Zhang, Cheng

D. Formulate GQM Model with the defined questions • We build a Goal-Question-Metric (GQM)

D. Formulate GQM Model with the defined questions • We build a Goal-Question-Metric (GQM) model for the interactivity. • At top, we place the pattern names as the goals. • In the question levels, we place 2 -layered questions, where first layer represents conditions, followed by the subconditions. • These bottom level questions will be asked directly to designers. Each of which will be responded with ‘yes’, ‘no’ or ‘do not know’, with a weight, assigned by the users. • All the weights are positive integers between 1 and 9 (except 0 for ‘do not know’). made by Zhang, Cheng

A set of candidate design patterns made by Zhang, Cheng

A set of candidate design patterns made by Zhang, Cheng

Outline l Introduction l The Methodology l Prototype l Evaluation l Conclusion and Future

Outline l Introduction l The Methodology l Prototype l Evaluation l Conclusion and Future Work made by Zhang, Cheng

Prototype A. The DPR Knowledge Base(KB) • We have a central KB that plays

Prototype A. The DPR Knowledge Base(KB) • We have a central KB that plays an important role during the interactive session with the designer. made by Zhang, Cheng

Prototype B. DPR Process Model made by Zhang, Cheng

Prototype B. DPR Process Model made by Zhang, Cheng

Outline l Introduction l The Methodology l Prototype l Evaluation l Conclusion and Future

Outline l Introduction l The Methodology l Prototype l Evaluation l Conclusion and Future Work made by Zhang, Cheng

Evaluation Process model: Secondary recommendation made by Zhang, Cheng

Evaluation Process model: Secondary recommendation made by Zhang, Cheng

Evaluation A designer-DPR interactive session: RESPONSE(R), WEIGHT(W), ADAPTER(A), VISITOR(V) & DECORATOR(D) made by Zhang,

Evaluation A designer-DPR interactive session: RESPONSE(R), WEIGHT(W), ADAPTER(A), VISITOR(V) & DECORATOR(D) made by Zhang, Cheng

Evaluation Summary of the subjective evaluation for DPR made by Zhang, Cheng

Evaluation Summary of the subjective evaluation for DPR made by Zhang, Cheng

Evaluation Comparison: DPR, ESSDP, Re. Builder and RS made by Zhang, Cheng

Evaluation Comparison: DPR, ESSDP, Re. Builder and RS made by Zhang, Cheng

Outline l Introduction l The Methodology l Prototype l Evaluation l Conclusion and Future

Outline l Introduction l The Methodology l Prototype l Evaluation l Conclusion and Future Work made by Zhang, Cheng

Conclusion and future work • As our current and future work, we are trying

Conclusion and future work • As our current and future work, we are trying to come up with a tool that can suggest design patterns providing the interactivity for designers. • More specifically, for secondary level recommendation, deployment of DPR for re-organizing model components into groups, for individual selected pattern can be a prominent solution. made by Zhang, Cheng

Q&A

Q&A