Upload
others
View
3
Download
0
Embed Size (px)
Citation preview
DexterA Browser-based Data Explorer for End Users
Sudhir Agarwal, Abhijeet Mohapatra, and Michael Genesereth
Stanford Logic Group
Project Page: http://dexter.stanford.edu
Motivation Which Republican senators have
been fined by the FEC?
Name State …
Barbara Boxer CA …
Ted Cruz TX …
congressMembersAd-hoc analysis
More and more structured data made available in the Web
Ad-hoc Analysis of Data
• Too tedious:
• Limited querying capability of sources
• Spreadsheets don’t offer sufficient functionality
• Inability to query private and public data together without uploading the data
http://dexter.stanford.edu
Browser-basedDomain-independent
Explorer for structured data
Ad-hoc “on-the-fly” queries Queries across multiple sources
Dexter
Data = Tables• Tables
• Other sources of data (are mapped to tables)
• CSV, JSON or XML files
• APIs
• DOM elements in Web pages (e.g. <div>, <table> elements)
X Y1 a2 b
rY Za 3c 5
s
Queries = Dexlog Rules
Dexlog = Datalog + Negation (as failure) + Aggregation + Built-ins
X Y1 a2 b
rY Za 3c 5
s
q(X, Z) :- r(X, Y) & s(Y, Z)
Overview: http://dexter.stanford.edu/main/dexlog.html
Aggregation: Special operator setof() for constructing sets
setof(X, r(X, Y), S) ≡ SY = {X | r(X, Y)}
Which Republican senators have
been fined by the FEC?
Example: Ad-hoc Analysis
• Data about administrative fines: http://www.fec.gov/data/AdminFine.do
• Data about members of Congress: https://www.govtrack.us/api/v2/person [Govtrack API]
• Filter misc.fines to get senators who have been fined • Filter misc.congress to get republican members • Join the two filtered tables on member names
Dexlog query to join the two tables: misc.fines and misc.congress
Demo
Query Evaluationq(X, Z) :- govtrack.s(X, “Republican”) &
fec.t(X, “senator”)
Dexter
Query Decomposition
govtrack
Query Evaluationq(X, Z) :- govtrack.s(X, “Republican”) &
fec.t(X, “senator”)
Dexter
fec.t(X, “senator”)
govtrack.s(X, “Republican”)
Source Invocation
govtrack
Query Evaluationq(X, Z) :- govtrack.s(X, “Republican”) &
fec.t(X, “senator”)
Dexter
fec.t(X, “senator”)tuples
govtrack.s(X, “Republican”)tuples⋈
Answer Construction
govtrack
• Browser for supporting ad-hoc queries over structured data
• Create tables (from files, Web pages, DBs, APIs), edit tables, check integrity constraints, query tables using Dexlog rules, visualize tables as charts, share and export tables and rules
• Resources:
• Dexter: Plugging-n-Playing with Data Sources in Your Browser [AAAI ’14 workshop on Semantic Cities]
• Project page: http://dexter.stanford.edu
• Primer: http://dexter.stanford.edu/primer.pdf
• Dexlog Overview: http://dexter.stanford.edu/main/dexlog.html
Dexter