a generic module system for web rule languages: divide and rule

13
A Generic Module System for Web Rule Languages: Divide and Rule Uwe Aßmann, Sacha Berger, François Bry, Tim Furche, Jakob Henriksson, Paula-Lavinia Pătrânjan RuleML 2007 October 2007

Upload: others

Post on 12-Sep-2021

2 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: A Generic Module System for Web Rule Languages: Divide and Rule

A Generic Module System for Web Rule Languages: Divide and Rule

Uwe Aßmann, Sacha Berger, François Bry,

Tim Furche, Jakob Henriksson,

Paula-Lavinia Pătrânjan

RuleML 2007 October 2007

Page 2: A Generic Module System for Web Rule Languages: Divide and Rule

October 2007RuleML 2007

Modules

Software units thatGroup together parts of programs and knowledgeUsually serve a specific purpose

An essential feature for programming languagesMake large scale projects tractable by humansFacilitate the integration of existing applicationsOffer a flexible solution to application development

Page 3: A Generic Module System for Web Rule Languages: Divide and Rule

October 2007RuleML 2007

… and Rule Languages

The rule-based programming paradigmHigh-level means for developing applications of various domainsFlexible and adaptive approach towards application development

Rule languagesHave been developed within different communities

Database systems, business rules, (Semantic) Web

There is still room for further exploiting their potentialReuse and integrate knowledgeSpecified in different rule languages

Page 4: A Generic Module System for Web Rule Languages: Divide and Rule

October 2007RuleML 2007

Modules for Web Rule Languages

Besides the (general) advantages of modules in programminglanguages:

Scoped inferenceInfer new knowledge within an explicitly given scope

Data integrationIssue also for the W3C RIF WG

… most of (Web) rule languages still lack a module system!

Page 5: A Generic Module System for Web Rule Languages: Divide and Rule

October 2007RuleML 2007

Modules for Web Rule LanguagesOur Proposal

A conceptual framework for modules in rule languages

Provides abstract language constructsAbstracts away from a particular data modelPreserves the languages’ semantics

Main ideaRewriting modular programs into semantically equivalent non-modular programsBased on so-called reduction semantics

Focus on genericityApplicable to many Web rule languages

Page 6: A Generic Module System for Web Rule Languages: Divide and Rule

October 2007RuleML 2007

Modules for Web Rule LanguagesFramework

Languages based on deductive rulesOf the form head <- bodyWhere head and body are finite sequences of atomic formulas

Requirement for rule languagesRule chaining (or rule dependency)Dependency relations between body and head parts of a program (or module)

Example rule languages SWRL, RIF BLD, Datalog, Triple, Prolog but not CSS

Page 7: A Generic Module System for Web Rule Languages: Divide and Rule

October 2007RuleML 2007

Module System Algebra Module DefinitionA module M is a triple (RPRIV, RPUB, △)

RPRIV, RPUB are the private and public, respectively, rules of M△ is the dependency relation between body parts and

heads of rules

Page 8: A Generic Module System for Web Rule Languages: Divide and Rule

October 2007RuleML 2007

Module System AlgebraModule Composition Operators

Import, denoted M1 M2 Public rules of M2 are visible in M1… and in all other modules importing M1

Qualified importImport public, denoted M1 M2Import private, denoted M1 ⋈ M2

M2 not visible in modules importing M1

Scoped import, denoted M1 S M2 M2’s rules become visible only to specifically marked body parts of M1Extends the dependency relation of M1Pairs of body parts from M1 and heads of rules from M2

Page 9: A Generic Module System for Web Rule Languages: Divide and Rule

October 2007RuleML 2007

Module System AlgebraPublic and Private Import

Page 10: A Generic Module System for Web Rule Languages: Divide and Rule

October 2007RuleML 2007

Module System AlgebraModule Composition

Page 11: A Generic Module System for Web Rule Languages: Divide and Rule

October 2007RuleML 2007

Module System AlgebraModule Composition

A single fundamental module composition operatorScoped import as base of our module algebraPublic and private import

Can be reduced to scoped import in presence of views Details in the paper

By composing modules a new set of rules is formedA new dependency relation is attached to this setAn operation is needed

For adjusting a given dependency relationThe slide operation sufficesFormal definitions in the paper!

Page 12: A Generic Module System for Web Rule Languages: Divide and Rule

October 2007RuleML 2007

Concluding Remarks

We do notPropose a concrete module system for a given rule language!

Instead, our workAbstracts from similar module systems realizable for different rule languagesProposes a framework for a generic module systemThat can be implemented e.g.By means of a composition framework such as Reuseware

http://www.reuseware.org/As done e.g. for the Web rule language Xcerpt

Page 13: A Generic Module System for Web Rule Languages: Divide and Rule

October 2007RuleML 2007

Thank you for your attention!

For more information on our research work:

http://rewerse.net/