Outline Logistics (Project) & Review First Order Predicate Calculus Relational Algebra Datalog Information Integration Softbots Query Containment Rewriting.

Slides:



Advertisements
Similar presentations
Computer Science CPSC 322 Lecture 25 Top Down Proof Procedure (Ch 5.2.2)
Advertisements

Lecture 11: Datalog Tuesday, February 6, Outline Datalog syntax Examples Semantics: –Minimal model –Least fixpoint –They are equivalent Naive evaluation.
CPSC 504: Data Management Discussion on Chandra&Merlin 1977 Laks V.S. Lakshmanan Dept. of CS UBC.
Methods of Proof Chapter 7, Part II. Proof methods Proof methods divide into (roughly) two kinds: Application of inference rules: Legitimate (sound) generation.
Logic.
1 Relational Algebra & Calculus. 2 Relational Query Languages  Query languages: Allow manipulation and retrieval of data from a database.  Relational.
Efficient Query Evaluation on Probabilistic Databases
CPSC 322, Lecture 23Slide 1 Logic: TD as search, Datalog (variables) Computer Science cpsc322, Lecture 23 (Textbook Chpt 5.2 & some basic concepts from.
CPSC 322, Lecture 19Slide 1 Propositional Logic Intro, Syntax Computer Science cpsc322, Lecture 19 (Textbook Chpt ) February, 23, 2009.
Outline Recap Knowledge Representation I Textbook: Chapters 6, 7, 9 and 10.
CMPT 354, Simon Fraser University, Fall 2008, Martin Ester 52 Database Systems I Relational Algebra.
Proof methods Proof methods divide into (roughly) two kinds: –Application of inference rules Legitimate (sound) generation of new sentences from old Proof.
Constraint Logic Programming Ryan Kinworthy. Overview Introduction Logic Programming LP as a constraint programming language Constraint Logic Programming.
CPSC 322, Lecture 23Slide 1 Logic: TD as search, Datalog (variables) Computer Science cpsc322, Lecture 23 (Textbook Chpt 5.2 & some basic concepts from.
Knowledge Representation I (Propositional Logic) CSE 473.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 6 The Relational Algebra and Relational Calculus.
Embedded SQL Direct SQL is rarely used: usually, SQL is embedded in some application code. We need some method to reference SQL statements. But: there.
1 Relational Algebra and Calculus Yanlei Diao UMass Amherst Feb 1, 2007 Slides Courtesy of R. Ramakrishnan and J. Gehrke.
One More Normal Form Consider the dependencies: Product Company Company, State Product Is it in BCNF?
Relation Decomposition A, A, … A 12n Given a relation R with attributes Create two relations R1 and R2 with attributes B, B, … B 12m C, C, … C 12l Such.
1 Relational Algebra and Calculus Chapter 4. 2 Relational Query Languages  Query languages: Allow manipulation and retrieval of data from a database.
Outline Logistics Review Recursive Plans –Datalog programs vs. conjunctive queries –Recursive Programs –Maximality Effect of Functional dependencies Effect.
Ming Fang 6/12/2009. Outlines  Classical logics  Introduction to DL  Syntax of DL  Semantics of DL  KR in DL  Reasoning in DL  Applications.
Recursive query plans for Data Integration Oliver Michael By Rajesh Kanisetti.
1st-order Predicate Logic (FOL)
CSE314 Database Systems The Relational Algebra and Relational Calculus Doç. Dr. Mehmet Göktürk src: Elmasri & Navanthe 6E Pearson Ed Slide Set.
M Taimoor Khan Course Objectives 1) Basic Concepts 2) Tools 3) Database architecture and design 4) Flow of data (DFDs)
Logical Agents Logic Propositional Logic Summary
Logic in AI CSE 573. © Daniel S. Weld 2 Logistics Monday? Reading Ch 8 Ch 9 thru p 278 Section 10.3 Projects Due 11/10 Teams and project plan due by this.
Datalog Inspired by the impedance mismatch in relational databases. Main expressive advantage: recursive queries. More convenient for analysis: papers.
An Introduction to Artificial Intelligence – CE Chapter 7- Logical Agents Ramin Halavati
1 Relational Algebra & Calculus Chapter 4, Part A (Relational Algebra)
1 Relational Algebra and Calculas Chapter 4, Part A.
Relational Algebra.
Datalog –Another query language –cleaner – closer to a “logic” notation, prolog – more convenient for analysis – can express queries that are not expressible.
Logical Agents Chapter 7. Knowledge bases Knowledge base (KB): set of sentences in a formal language Inference: deriving new sentences from the KB. E.g.:
LDK R Logics for Data and Knowledge Representation Propositional Logic: Reasoning First version by Alessandro Agostini and Fausto Giunchiglia Second version.
Logical Agents Chapter 7. Outline Knowledge-based agents Logic in general Propositional (Boolean) logic Equivalence, validity, satisfiability.
For Wednesday Read chapter 9, sections 1-3 Homework: –Chapter 7, exercises 8 and 9.
Presented By: Miss N. Nembhard. Relation Algebra Relational Algebra is : the formal description of how a relational database operates the mathematics.
© Copyright 2008 STI INNSBRUCK Intelligent Systems Propositional Logic.
Row Types in SQL-3 Row types define types for tuples, and they can be nested. CREATE ROW TYPE AddressType{ street CHAR(50), city CHAR(25), zipcode CHAR(10)
Lu Chaojun, SJTU 1 Extended Relational Algebra. Bag Semantics A relation (in SQL, at least) is really a bag (or multiset). –It may contain the same tuple.
1 Reasoning with Infinite stable models Piero A. Bonatti presented by Axel Polleres (IJCAI 2001,
Datalog Another formalism for expressing queries: - cleaner - closer to a “logic” notation - more convenient for analysis - equivalent in power to relational.
1 Propositional Logic Limits The expressive power of propositional logic is limited. The assumption is that everything can be expressed by simple facts.
1 Lecture 08: E/R Diagrams and Functional Dependencies Friday, January 21, 2005.
First-Order Logic Semantics Reading: Chapter 8, , FOL Syntax and Semantics read: FOL Knowledge Engineering read: FOL.
Logical Agents Chapter 7. Outline Knowledge-based agents Propositional (Boolean) logic Equivalence, validity, satisfiability Inference rules and theorem.
1 The Relational Data Model David J. Stucki. Relational Model Concepts 2 Fundamental concept: the relation  The Relational Model represents an entire.
Lecture 9: Query Complexity Tuesday, January 30, 2001.
Logical Agents. Outline Knowledge-based agents Logic in general - models and entailment Propositional (Boolean) logic Equivalence, validity, satisfiability.
Module 2: Intro to Relational Model
EA C461 – Artificial Intelligence Logical Agent
Relational Algebra at a Glance
Modifying the Database
The Propositional Calculus
Chapter 2: Intro to Relational Model
Chapter 2: Intro to Relational Model
Logics for Data and Knowledge Representation
Logic Based Query Languages
Chapter 2: Intro to Relational Model
Example of a Relation attributes (or columns) tuples (or rows)
Knowledge Representation I (Propositional Logic)
Chapter 2: Intro to Relational Model
Datalog Inspired by the impedance mismatch in relational databases.
Terminology Product Attribute names Name Price Category Manufacturer
Syllabus Introduction Website Management Systems
Relational Model B.Ramamurthy 5/28/2019 B.Ramamurthy.
Lecture 08: E/R Diagrams and Functional Dependencies
Presentation transcript:

Outline Logistics (Project) & Review First Order Predicate Calculus Relational Algebra Datalog Information Integration Softbots Query Containment Rewriting Queries w/ Views

Softbot = Soft ware Ro bot [Etzioni AI Mag93] cgi invocation db update Effectors Planning-Based Control –High-Level Goals… –Increased Autonomy http finger Sensors

The Tuple Extraction Problem WWW Sources Formatted for People Softbot wants relational information These movies now showing: The Rock 7:20 Great! Vertigo 9:30 Classic! Star Trek 7:30 Beam me up Bookmark Me Now! Thanks! N ? [Kushmerick 97]

HTML Source Showtimes Now Showing: The Rock 7:20 Great! Vertigo 9:30 Classic Star Trek 7:30 Beam me up Bookmark me now! Thanks!

Note the Movie Names…. Showtimes Now Showing: The Rock 7:20 Great! Vertigo 9:30 Classic Star Trek 7:30 Beam me up Bookmark me now! Thanks!

Surrounded by and Showtimes Now Showing: The Rock 7:20 Great! Vertigo 9:30 Classic Star Trek 7:30 Beam me up Bookmark me now! Thanks!

Similarly, Showtimes by, Showtimes Now Showing: The Rock 7:20 Great! Vertigo 9:30 Classic Star Trek 7:30 Beam me up Bookmark me now! Thanks!

A Wrapper ExtractMovieTimes Tuples := {} While P not empty do: Skip forward to Title := ExtractTextUntilNext( ) Skip forward to Time := ExtractTextUntilNext( ) Push (Title, Time) onto Tuples Return Tuples

Project (5/7) Select Information Sources –Movie domain –We supply an ontology –You provide Datalog source descriptions (5/14) Write Wrappers (Class to share) –Each one subclasses Java wrapper class –Regular expression package (6/11) Complete Information Integration Softbot

Course Topics by Week Search & Constraint Satisfaction Knowledge Representation 1: Propositional Logic Autonomous Spacecraft 1: Configuration Mgmt Autonomous Spacecraft 2: Reactive Planning Information Integration 1: Knowledge Representation Information Integration 2: Planning & Execution Supervised Learning & Datamining Reinforcement Learning Bayes Nets: Inference & Learning Review & Future Forecast

Knowledge Representation Propositional Logic Relational Algebra Datalog First-Order Predicate Calculus Bayes Networks Description Logic(s)

Reasoning Algorithms Tasks –Satisfiability –Entailment Approach –Systematic (e.g. DPLL) –Stochastic (e.g. GSAT) Properties –Soundness –Completeness –Complexity

13 Summary: Propositional Logic Syntax –Prop variables: P, Q, … –Connectives: and, or, not, =>, = Semantics – Truth Tables Inference –Modus Ponens –Resolution Complexity: –NPC  P  Q, P Q  P  Q, P  R Q  R

14 Propositional. Logic vs First Order Ontology Syntax Semantics Inference Facts: P, Q Atomic sentences Connectives Truth Tables NPC, but SAT algos work well Objects (e.g. Dan) Properties (e.g. mother-of) Relations (e.g. female) Variables & quantification Sentences have structure: terms female(mother-of(X))) Interpretations (Much more complicated) Undecidable, but theorem proving works sometimes Look for tractable subsets

15 Definitions Constants: a,b, dog33. –Name a specific object. Variables: X, Y. –Refer to an object without naming it. Functions: father-of –Mapping from objects to objects. Terms: father-of(father-of(dog33)) –Refer to objects Atomic Sentences: in(father-of(dog33), food6) –Can be true or false –Correspond to propositional symbols P, Q

16 More Definitions Logical connectives: and, or, not, => Quantifiers: –For all  –There exists  Examples –Dumbo is grey –Elephants are grey –There is a grey elephant

Interaction of quant + connective  x E(x)  G(x)  x E(x)  G(x)  x E(x)  G(x)  x E(x)  G(x) E(x) == “x is an elephant” G(x) == “x has the color grey”

Nested Quantifiers: Order matters! Examples –Every dog has a tail –Someone is loved by everyone

Outline Logistics (Project) & Review First Order Predicate Calculus Relational Algebra Datalog Information Integration Softbots Query Containment Rewriting Queries w/ Views

Today’s KR Sequence Propositional Logic Relational Algebra = Datalog without recursion Datalog First-Order Predicate Calculus

Terminology Name Price Category Manufacturer gizmo $19.99 gadgets GizmoWorks Power gizmo $29.99 gadgets GizmoWorks SingleTouch $ photography Canon MultiTouch $ household Hitachi Tuples Attribute names Product Product(name, price, category, manufacturer) (Arity=4)

More Terminology Every attribute has an atomic type. Relation Schema: relation name + attribute names + attribute types Relation instance: a set of tuples. Only one copy of any tuple! (not) Database Schema: a set of relation schemas. Database instance: a relation instance for every relation in the schema.

More on Tuples Formally, a mapping from attribute names to (correctly typed) values: name gizmo price $19.99 category gadgets manufacturer GizmoWorks Sometimes we refer to a tuple by itself: (note order of attributes)) (gizmo, $19.99, gadgets, GizmoWorks) or Product (gizmo, $19.99, gadgets, GizmoWorks).

Integrity Constraints An important functionality of a DBMS is to enable the specification of integrity constraints and to enforce them. Knowledge of integrity constraints is also useful for query planning and optimization. Examples of constraints: keys, superkeys foreign keys domain constraints, tuple constraints. Functional dependencies, multivalued dependencies.

Keys A minimal set of attributes that uniquely identify the tuple (I.e., there is no pair of tuples with the same values for the key attributes): Person: social security number name name + address name + address + age Perfect keys are often hard to find, but organizations usually invent something anyway. Superkey: a set of attributes that contains a key. A relation may have multiple keys, but only one primary key employee number, social-security number Movies?

Foreign Key Constraints Purchase: buyer price product Joe $20 gizmo Jack $20 E-gizmo Product: name manufacturer description gizmo G-sym great stuff E-gizmo G-sym even better An attribute of a relation R is must refer to a key of a relation S.

Functional Dependencies Definition: If two tuples agree on the attributes A, A, … A 12n then they must also agree on the attributes B, B, … B 12m Formally: A, A, … A 12n B, B, … B 12m Key of a relation: all the attributes are either on the left or right.

Relational Algebra Operators: tuple sets as input, new set as output Basic Binary Set Operators –Result is table (set) with same attributes Sets must be compatible! –R1(A1,A2,A3)  R2(B1,B2,B3)  Domain(Ai) = Domain(Bi) –Union All tuples in either R1 or in R2 –Intersection All tuples in both R1 and R2 –Difference All tuples in R1 but not in R2 –Complement - what’s the universe? Selection, Projection, Cartesian Product, Join

Selection Grab a subset of the tuples in a relation that satisfy a given condition –Use and, or, not, >, <… to build condition Unary operation… returns set with same attributes, but ‘selects’ rows

Employee SSNNameDepartmentIDSalary John130, Tony132, Alice245,000 Selection Example SSNNameDepartmentIDSalary Alice245,000 Select DepartmentID = 2

Projection Unary operation, selects columns Returned schema is different, –so returned tuples are not subset of original set –Contrast with selection Eliminates duplicate tuples

Cartesian Product Binary Operation Result is set of tuples combining all elements of R1 with all elements of R2, for R1  R2 Schema is union of Schema(R1) & Schema(R2) Notice we could do selection on result to get meaningful info!

Cartesian Product Example

Join Most often used… Combines 2 relations, selecting only related tuples Equivalent to a cross product followed by selection Resulting schema has all attributes of the two relations, but one copy of join condition attributes

Outline Logistics (Project) & Review First Order Predicate Calculus Relational Algebra Datalog Information Integration Softbots Query Containment Rewriting Queries w/ Views

Logic Based Query Languages Datalog: –Subset of First Order Predicate Calculus Function Free Restricted to Horn Clauses More Powerful than relational algebra –Enables expressing recursive queries –More convenient for analysis Without recursion (but with negation) it is –Equivalent in power to relational algebra

Datalog Concepts Atoms Datalog rules, datalog programs EDB predicates, IDB predicates Conjunctive queries Recursion Built-in predicates Negated atoms, stratified programs. Semantics: least fixpoint.

Predicates and Atoms - Relations are represented by predicates - Tuples are represented by atoms. Purchase( “joe”, “bob”, “Nike Town”, “Nike Air”, 2/2/98) - arithmetic: built-in relations: X Z/2 - negated atoms: NOT Product(“Brooklyn Bridge”, $100, “Microsoft”) Just like in First-Order Predicate Calculus

Datalog Rules and Queries A pure datalog rule (e.g. first-order horn clause with a positive literal) has the following form: head :- atom1, atom2, …., atom,… where all the atoms are non-negated and relational. BritishProduct(X) :- Product(X,Y,P) & Company(P, “UK”, SP) A datalog program is a set of datalog rules. A program with a single rule is a conjunctive query. We distinguish EDB predicates and IDB predicates EDB’s are stored in the database, appear only in the bodies IDB’s are intensionally defined, appear in both bodies and heads.

Correspondence: Datalog ~ Relational Algebra ED(Name, SSN, Dname) :- Employee(Name, SSN) & Dependents(SSN, Dname) Given: EDBs Define: IDB

The Meaning of Datalog Rules Repeat the following until you cannot derive any new facts: Consider every assignment from the variables in the body to the constants in the database. If each of the atoms in the body is made true by the assignment, then add the tuple for the head into the relation of the head. Start with the facts in the EDB and iteratively derive facts for IDBs.

Transitive Closure Suppose we are representing a graph by a relation Edge(X,Y): Edge(a,b), Edge (a,c), Edge(b,d), Edge(c,d), Edge(d,e) a b c d e I want to express the query: Find all nodes reachable from a.

Recursion in Datalog Path( X, Y ) :- Edge( X, Y ) Path( X, Y ) :- Path( X, Z ), Path( Z, Y ). Semantics: evaluate the rules until a fixedpoint: Iteration #0: Edge: {(a,b), (a,c), (b,d), (c,d), (d,e)} Path: {} Iteration #1: Path: {(a,b), (a,c), (b,d), (c,d), (d,e)} Iteration #2: Path gets the new tuples: (a,d), (b,e), (c,e) Iteration #3: Path gets the new tuple: (a,e) Iteration #4: Nothing changes -> We stop. Note: number of iterations depends on the data. Cannot be anticipated by only looking at the query! a b c d e

Built in Predicates Rules may include atoms with built-in predicates: ExpensiveProduct(X) :- Product(X,Y,P) & P > $100 But: we need to restrict the use of built-in atoms in rules. P(X) :- R(X) & X<Y What does this mean? Hence, we require that every variable that appears in a built-in atom also appears in a relational atom.

Negated Subgoals Rules may include negated subgoals, but in restricted forms: Ok: P(X,Y) :- Between(X,Y,Z) & NOT Direct(X,Z) Bad: Q(X, Y) :- R(X) & NOT S(Y) Bad but salvagable: T(X) :- R(X) & NOT S(X,Y) We’ll rewrite as: S’(X) :- S(X,Y) T(X) :- R(X) & NOT S’(X)

Stratified Negation is Ok A predicate P depends on a predicate Q if: Q appears negated in a rule defining P. If there is a cycle in the dependency graph, the datalog program is not stratified. Example: p(X) :- r(X) & NOT q(X) q(X) :- r(X) & NOT p(X) Suppose r has the tuple {1} What is the fixed point?

Subtleties with Stratified Rules Example: p(X) :- r(X) q(X) :- s(X) & NOT p(X). Suppose: r = {1}, and s = {1,2} One solution: p = {1} and q = {2} Another solution: p={1,2} and q={}. Perfect model semantics: apply the rules stratum after stratum. q p

Outline Logistics (Project) & Review First Order Predicate Calculus Relational Algebra Datalog Information Integration Softbots Query Containment Rewriting Queries w/ Views

Motivation: Info Integration Want agent such that User says what she wants Softbot determines how & when to achieve it Example: –Show me all reviews of movies starring Marlon Brando that are currently playing in Seattle EbertIMDBSpotShowT

User must know which sites have relevant info User must go to each one in turn Slow: Sequential access takes time Confusing: Each site has a different interface User must manually integrate information Problems Before your softbot can solve these problems it must be able to perceive WWW content...

Information Integration Optimizer

Representation I World Ontology –Defines predicates of relational schemata –E.g., actor-in (Movie, Part, Name), review-of (Movie, Part) year-of (Movie, Year) shows-in (Movie, City, Theatre) –User uses this language to specify queries –You use language to specify content of info sites

:- vs.  vs.  Representation II: Queries Find-all (M, Review, brando, seattle) Such That actor-in(M, Part, brando) & shows-in(M, seattle, T) & review-of(M, Review) Writen in Datalog: query(M, R, Brando, Seattle) :- actor-in(M, Part, brando) & shows-in(M, seattle, T) & review-of(M, R)

Representation II Information Source Functionality –Info Required? $ Binding Patterns –Info Returned? –Mapping to World Ontology Source may be incomplete :  (not  ) IMDBActor($Actor, M)  actor-in(M, Part, Actor) Spot($M, Rev, Y)  review-of(M, Rev) & year-of(M, Y) Sidewalk($C, M, Th)  shows-in(M, C, Th) For Example [Rajaraman95]

A Plan to Solve the Query IMDBActor($Actor, M)  actor-in(M, Part, Actor) Spot($M, Rev, Y)  review-of(M, Rev) & year-of(M, Y) Sidewalk($C, M, Th)  shows-in(M, C, Th) How verify plan answers query? How find this solution? query(M, R, Brando, Seattle)  actor-in(M, Part, brando) & shows-in(M, seattle, T) & review-of(M, R) plan(M, R, Brando, Seattle)  IMDBActor(brando, M) & Sidewalk(seattle, M, Th) & Spot(M, Rev, Y)

Two Questions How verify this plan answers query? 1. Verify information content of plan Same as DB problem of rewriting queries using views Show expansion of plan equivalent to query Technique of query containment 2. Verifying binding pattern constraints How find a valid solution plans? –Search... –Search-free synthesis of maximal recursive plan

Outline Logistics (Project) & Review First Order Predicate Calculus Relational Algebra Datalog Information Integration Softbots Query Containment Rewriting Queries w/ Views

Query Containment Containment –q1  q2 iff q1(D)  q2(D) for every database instance, D Equivalence –q1  q2 iff q1  q2 and q2  q1 Satisfiability –q is satisfiable if  D such that q(D)  Let q1, q2 be datalog rules E.g. q1(X) :- p(X) & r(X)

Motivation Removing redundant subgoals Detecting independence of queries from update Knowledge Base verification Semantic caching Reusing views (results of previous queries) –Internet Information Integration Softbots

Perspective from Logic Containment a special form of validity Given q1(A, D) :- p(A, B) & r(C, D) q2(A, D) :- p(A, B) & r(B, D) q1  q2 is equivalent to saying the next sentence is valid:  A, D (  B p(A, B)  r(B, D)) => (  B,C p(A, B)  r(C, D))

 ( p(A, B)) = p(E, G)  (r(C, D)) = r(G, F) q1 contains q2 iff   : vars(q1) -> vars(q2) s.t. –  literals L  body(q1),  (L)  body(q2) –  (head(q1)) = head(q2) For example –Q1: q(A, D) :- p(A, B) & r(C, D) –Q2: q(E, F) :- p(E, G) & r(G, F) & s(E, F) –  : A -> E D -> F B -> G C -> G Containment Mappings [Chandra & Merlin 77]

Computing Containment To show q1 contains q2 Search... –Space of possible containment mappings –Incrementally verify:  literals L  body(q1),  literal L’  body(q2) such that  (L)=L’ NP-complete for pure conjunctive queries “Works” for unions of conjunctive queries

Reusing Materialized Views q (A, E) :- r(A, B) & r(B, C) & s(C, D) & s(D, E) Suppose all we have are results of previous queries: v(F, G) :- r(F, H) & r(H, G) & s(G, I) u(J, K) :- r(M, J) & s(J, N) & s(N, K) Can we still answer q? Yes!q'(X, Y) :- v(X, Z) & u(Z, Y) Let q” denote expansion of q’ q”(X, Y) :- r(X, H) & r(H, Y) & s(Y, I) & r(M, Z) & s(Z, N) & s(N, Y) Equivalence chain: q  q”  q’ I.e. prove q  q’  q”  q

I Y H q  q” q (A, E) :- r(A, B) & r(B, C) & s(C, D) & s(D, E) q”(X, Y) :- r(X, H) & r(H, Y) & s(Y, I) & r(M, Z) & s(Z, N) & s(I, Y)  : A -> X B -> C -> D -> E -> Y

Back to Information Integration How verify this plan answers query? 1. Verify information content of plan Same as DB problem of rewriting queries using views Show expansion of plan equivalent to query Technique of query containment 2. Verifying binding pattern constraints How find a valid solution plans? –Search... –Search-free synthesis of maximal recursive plan

A Plan to Solve the Query IMDBActor($Actor, M)  actor-in(M, Part, Actor) Spot($M, Rev, Y)  review-of(M, Rev) & year-of(M, Y) Sidewalk($C, M, Th)  shows-in(M, C, Th) query(M, R, b, s)  actor-in(M, Part, b) & shows-in(M, s, T) & review-of(M, R) plan(M, R, b, s)  IMDBActor(b, M) & Sidewalk(s, M, Th) & Spot(M, R, Y) plan'(M, R, b, s)  actor-in(M, P, A) & review-of(M, R) & year-of(M, Y) & shows-in(M, C, T)  : M -> M Part -> P b -> A s -> C R -> R

How verify this plan answers query? 1. Verify information content of plan 2. Verifying binding pattern constraints IMDBActor($Actor, M)  actor-in(M, Part, Actor) Spot($M, Rev, Y)  review-of(M, Rev) & year-of(M, Y) Sidewalk($C, M, Th)  shows-in(M, C, Th) plan(M, R, brando, seattle)  IMDBActor(b, M) & Sidewalk(s, M, Th) & Spot(M, R, Y)

Outline Logistics (Project) & Review First Order Predicate Calculus Relational Algebra Datalog Information Integration Softbots Query Containment Rewriting Queries w/ Views

Summary How Represent Contents of Information Sources? –Datalog How pose a query? –Datalog How verify a plan answers query? 1. Verify information content of plan Check containment of query and plan expansion 2. Verifying binding pattern constraints How find a valid solution plans? –Search through the space of... –Search-free synthesis of maximal recursive plan Paper 6.1