existential rules
play

Existential Rules Combined approach for EL Micha el Thomazo - PowerPoint PPT Presentation

Existential Rules Existential Rules Combined approach for EL Micha el Thomazo November 22nd, 2013 Dresden 1 / 30 Existential Rules Flow of the course What has been seen until now: forward chaining approach backward chaining


  1. Existential Rules Existential Rules Combined approach for EL Micha¨ el Thomazo November 22nd, 2013 Dresden 1 / 30

  2. Existential Rules Flow of the course What has been seen until now: ◮ forward chaining approach ◮ backward chaining approach Today’s topic: a case where none of the already presented approaches are applicable. 2 / 30

  3. Existential Rules Reference for today’s course Conjunctive Query Answering in the Description Logic EL Using a Relational Database System , Lutz, Toman, Wolter, IJCAI 09 3 / 30

  4. Existential Rules ELH dr N C and N R disjoint sets of (atomic) concept and role names. EL concept An EL concept is built as follows: ◮ an atomic concept C ∈ N C ◮ top concept ⊤ ◮ the intersection of two concepts C 1 ⊓ C 2 ◮ ∃ r . C , where r is a role name and C an EL concept An ELH dr TBox is a set of concept inclusions C 1 ⊑ C 2 and of role inclusions r 1 ⊑ r 2 , as well as a set of domain and range restrictions ( dom( r ) ⊑ C and ran( r ) ⊑ C ′ ). 4 / 30

  5. Existential Rules EL and existential rules Any EL ontology can be expressed thanks to a set of existential rules. → consider the standard translation into first-order logic 5 / 30

  6. Existential Rules EL and rule applications Let us consider the following EL concept inclusion: C ⊑ ∃ r . C , and the following ABox: C ( a ) . 6 / 30

  7. Existential Rules EL and query rewriting Let us consider the following EL concept inclusion: ∃ r . C ⊑ C and the following query: ∃ xC ( x ) ∧ D ( x ) . 7 / 30

  8. Existential Rules The combined approach (1) In the combined approach, both the query and the data are modified. We look for F ′ and q ′ such that: = q ⇔ F ′ | = q ′ . F , R | 8 / 30

  9. Existential Rules The combined approach (2) It has been applied for ◮ ELH dr ⊥ (today’s course) ◮ DL-Lite ◮ generalizations of guarded rules Advantages: ◮ allow to deal with more expressive ontologies ◮ avoid some blow up inherent to query rewriting approaches Main limitation: ◮ the data is modified 9 / 30

  10. Existential Rules Some technical assumptions 1. queries contain only individual names that occur in the KB 2. TBoxes do not contain domain restrictions 3. TBoxes contain exactly one range restriction per role name 4. if K | = r ⊑ s and ran( r ) ⊑ C , ran( s ) ⊑ D are in T , then C ⊑ T D 5. there are no r , s ∈ N R with r � = s such that K | = r ⊑ s and K | = s ⊑ r All these assumptions can be made without loss of generality. 10 / 30

  11. Existential Rules Some notations sub( T ): subconcepts appearing in T ◮ rol( R ): roles appearing in T ◮ Ind( A ): individuals appearing in A ◮ ran T ( r ): unique concept C such that ran( r ) ∈ T ◮ ran( T ) = { ran T ( r ) | r ∈ rol( T ) } ◮ NI aux = { x C , D | C ∈ ran( T ) and D ∈ sub( T ) } ◮ 11 / 30

  12. Existential Rules Enriching the data 12 / 30

  13. Existential Rules First step: canonical model for instance queries ◮ ∆ I K := Ind( A ) ∪ NI aux ◮ a I K := a for all a ∈ Ind( A ) ◮ A I K := { a ∈ Ind( A ) | K | = A ( a ) } ∪ { x C , D ∈ NI aux | C ⊓ D ⊑ A } ◮ r I K = r I K ∪ r I K ∪ r I K 1 2 3 ◮ r I K := { ( a , b ) ∈ Ind( A ) × Ind( A ) | s ( a , b ) ∈ A and K | = s ⊑ r } 1 ◮ r I K := { ( a , x C , D ) ∈ Ind( A ) × NI aux | K | = ∃ s . D ( a ) , ran( s ) = C , K | = 2 s ⊑ r } ◮ r I K = C ⊓ D ⊑ ∃ r . D ′ , ran( s ) = := { ( x C , D , x C ′ , D ′ ) ∈ NI aux × NI aux | K | 3 C ′ , K | = s ⊑ r } 13 / 30

  14. Existential Rules First problem Consider K 1 = ( T 1 , A 1 ) with T 1 = { A ⊑ A } , and A 1 = { B ( a ) } . Let q 1 = ∃ u ( B ( v ) ∧ A ( u )). x ⊤ , A ∈ A I K 1 and I K 1 | = q 1 [ a ] but a is not a certain answer. Solved by considering only the “connected” part → I k R . 14 / 30

  15. Existential Rules Second problem Consider K 2 = ( T 2 , A 2 ) with T 2 = { A ⊑ ∃ r . B ⊓ ∃ s . B } and A 2 = { A ( a ) } . Let consider q 2 = ∃ u ( r ( v , u ) ∧ s ( v , u ). I K 2 | = q 2 [ a ], but a is not a certain answer. Question: why does I K 2 | = q 2 [ a ] hold? 15 / 30

  16. Existential Rules Solving them by unraveling (1) We define Ind( A ) I = { a I | a ∈ Ind( A ) } . A path in I is a finite sequence d 0 r 1 d 1 . . . r n d n such that: ◮ d 0 ∈ Ind( A ) I ; ◮ ( d i , d i +1 ) ∈ r I i +1 for all i < n . Denoted by paths A ( I ). 16 / 30

  17. Existential Rules Solving them by unraveling (2) Let R be the set of role inclusion in K . The ( A , R )-unraveling J of I is defined as follows: ◮ ∆ J = paths A ( I ) ◮ a J = a I for all a ∈ Ind( A ) ◮ A J = { p | tail( p ) ∈ A I } ◮ r J = r J 1 ∪ r J 2 ◮ r J 1 = { ( d , e ) | d , e ∈ Ind( A ) ∧ ( d , e ) ∈ r I } 2 = { ( p , p · se ) | p , p · se ∈ ∆ J and R | ◮ r J = s ⊑ r } The unraveling of I r K is denoted by U K . 17 / 30

  18. Existential Rules Motivation for the second step We want to represent the canonical model thanks to a relational database. We thus need a finite canonical model. The unraveling is infinite in general. We rewrite the query in order to regain soundness. 18 / 30

  19. Existential Rules Rewriting the query 19 / 30

  20. Existential Rules Recognizing errors The aim is to exclude some of the answer provided with the canonical model for instance queries. We make use of the following equivalence relation: The equivalence relation ∼ q ∼ q is the smallest relation on terms( q ) that include identity, is transitive and satisfies the following closure relation: If r 1 ( s , t ) , r 2 ( s ′ , t ′ ) ∈ q and t ∼ q t ′ , then s ∼ q s ′ 20 / 30

  21. Existential Rules pre and in For an equivalence class ζ of ∼ q , we define the following two sets: pre( ζ ) = { t | r ( t , t ′ ) ∈ q for some r ∈ N R and t ′ ∈ ζ } ◮ in( ζ ) = { r | r ( t , t ′ ) ∈ a for some t ∈ term( q ) and t ′ ∈ ζ } ◮ 21 / 30

  22. Existential Rules Implicant and prime implicant For R ⊆ N R and r ∈ N R , r is an implicant of N R if for any s ∈ R , R | = r ⊑ s . It is called a prime implicant if for all implicant r ′ of R such that r ′ � = r , R �| = r ⊑ r ′ , 22 / 30

  23. Existential Rules Some relevant situations We define: Fork = us the set if pairs ( pre( ζ ) , ζ ), where pre( ζ ) is of ◮ cardinality at least two; 23 / 30

  24. Existential Rules Some relevant situations We define: Fork = us the set if pairs ( pre( ζ ) , ζ ), where pre( ζ ) is of ◮ cardinality at least two; Fork � = is the set of variables v ∈ qvar( q ) such that there is ◮ no implicant of in([ v ]); 24 / 30

  25. Existential Rules Some relevant situations We define: Fork = us the set if pairs ( pre( ζ ) , ζ ), where pre( ζ ) is of ◮ cardinality at least two; Fork � = is the set of variables v ∈ qvar( q ) such that there is ◮ no implicant of in([ v ]); Fork H is the set of pairs ( I , ζ ) such that pre( ζ ) � = ∅ , there is ◮ a prime implicant of in( ζ ) that is not contained in in( ζ ) and I is the set of all prime implicants of in( ζ ) 25 / 30

  26. Existential Rules Some relevant situations We define: Fork = us the set if pairs ( pre( ζ ) , ζ ), where pre( ζ ) is of ◮ cardinality at least two; Fork � = is the set of variables v ∈ qvar( q ) such that there is ◮ no implicant of in([ v ]); Fork H is the set of pairs ( I , ζ ) such that pre( ζ ) � = ∅ , there is ◮ a prime implicant of in( ζ ) that is not contained in in( ζ ) and I is the set of all prime implicants of in( ζ ) Cyc is the set of variables v ∈ qvar( q ) such that there are ◮ r 0 ( t 0 , t ′ 0 ) , . . . , r m ( t m , t ′ m ) , . . . , r n ( t n , t ′ n ) ∈ q , n , m ≥ 0 with v ∼ q t i for some i ≤ n , T ′ i ∼ q t i +1 for all i < n and t ′ n ∼ q t m . 26 / 30

  27. Existential Rules The rewriting We rewrite q = ∃ u ( ψ ) into ∃ u ( ψ ∧ ϕ 1 ∧ ϕ 2 ∧ ϕ 3 ), where: ◮ ϕ 1 = � v ∈ avar ( q ) ∪ Fork � = ∪ Cyc ¬ Aux( v ) ◮ ϕ 2 = � ( { t 1 ,..., t k } ,ζ ) ∈ Fork = ( Aux( t ζ ) → � 1 ≤ i < k t i = t i +1 ) r ∈ I r ( t pre ◮ ϕ 3 = � ( I ,ζ ) ∈ Fork H ( Aux( t ζ ) → � , t ζ )) ζ pre where t ζ is a representative of ζ and t is an arbitrary element of ζ pre( t ζ ) 27 / 30

  28. Existential Rules Formalization of the goal We prove the following equivalence: = q ∗ I r K | R [ a 1 , . . . , a k ] ⇔ U K | = a [ a 1 , . . . , a k ] 28 / 30

  29. Existential Rules Two properties of models Let A be an ABox. Let I be a model where Aux I = ∆ I \ Ind( A ) I . ◮ I is A -connected if every d ∈ ∆ I equals tail( p ) for some p ∈ paths A ( I ) ◮ I is split if d ∈ Aux I and ( d , d ′ ) ∈ r I imply d ′ ∈ Aux I , for all r ∈ N R and d , d ′ ∈ ∆ I 29 / 30

  30. Existential Rules The theorem Let I be split and A -connected and let I ′ be the ( A , R )-unraveling of I . Let q be a k -ary conjunctive query. Then the following holds for all a 1 , . . . , a k ∈ Ind( A ): R [ a 1 , . . . , a k ] ⇔ I ′ | = q ∗ I | = q [ a 1 , . . . , a k ] 30 / 30

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend