Stream Reasoning with LARS Harald Beck Minh Dao-Tran Thomas Eiter The 2nd Stream Reasoning Workshop December 8-9, 2016
Outline LARS Overview (Revised) LARS Syntax and Semantics Recent and Ongoing LARS Research @ KBS LARS’ Collaboration
LARS Overview LARS is a logical framework with a rule-based language that offers ◮ generic window operators, ◮ different ways to refer to time, and ◮ an ASP-like semantics for (analyzing) stream reasoning.
LARS Setting: Streams ) ) ) 5 5 A 2 2 7 r r t t b 2 0 , 1 , , 1 ( ( ( d d d e e e r r r a a a e e e p p p p p p a a a • • • 11 12 13 14 15 16 17 18 19 20 21 22 23 Data Streams D = ( T , υ ) T = [0 , 50] 12 �→ { appeared (0 , tr 25 ) } , υ = 17 �→ { appeared (1 , tr 25 ) } , 19 �→ { appeared (1 , b 27 A ) }
LARS Setting: Streams ) ) ) 5 5 A 2 2 7 ) ) r r t t b 2 5 A 2 7 0 , 1 , , r 1 t b 2 ( ( ( d d d 2 , , 2 e e e ( ( r r r p p a a a x e e e x p p e e p p p p a a a • • • • • 11 12 13 14 15 16 17 18 19 20 21 22 23 Interpretation Stream S ⋆ = ( T ⋆ , υ ⋆ ) ⊇ D T ⋆ = [0 , 50] 12 �→ { appeared (0 , tr 25 ) } , 21 �→ { exp (2 , tr 25 ) } , υ ⋆ = 17 �→ { appeared (1 , tr 25 ) } , 23 �→ { exp (2 , b 27 A ) } , 19 �→ { appeared (1 , b 27 A ) }
LARS Window Functions and Operators ) ) ) 5 5 A 2 2 7 r r b 2 t t 0 , 1 , 1 , ( ( ( d d d e e e r r r a a a e e e p p p p p p a a a • • • 11 12 13 14 15 16 17 18 19 20 21 22 23 Window functions S ′ = ( T ′ , υ ′ ) = w ( S , t ) T ′ = [15 , 20] υ ′ = { 17 �→ { appeared (1 , tr 25 ) } , 19 �→ { appeared (1 , b 27 A ) }} Window operators ⊞ w
(Revised) LARS Syntax α ::=
(Revised) LARS Syntax α ::= a | ¬ α | α ∧ α | α ∨ α | α → α ◮ standard logical operators
(Revised) LARS Syntax α ::= a | ¬ α | α ∧ α | α ∨ α | α → α | ♦ α | � α | @ t α ◮ standard logical operators ◮ various ways for time references
(Revised) LARS Syntax α ::= a | ¬ α | α ∧ α | α ∨ α | α → α | ♦ α | � α | @ t α | ⊞ w α ◮ standard logical operators ◮ various ways for time references ◮ window operators which can be nested ⊞ 60 � ⊞ 10 ♦ appeared ( s , b 1 )
(Revised) LARS Syntax α ::= a | ¬ α | α ∧ α | α ∨ α | α → α | ♦ α | � α | @ t α | ⊞ w α | ⊲α ◮ standard logical operators ◮ various ways for time references ◮ window operators which can be nested ⊞ 60 � ⊞ 10 ♦ appeared ( s , b 1 ) ◮ Reset operator
(Revised) LARS Syntax α ::= a | ¬ α | α ∧ α | α ∨ α | α → α | ♦ α | � α | @ t α | ⊞ w α | ⊲α ◮ standard logical operators ◮ various ways for time references ◮ window operators which can be nested ⊞ 60 � ⊞ 10 ♦ appeared ( s , b 1 ) ◮ Reset operator ◮ Rules @ T + L exp ( M , V ) ← ⊞ 5 @ T appeared ( N , V ) , plan ( N , M , V , L ) .
(Revised) LARS Entailment Structure M = � S ⋆ , W , B �
(Revised) LARS Entailment Structure M = � S ⋆ , W , B � Substream S = ( T , υ ) of S ⋆ : currently considered window Time point t ∈ T
(Revised) LARS Entailment Structure M = � S ⋆ , W , B � Substream S = ( T , υ ) of S ⋆ : currently considered window Time point t ∈ T M , S , t � a iff a ∈ υ ( t ) or a ∈ B ,
(Revised) LARS Entailment Structure M = � S ⋆ , W , B � Substream S = ( T , υ ) of S ⋆ : currently considered window Time point t ∈ T M , S , t � a iff a ∈ υ ( t ) or a ∈ B , M , S , t � ¬ α iff M , S , t � α, M , S , t � α ∧ β iff M , S , t � α and M , S , t � β, M , S , t � α ∨ β iff M , S , t � α or M , S , t � β, M , S , t � α → β iff M , S , t � α or M , S , t � β,
(Revised) LARS Entailment Structure M = � S ⋆ , W , B � Substream S = ( T , υ ) of S ⋆ : currently considered window Time point t ∈ T M , S , t � a iff a ∈ υ ( t ) or a ∈ B , M , S , t � ¬ α iff M , S , t � α, M , S , t � α ∧ β iff M , S , t � α and M , S , t � β, M , S , t � α ∨ β iff M , S , t � α or M , S , t � β, M , S , t � α → β iff M , S , t � α or M , S , t � β, M , S , t ′ � α for some t ′ ∈ T , M , S , t � ♦ α iff
(Revised) LARS Entailment Structure M = � S ⋆ , W , B � Substream S = ( T , υ ) of S ⋆ : currently considered window Time point t ∈ T M , S , t � a iff a ∈ υ ( t ) or a ∈ B , M , S , t � ¬ α iff M , S , t � α, M , S , t � α ∧ β iff M , S , t � α and M , S , t � β, M , S , t � α ∨ β iff M , S , t � α or M , S , t � β, M , S , t � α → β iff M , S , t � α or M , S , t � β, M , S , t ′ � α for some t ′ ∈ T , M , S , t � ♦ α iff M , S , t ′ � α for all t ′ ∈ T , M , S , t � � α iff
(Revised) LARS Entailment Structure M = � S ⋆ , W , B � Substream S = ( T , υ ) of S ⋆ : currently considered window Time point t ∈ T M , S , t � a iff a ∈ υ ( t ) or a ∈ B , M , S , t � ¬ α iff M , S , t � α, M , S , t � α ∧ β iff M , S , t � α and M , S , t � β, M , S , t � α ∨ β iff M , S , t � α or M , S , t � β, M , S , t � α → β iff M , S , t � α or M , S , t � β, M , S , t ′ � α for some t ′ ∈ T , M , S , t � ♦ α iff M , S , t ′ � α for all t ′ ∈ T , M , S , t � � α iff M , S , t ′ � α and t ′ ∈ T , M , S , t � @ t ′ α iff
(Revised) LARS Entailment Structure M = � S ⋆ , W , B � Substream S = ( T , υ ) of S ⋆ : currently considered window Time point t ∈ T M , S , t � a iff a ∈ υ ( t ) or a ∈ B , M , S , t � ¬ α iff M , S , t � α, M , S , t � α ∧ β iff M , S , t � α and M , S , t � β, M , S , t � α ∨ β iff M , S , t � α or M , S , t � β, M , S , t � α → β iff M , S , t � α or M , S , t � β, M , S , t ′ � α for some t ′ ∈ T , M , S , t � ♦ α iff M , S , t ′ � α for all t ′ ∈ T , M , S , t � � α iff M , S , t ′ � α and t ′ ∈ T , M , S , t � @ t ′ α iff M , S ′ , t � α where S ′ = w ( S , t ) , M , S , t � ⊞ w α iff
(Revised) LARS Entailment Structure M = � S ⋆ , W , B � Substream S = ( T , υ ) of S ⋆ : currently considered window Time point t ∈ T M , S , t � a iff a ∈ υ ( t ) or a ∈ B , M , S , t � ¬ α iff M , S , t � α, M , S , t � α ∧ β iff M , S , t � α and M , S , t � β, M , S , t � α ∨ β iff M , S , t � α or M , S , t � β, M , S , t � α → β iff M , S , t � α or M , S , t � β, M , S , t ′ � α for some t ′ ∈ T , M , S , t � ♦ α iff M , S , t ′ � α for all t ′ ∈ T , M , S , t � � α iff M , S , t ′ � α and t ′ ∈ T , M , S , t � @ t ′ α iff M , S ′ , t � α where S ′ = w ( S , t ) , M , S , t � ⊞ w α iff M , S , t � ⊲α iff M , S ⋆ , t � α ,
Scenario Carminweg 26 Kagraner Platz 27 A Kagran 25 U1
LARS Programs ) ) ) 5 5 A 2 2 7 r r 2 t t b , , 0 1 1 , ( ( ( d d d e e e r r r a a a e e e p p p p p p a a a • • • 11 12 13 14 15 16 17 18 19 20 21 22 23 @ T + L exp ( M , V ) ← ⊞ 5 @ T appeared ( N , V ) , plan ( N , M , V , L ) . takeBus ( N ) ← ⊞ +2 ♦ exp( N , B ) , bus ( B ) , not takeTram ( N ) . takeTram ( N ) ← ⊞ +5 ♦ exp( N , Tr ) , tram ( Tr ) , not takeBus ( N ) .
LARS Programs ) ) ) 5 5 A ) 2 2 7 ) r r 2 t t b A 5 , , 2 7 0 1 1 , r 2 t b ( ( ( d d d , 2 2 , e e e ( ( r r r a a p p a e e x x e e p p e p p p p a a a • • • • • 11 12 13 14 15 16 17 18 19 20 21 22 23 @ T + L exp ( M , V ) ← ⊞ 5 @ T appeared ( N , V ) , plan ( N , M , V , L ) . takeBus ( N ) ← ⊞ +2 ♦ exp( N , B ) , bus ( B ) , not takeTram ( N ) . takeTram ( N ) ← ⊞ +5 ♦ exp( N , Tr ) , tram ( Tr ) , not takeBus ( N ) .
LARS Programs ) ) ) 5 5 A ) 2 2 7 ) ) r r 2 t t b 2 A 5 ( , , 2 7 0 1 1 , r s 2 t b ( ( ( u d d d B , 2 2 , e e e e ( ( r r r a a k p p a e e a x x e t e p p e p p p p a a a • • • • • • 11 12 13 14 15 16 17 18 19 20 21 22 23 @ T + L exp ( M , V ) ← ⊞ 5 @ T appeared ( N , V ) , plan ( N , M , V , L ) . takeBus ( N ) ← ⊞ +2 ♦ exp( N , B ) , bus ( B ) , not takeTram ( N ) . takeTram ( N ) ← ⊞ +5 ♦ exp( N , Tr ) , tram ( Tr ) , not takeBus ( N ) .
LARS Programs ) ) ) 5 5 A ) ) 2 2 7 ) r r 2 2 t t b ( A 5 , , m 2 7 0 1 1 , r 2 t b ( ( ( a d d d r , 2 2 , T e e e ( ( r r r e a a p p a k e e x x e a e p p e p t p p p a a a • • • • • • 11 12 13 14 15 16 17 18 19 20 21 22 23 @ T + L exp ( M , V ) ← ⊞ 5 @ T appeared ( N , V ) , plan ( N , M , V , L ) . takeBus ( N ) ← ⊞ +2 ♦ exp( N , B ) , bus ( B ) , not takeTram ( N ) . takeTram ( N ) ← ⊞ +5 ♦ exp( N , Tr ) , tram ( Tr ) , not takeBus ( N ) .
Recommend
More recommend