230 likes | 378 Views
Approximate Functional Dependencies for XML Data. Fabio Fassetti , Bettina Fazzinga. DEIS, University of Calabria, Italy. ADBIS 2007 - Varna (BUL), September 29 - October 3. Outline. Preliminaries Inference Problem Classical Approach Our Approach System Architecture Conclusions. faculty.
E N D
Approximate Functional Dependencies for XML Data Fabio Fassetti, Bettina Fazzinga DEIS, University of Calabria, Italy ADBIS 2007 - Varna (BUL), September 29 - October 3
Outline • Preliminaries • Inference Problem • Classical Approach • Our Approach • System Architecture • Conclusions Approximate Functional Dependencies for XML
faculty 1 2 9 16 course course course 3 5 7 12 10 14 19 21 17 year professor name year professor name year professor name 4 8 18 6 11 13 22 20 15 "Databases Systems" "Databases Systems" "2005" "Robinson" "Programming" "2006" "Robinson" "2006" "Brown" Preliminaries:XML Functional Dependency XML Paths … {p1, p2,…pn} q Right Part Left Part XML Tree: XFD: /faculty/course/name, /faculty/course/year /faculty/course/professor Approximate Functional Dependencies for XML
faculty 1 2 9 16 course course course 3 5 7 12 10 14 19 21 17 year professor name year professor name year professor name 4 8 18 6 11 13 22 20 15 "Databases Systems" "Databases Systems" "2005" "Robinson" "Programming" "2006" "Robinson" "2006" "Brown" 1 1 1 faculty faculty faculty 2 9 16 course course course 3 7 10 14 17 21 name professor name professor name professor 4 8 11 18 15 22 "Databases Systems" "Databases Systems" "Robinson" "Robinson" "Programming" "Brown" Preliminaries:Tuples {/faculty/course/name/#text, /faculty/course/professor/#text} Approximate Functional Dependencies for XML
Inference Problem XML Functional Dependencies XML Document XML Document Is it satisfied? XFD Approximate Functional Dependencies for XML
Classical Approach: XFD Satisfaction XFD f: {p1, p2,…pn} q XML Document f is satisfied if and only if each pair of tuples satisfies f Tuples {t1, t2, …, tm} no (ti, tj) satisfies f yes Are ti, tjequal w.r.t. the left part of f? Are ti, tjequal w.r.t. the right part of f? no yes ti, tj (ti, tj) does not satisfy f ß f is not satisfied by the XML Document Approximate Functional Dependencies for XML
faculty 1 2 9 16 course course course 3 5 7 12 10 14 19 21 17 year professor name year professor name year professor name 4 8 18 6 11 13 22 20 15 "Databases Systems" "Databases Systems" "2005" "Robinson" "Programming" "2006" "Robinson" "2006" "Brown" 1 1 1 faculty faculty faculty 2 9 16 course course course 3 7 10 14 17 21 name professor name professor name professor 4 8 11 18 15 22 "Databases Systems" "Databases Systems" "Robinson" "Robinson" "Programming" "Brown" Classical Approach: XFD Satisfaction XML Tree: ? XFD: /faculty/course/name/#text /faculty/course/professor/#text Tuples: Approximate Functional Dependencies for XML
1 1 1 faculty faculty faculty 2 9 16 course course course 3 7 10 14 17 21 name professor name professor name professor 4 8 11 18 15 22 "Databases Systems" "Databases Systems" "Robinson" "Robinson" "Programming" "Brown" Classical Approach: XFD Satisfaction ? Yes /faculty/course/name/#text /faculty/course/professor/#text ok (2,3): (1,3): ok (1,2): ok 1 2 3 = ≠ = ≠ Approximate Functional Dependencies for XML
= = Classical Approach: XFD Satisfaction YES! ? /faculty/course/name /faculty/course/book (2,3): ok (1,3): ok (1,2): ok 1 2 = = 3 Approximate Functional Dependencies for XML
= Classical Approach: Flaw 1 NO! ? /faculty/course/name /faculty/course/book (1,3): no 1 2 = 3 Approximate Functional Dependencies for XML
≈dist>s ≈dist>s Our Approach: s-approximation YES! ? /faculty/course/name /faculty/course/book (2,3): ok (1,2): ok (1,3): ok s-satisfied 1 2 ≈dist<s 3 ≈dist<s Approximate Functional Dependencies for XML
= = Classical Approach: Flaw 2 YES! ? /faculty/course/professor /faculty/course/semester (2,3): ok (1,3): ok (1,2): ok = = 1 2 3 Approximate Functional Dependencies for XML
≈ Our Approach: s-approximation NO! ? /faculty/course/professor /faculty/course/semester (1,3): NO Not s-satisfied 1 2 ≈ 3 Approximate Functional Dependencies for XML
Classical Approach: Flaw 3 NO! ? /faculty/course/name /faculty/course/credits (1,4): ok (1,3): no (1,2): no (1,5): ok (2,5): ok (3,5): ok (2,4): ok (2,3): ok (3,4): ok (4,5): ok 1 2 3 4 5 Approximate Functional Dependencies for XML
≈ Our Approach: s-approximation NO! ? /faculty/course/name /faculty/course/credits (1,4): ok (1,3): no (1,2): no (1,5): ok (2,5): ok (3,5): ok (2,4): ok (2,3): ok (3,4): ok (4,5): ok Not s-satisfied ≈ 1 2 3 4 5 Approximate Functional Dependencies for XML
Our Approach: q-approximation YES! ? /faculty/course/name /faculty/course/credits s-satisfied (1,4): ok (1,3): no (1,2): no (1,5): ok (2,5): ok (3,5): ok (2,4): ok (2,3): ok (3,4): ok (4,5): ok 1 2 3 4 5 Approximate Functional Dependencies for XML
Our Approach: q-approximation YES! /faculty/course/name /faculty/course/credits ß Set of tuples: {1,2,3,4,5} q-satisfied 4/5 > q ? Maximal set of tuples s-satisfying the XFD: {2,3,4,5} 1 2 3 4 5 Approximate Functional Dependencies for XML
Our Approach: Approximate Inference s XML Document q XML Functional Dependencies XML Document Is it (s,q)-satisfied? XFD Approximate Functional Dependencies for XML
Our Approach:XFD Approximate Satisfaction XFD f: {p1, p2,…pn} q XML Document Tuples {t1, t2, …, tm} (ti, tj) s-satisfies f no yes Are ti, tjs-similar w.r.t. the left part of f? Are ti, tjs-similar w.r.t. the right part of f? yes no ti, tj (ti, tj) does not s-satisfy f THEN f is not satisfied by the XML Document Approximate Functional Dependencies for XML
Our Approach:XFD Approximate Satisfaction XFD f: {p1, p2,…pn} q XML Document Tuples {t1, t2, …, tm} Compute the size of the maximal set of tuples s-satisfying f Is this size at least the q% of the total number of tuples? yes no f is not (s,q)-satisfied by the XML document f is (s,q)-satisfied by the XML document Approximate Functional Dependencies for XML
Fox System Architecture Preprocessing Module XFD Generator XFD Checker Graphical User Interface XML Doc s, q XFDs (s,q)-approx satisfied Approximate Functional Dependencies for XML
Conclusions • The concept of approximate satisfaction of XFDs has been motivated and discussed • A system to infer such XFDs has been presented Approximate Functional Dependencies for XML
Thank You Approximate Functional Dependencies for XML