48
Rule-based generation of requirements traceability relations

Rule-based generation of requirements traceability relations

Embed Size (px)

DESCRIPTION

Rule-based generation of requirements traceability relations. Trace Rules. Requirement-to-object model -> (REQ or UCD) Object Model Inter-requirement rules -> REQ UCD. Traceability Types. Satisfiability Dependency Evolution Rationalisation. RTOM rules. - PowerPoint PPT Presentation

Citation preview

Rule-based generation of requirements traceability

relations

Trace Rules

• Requirement-to-object model -> (REQ or UCD) <-> Object Model

• Inter-requirement rules -> REQ <-> UCD

Traceability Types

• Satisfiability

• Dependency

• Evolution

• Rationalisation.

RTOM rules

• 利用 RSD 上句法 (syntactically) 的上的分析跟 Object Model 上特定 fields 的關係,如 class, attribute, operations 產生關係。

IREQ Rules

• Between Requirements

• Between USD events.

• Between Requirement and USD

• 特點是要有 trace to AOM 才會產生 IREQ trace.

Use case consist of

• A unique identifier

• A title

• Characteristic information (description, pre-conditions and post-conditions)

• A flow of normal events

• Exceptional events.

Four stages to proceed

• Grammatical tagging

• XML conversion

• Generate RTOM relations

• Generate IREQ relations

Four types of relations

• Overlap

• Requires_Executions_Of

• Requires_Feature_In

• Can_Partially_Realise

Overlap Relation

• An overlap relation 重疊 denotes that the connected elements refer to a common feature of the underlying system or its domain.

• 一個 common 的功能• 例 : Treble levels

Overlap relation 產生在• A sequence of terms in ( requirement state,

part of a use case, class attribute, class association, class association end)

• A sequence of terms in a requirement statement and part of use case.

Requires_Execution_of

• “Sequence of terms” or a part of use case 與 Operation in AOM.

Requires_Feature_In

• Between UCD and Requirement

• Between 2 Requirements

Can_Partially_Realise

• Between (description, event and post-condition in UCD) and Requirements

CLAWS tags set samples

VVZ The -s form of lexical verbs (e.g. forgets, sends, lives, returns)

NN0 Common noun, neutral for number (e.g. aircraft, data, committee)

NN1 Singular common noun (e.g. pencil, goose, time, revelation)

NN2 Plural common noun (e.g. pencils, geese, times, revelations)

Rules Form

Sample of Prediction

• Where P is defined as

• ATTRIBUTE_OF(Id1, Id2)

• Id1 is an attribute, and Id2 is a class.

• Id1 is an attribute of Id2 or inherited by Id2

Sample of Functions

• Name(Id1):String

• Take UML model element identifier and return the name of the model element.

Function Listing

• Name(Id1): String

• Concat (String1, String2 ): String3

• Synonym(String1) : Set of < String>

• Singular_Form(String1) : String2

• Stereotype(Id1) : Set of <String>

Rule 1

• Establish a overlap relation.• NN1 – singular common noun• JJ - general adjective• NP1 - singular proper noun (e.g. London, Jane,

Frederick) • NN2 - plural locative noun (e.g. Islands, Streets)

Rule 1 define

• The qualified noun (x1, x2, x3) 強調這 feature 可能被 model 成一個 attribute.

• X1 強調這組名詞的 owner, 所以可能被model 成 class.

• X2 是附加的特徵,強調 owner 或 feature ,所以有可能加在 class name 或是 attribute 內。

Rule 1 Example

Rule 2

• VVI – infinitive 原形動詞 • AT - article (e.g. the, no) 冠詞• CC - coordinating conjunction (e.g. and, or)

Rule 2

• Match 一個主動作 <x1/{VVI}:1> 跟一個物件,這個動作要出現在 OM 的 Class Operation 中。

Rule 2 matched by..

• 動詞在 operation 內。 (MEMBER_OF(<x1>, SNYNONYMS(STEREOTYPE(<X9>)))

• 第一名詞 <x3> 存在於 class name 之中 .

• 單數名詞存在於 operation 中

Rule 2 Example

Rule 3

• <x1> and <x5> 同時存在於 Class Name之中

Rule 3 Example

Rule 4

• VBZ - is

Rule 4 can

• Create rule between precondition of a use case and an operation in an OM.

• <x3> is the name, <x1> is qualifier– CONTAINS(NAME(<x6>, <x3>)– CONTAINS(NAME(<x5>, <x1>)– EQUAL_TO(STEREOTYPE(<x6>, “get”))

Rule 4 Example

Rule 4 based on

• 在 pre-condition 內,一個名詞 is (to be) ….. 表示一種條件,這種條件強調這個名詞 ( 功能 ) 的值。

• 因此在 OM 內,基於封裝的基礎,應該有 <<get>> 這種 operation 得到這名詞的值。

Rule 5

• VVN - past participle of lexical verb (e.g. given, worked)

Rule 5 can

• Match an expression in post-condition and and an operation in OM.

• <x3> 通常被 <x5> 所描述

Rule 5 matched if

• The name operation contain the noun or the qualifier. CONTAINS(NAME(<x6>, <x3>)) and CONTAINS(NAME(<x6>, <x1>))

• 動詞跟 operation 的 stereo type 的同義詞符合 - MEMBER_OF(<x5>, SYNONYMS(STEREOTYPE(<x6>)))

Rule 5 Example

IREQ Rules

• Generate overlap, requires_feature_in or can_partially_realise relations.

• IREQ rules based on 之前產生的 relation 才再產生 relation

IREQ Form

Rule 6

• RSD id 72 has require_execution_of…

• UCD AF2 also has require_execution_of…

• So generate a USD Can_Partially_Realise relation with RSD.

Rule 7

• Generate require_feature_in relation between requirements.

Rule 7 matched if

• One of the requirement linked with <x2> , which is a association end of a class <x1> by an overlap relation.

• Other requirement is linked with operation <x3> defined in class <x1> by require_execution_of relation.

• The name of operation includes the name of the association end.

Rule 7 based on

• 如果一個 operation 對其中一個 association end name 有動作。

• 這個 requirement require_execution_of 也須要另一個 association end 的存在。

Rule 7 Example

Rule 8

Rule 8 Example