1
Semantic Technology
via Business Rules
in Open Vocabulary English
Adrian Walker
www.executable-english.com
2
Agenda• The World Wide Database vision
• Only experts have the skills to use the current tools
• An easier future for Semantic Technology -- combine:
– Semantics1 - Data Semantics = the current Technology
– Semantics2 - what a reasoner should do
– Semantics3 - Application Semantics = English meanings at the UI
• A browser-based system for writing and running applications in English
• Examples : Semantics of ontology data, and of oil-industry SQL data
• Google indexes and searches applications that are written in English
• Summary
3
The World Wide Database vision
"If HTML and the Web made all the online documents look like one huge
book, the Semantic Web will make all the data in the world look like one
huge database”
-- Tim Berners-Lee
What is the Semantic Web?
“Data integration across application, organizational boundaries”
-- Tim Berners-Lee
4
negotiable semantic distance Manufacturer’s Englishmodel of the world
The World Wide Database vision
Retailer’s Englishmodel of the world
5
Retailer’s Englishmodel of the world
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Alt rdf:about="http://retailer.org/node"/>
</rdf:RDF>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Alt rdf:about="http://manuf.org/node"/>
</rdf:RDF>
negotiable semantic distance
negotiable semantic distance Manufacturer’s Englishmodel of the world
The World Wide Database vision
6
Retailer’s Englishmodel of the world
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Alt rdf:about="http://retailer.org/node"/>
</rdf:RDF>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Alt rdf:about="http://manuf.org/node"/>
</rdf:RDF>
negotiable semantic distance
negotiable semantic distance Manufacturer’s Englishmodel of the world
X semantic disconnects X
The World Wide Database vision
7
Retailer’s Englishmodel of the world
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Alt rdf:about="http://retailer.org/node"/>
</rdf:RDF>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Alt rdf:about="http://manuf.org/node"/>
</rdf:RDF>
negotiable semantic distance
negotiable semantic distance Manufacturer’s Englishmodel of the world
X semantic disconnects X
The World Wide Database vision
8
Agenda• The World Wide Database vision
• Only experts have the skills to use the current tools
• An easier future for Semantic Technology -- combine:
– Semantics1 - Data Semantics = the current Technology
– Semantics2 - what a reasoner should do
– Semantics3 - Application Semantics = English meanings at the UI
• A browser-based system for writing and running applications in English
• Examples : Semantics of ontology data, and of oil-industry SQL data
• Google indexes and searches applications that are written in English
• Summary
9
Only Experts have the Skills to Use the Current Tools
KnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub Topic
10
Only Experts have the Skills to Use the Current Tools
Researcher
Adrian
Bob
ClaireKnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub TopicInstance
11
Only Experts have the Skills to Use the Current Tools
Researcher
Adrian
Bob
ClaireKnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub TopicInstance
Does research on
12
Only Experts have the Skills to Use the Current Tools
Researcher
Adrian
Bob
ClaireKnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub TopicInstance
Does research on
New user asked: how can I use RDF and Owl to find out from the above that “Bob does research into Semantic Web” ?
13
Only Experts have the Skills to Use the Current Tools
Researcher
Adrian
Bob
ClaireKnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub TopicInstance
Does research on
New user asked: how an I use RDF and Owl to find out from the above that “Bob does research into Semantic Web” ?Expert replied: “You can do it by declaring subtopic to be transitive and by using a rule such as
ObjectPropertyAtom( worksIn, ?x, ?y) IF ObjectPropertyAtom( worksIn, ?x, ?z) AND ObjectPropertyAtom( subtopic, ?z, ?y)
Such rules can be expressed in RuleML or in SWRL, but you would have to find aninference tool for them.”
14
Agenda• The World Wide Database vision
• Only experts have the skills to use the current tools
• An easier future for Semantic Technology -- combine:
– Semantics1 - Data Semantics = the current Technology
– Semantics2 - what a reasoner should do
– Semantics3 - Application Semantics = English meanings at the UI
• A browser-based system for writing and running applications in English
• Examples : Semantics of ontology data, and of oil-industry SQL data
• Google indexes and searches applications that are written in English
• Summary
15
KnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub Topic
An Easier Future for Semantic Technology
this-item is a sub topic of this-topic===================================Data Mining Knowledge DiscoveryText Mining Knowledge DiscoveryKnowledge Discovery Semantic Web
Facts:
16
KnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub Topic
Researcher
Adrian
Bob
Claire
Instance
An Easier Future for Semantic Technology
this-item is a sub topic of this-topic===================================Data Mining Knowledge DiscoveryText Mining Knowledge DiscoveryKnowledge Discovery Semantic Web
this-person is a researcher===================Adrian Bob Claire
Facts:
17
KnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub Topic
Researcher
Adrian
Bob
Claire
Instance
Does research on
An Easier Future for Semantic Technology
this-person does research into this-topic==============================Adrian Knowledge DiscoveryBob Data MiningClaire Text Mining
this-item is a sub topic of this-topic===================================Data Mining Knowledge DiscoveryText Mining Knowledge DiscoveryKnowledge Discovery Semantic Web
this-person is a researcher===================Adrian Bob Claire
Facts:
18
KnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub Topic
Researcher
Adrian
Bob
Claire
Instance
Does research on
An Easier Future for Semantic Technology
some-subject is a sub topic of some-subject1that-subject1 is a sub topic of some-topic-----------------------------------------------------that-subject is a sub topic of that-topic
A rule:
19
An Easier Future for Semantic Technology
some-person does research into some-subjectthat-subject is a sub topic of some-topic------------------------------------------------------that-person does research into that-topic
some-subject is a sub topic of some-subject1that-subject1 is a sub topic of some-topic-----------------------------------------------------that-subject is a sub topic of that-topic
Another rule:
-- To run or change this example, please point Firefox or Chrome to the demo OwlResearchOnt at www.executable-english.com
KnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub Topic
Researcher
Adrian
Bob
Claire
Instance
Does research on
20
An Easier Future for Semantic Technology
Question: Bob does research into some-topic?
KnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub Topic
Researcher
Adrian
Bob
Claire
Instance
Does research on
21
An Easier Future for Semantic Technology
Question: Bob does research into some-topic?
Answer: Bob does research into this-topic===========================
Data MiningKnowledge DiscoverySemantic Web
-- To run or change this example, please point Firefox or Chrome to the demo OwlResearchOnt at www.executable-english.com
KnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub Topic
Researcher
Adrian
Bob
Claire
Instance
Does research on
22
An Easier Future for Semantic Technology
Bob does research into Data Mining Data Mining is a sub topic of Semantic Web --------------------------------------------------------Bob does research into Semantic Web
Explanation:
KnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub Topic
Researcher
Adrian
Bob
Claire
Instance
Does research on
23
An Easier Future for Semantic Technology
Bob does research into Data Mining Data Mining is a sub topic of Semantic Web --------------------------------------------------------Bob does research into Semantic Web
Data Mining is a sub topic of Knowledge Discovery Knowledge Discovery is a sub topic of Semantic Web ------------------------------------------------------------------Data Mining is a sub topic of Semantic Web
Explanation:
KnowledgeDiscovery
Data MiningText Mining
SemanticWeb
Sub Topic
Researcher
Adrian
Bob
Claire
Instance
Does research on
24
• Combine, in one system for non-expert authors and users
An Easier Future for Semantic Technology
25
• Combine, in one system for non-expert authors and users
• Semantics1 - Data Semantics
• the current technology
An Easier Future for Semantic Technology
26
• Combine, in one system for non-expert authors and users
• Semantics1 - Data Semantics
• the current technology
• Semantics2 -Mathematical Theory of Declarative Knowledge
• specifies what a reasoner should do
An Easier Future for Semantic Technology
27
• Combine, in one system for non-expert authors and users
• Semantics1 - Data Semantics
• the current technology
• Semantics2 -Mathematical Theory of Declarative Knowledge
• specifies what a reasoner should do
• Semantics3 - Application Semantics
• English meanings at the user/author interface
An Easier Future for Semantic Technology
28
Agenda• The World Wide Database vision
• Only experts have the skills to use the current tools
• An easier future for Semantic Technology -- combine:
– Semantics1 - Data Semantics = the current Technology
– Semantics2 - what a reasoner should do
– Semantics3 - Application Semantics = English meanings at the UI
• A browser-based system for writing and running applications in English
• Examples : Semantics of ontology data, and of oil-industry SQL data
• Google indexes and searches applications that are written in English
• Summary
29
A browser-based system for writing and running applications in English
Business Policy Agents
End User / Author
Writes Business Rules in open vocabulary English Directly into a browser
Runs the Rules Using the browser
Sees English explanations of the Results
Who does researchInto the Semantic Web?
Semantics3
30
A browser-based system for writing and running applications in English
Programmer
Theory ofDeclarativeKnowledge
End User / Author
Writes Business Rules in open vocabulary English Directly into a browser
Runs the Rules Using the browser
Sees Englishexplanations of the Results
Who does researchInto the Semantic Web?
Semantics3
Semantics2
31
A browser-based system for writing and running applications in English
Programmer
Theory ofDeclarativeKnowledge
Business Policy Agents
InternetBusiness Logic
Application Independent
End User / Author
Writes Business Rules in open vocabulary English Directly into a browser
Runs the Rules Using the browser
Sees Englishexplanations of the Results
Who does research.Into the Semantic Web?
Semantics3
Semantics2
32
A browser-based system for writing and running applications in English
Programmer
Theory ofDeclarativeKnowledge
Business Policy Agents
InternetBusiness Logic
Application Independent
End User / Author
Writes Business Rules in open vocabulary English Directly into a browser
Runs the Rules Using the browser
Sees Englishexplanations of the Results
Who does research.Into the Semantic Web?
SQL
RDF
Semantics3
Semantics2
Semantics1
33
Agenda• The World Wide Database vision
• Only experts have the skills to use the current tools
• An easier future for Semantic Technology -- combine:
– Semantics1 - Data Semantics = the current Technology
– Semantics2 - what a reasoner should do
– Semantics3 - Application Semantics = English meanings at the UI
• A browser-based system for writing and running applications in English
• Examples : Semantics of ontology data, and of oil-industry SQL data
• Google indexes and searches applications that are written in English
• Summary
34
A retailer orders computers from a manufacturer
In the retailer's terminology, a computer is called a PC for Gamers, while in the manufacturer's terminology, it is called a Prof Desktop.
The retailer and the manufacturer agree that both belong to the class Worksts/Desktops
Use semantic resolution to find out to what extent a Prof Desktop has the required memory, CPU and so forth for a PC for Gamers
-- Example based on “Semantic Resolution for E-Commerce”, by Yun Peng, Youyong Zou, Xiaocheng Luan ( UMBC ) and Nenad Ivezic, Michael Gruninger and Albert Jones ( NIST )
Ex 1: English semantics of ontology data
35
Retailer’s Englishmodel of the world
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Alt rdf:about="http://retailer.org/node"/>
</rdf:RDF>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Alt rdf:about="http://manuf.org/node"/>
</rdf:RDF>
negotiable semantic distance
negotiable semantic distance Manufacturer’s Englishmodel of the world
X semantic disconnects X
Ex 1: English semantics of ontology data
36
A retailer orders computers from a manufacturer -- facts
for the retailer the term PC for Gamers has super-class this-class in the this-ns namespace==================================================================
Computers to order retailerWorksts/Desktops sharedComputers shared
Ex 1: English semantics of ontology data
37
A retailer orders computers from a manufacturer -- facts
for the retailer the term PC for Gamers has super-class this-class in the this-ns namespace==================================================================
Computers to order retailerWorksts/Desktops sharedComputers shared
for the manufacturer the term Prof Desktop has super-class this-class in the this-ns namespace=====================================================================
Desktop manufacturerWorksts/Desktops sharedComputer Systems manufacturerComputers shared
Ex 1: English semantics of ontology data
38
A retailer orders computers from a manufacturer -- facts and a rule
for the retailer the term PC for Gamers has super-class this-class in the this-ns namespace==================================================================
Computers to order retailerWorksts/Desktops sharedComputers shared
for the manufacturer the term Prof Desktop has super-class this-class in the this-ns namespace=====================================================================
Desktop manufacturerWorksts/Desktops sharedComputer Systems manufacturerComputers shared
for the retailer the term some-item1 has super-class some-class in the some-ns namespacefor the manufacturer the term some-item2 has super-class that-class in the that-ns namespace----------------------------------------------------------------------------------------------------------------------the retailer term that-item1 and the manufacturer term that-item2 agree - they are of type that-class
-- To run or change this example, please point Firefox or Chrome to the demo SemanticResolution1 at www.executable-english.com
Ex 1: English semantics of ontology data
39
A retailer orders computers from a manufacturer -- answer table
this-result : retailer this-item1 is matched by manufacturer this-item2 on the property this-prop for part this-comp====================================================================================NEED PC for Gamers *missing-item* Size Graphics CardOK PC for Gamers Prof Desktop Size CPUOK PC for Gamers Prof Desktop Size MemoryOK PC for Gamers Prof Desktop Size Sound Card
-- To run or change this example, please point Firefox or Chrome to the demo SemanticResolution1 at www.executable-english.com
Ex 1: English semantics of ontology data
40
A retailer orders computers from a manufacturer -- explanation/proof of an answer
retailer PC for Gamers is matched by manufacturer Prof Desktop on the property Size for part Memory ------------------------------------------------------------------------------------------------------------------------------------OK : retailer PC for Gamers is matched by manufacturer Prof Desktop on the property Size for part Memory
-- To run or change this example, please point Firefox or Chrome to the demo SemanticResolution1 at www.executable-english.com
Ex 1: English semantics of ontology data
41
A retailer orders computers from a manufacturer -- explanation/proof of an answer
retailer PC for Gamers is matched by manufacturer Prof Desktop on the property Size for part Memory ------------------------------------------------------------------------------------------------------------------------------------OK : retailer PC for Gamers is matched by manufacturer Prof Desktop on the property Size for part Memory
the retailer term PC for Gamers and the manufacturer term Prof Desktop agree - they are of type Worksts/Desktops for the retailer the term PC for Gamers has part Memory with property Size >= 256 in the shared namespace for the manufacturer the term Prof Desktop has part Memory with property Size = 512 in the shared namespace = 512 meets the requirement >= 256 ----------------------------------------------------------------------------------------------------------------------------------------------retailer PC for Gamers is matched by manufacturer Prof Desktop on the property Size for part Memory
-- To run or change this example, please point Firefox or Chrome to the demo SemanticResolution1 at www.executable-english.com
Ex 1: English semantics of ontology data
42
A retailer orders computers from a manufacturer -- explanation/proof of an answer
retailer PC for Gamers is matched by manufacturer Prof Desktop on the property Size for part Memory ------------------------------------------------------------------------------------------------------------------------------------OK : retailer PC for Gamers is matched by manufacturer Prof Desktop on the property Size for part Memory
the retailer term PC for Gamers and the manufacturer term Prof Desktop agree - they are of type Worksts/Desktops for the retailer the term PC for Gamers has part Memory with property Size >= 256 in the shared namespace for the manufacturer the term Prof Desktop has part Memory with property Size = 512 in the shared namespace = 512 meets the requirement >= 256 ----------------------------------------------------------------------------------------------------------------------------------------------retailer PC for Gamers is matched by manufacturer Prof Desktop on the property Size for part Memory
for the retailer the term PC for Gamers has super-class Worksts/Desktops in the shared namespace for the manufacturer the term Prof Desktop has super-class Worksts/Desktops in the shared namespace --------------------------------------------------------------------------------------------------------------------------------------------the retailer term PC for Gamers and the manufacturer term Prof Desktop agree - they are of type Worksts/Desktops
-- To run or change this example, please point Firefox or Chrome to the demo SemanticResolution1 at www.executable-english.com
Ex 1: English semantics of ontology data
43
Retailer’s Englishmodel of the world
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Alt rdf:about="http://retailer.org/node"/>
</rdf:RDF>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Alt rdf:about="http://manuf.org/node"/>
</rdf:RDF>
negotiable semantic distance
negotiable semantic distance Manufacturer’s Englishmodel of the world
X semantic disconnects X
Ex 1: English semantics of ontology data
44
Retailer’s Englishmodel of the world
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Alt rdf:about="http://retailer.org/node"/>
</rdf:RDF>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Alt rdf:about="http://manuf.org/node"/>
</rdf:RDF>
negotiable semantic distance Manufacturer’s Englishmodel of the world
the retailer term PC for Gamers and the manufacturer term Prof Desktop agree -they are of type Worksts/Desktops
for the manufacturer the term Prof Desktop has part Memory with property Size = 512 in the shared namespace
English explanations bridge the semantic gap between people
and machines
Ex 1: English semantics of ontology data
negotiable semantic distance
45
Agenda• The World Wide Database vision
• Only experts have the skills to use the current tools
• An easier future for Semantic Technology -- combine:
– Semantics1 - Data Semantics = the current Technology
– Semantics2 - what a reasoner should do
– Semantics3 - Application Semantics = English meanings at the UI
• A browser-based system for writing and running applications in English
• Examples : Semantics of ontology data, and of oil-industry SQL data
• Google indexes and searches applications that are written in English
• Summary
46
Ex 2: English semantics of oil-industry SQL data
• A customer needs 1000 gallons of product y in October
• Products x and z can be substituted for product y, but only in the Fall
• Combine products x, y and z to fill the order
• Combination depends on:
• How much of each product is available from each refinery
• Available transportation from each refinery to the customer area
-- Example based on “Oil Industry Supply Chain Management Using English Business Rules Over SQL” by Ted Kowalski and Adrian Walker,www.executable-english.com/Oil_Industry_Supply_Chain_by_Kowalski_and_Walker.pdf
47
Ex 2: English semantics of oil-industry SQL data
estimated demand this-id in this-region is for this-quantity gallons of this-finished-product in this-month of this-year===================================================================================
523 NJ 1000 product-y October 2005
Facts:
48
Ex 2: English semantics of oil-industry SQL data
estimated demand this-id in this-region is for this-quantity gallons of this-finished-product in this-month of this-year===================================================================================
523 NJ 1000 product-y October 2005
Facts:
in this-season an order for this-product1 can be filled with the alternative this-product2==============================================================
Fall product-y product-xFall product-y product-z
49
Ex 2: English semantics of oil-industry SQL data
estimated demand this-id in this-region is for this-quantity gallons of this-finished-product in this-month of this-year===================================================================================
523 NJ 1000 product-y October 2005
Facts:
in this-season an order for this-product1 can be filled with the alternative this-product2==============================================================
Fall product-y product-xFall product-y product-z
in this-month the refinery this-name has committed to schedule this-amount gallons of this-product=======================================================================
October Shell Canada One 500 product-yOctober Shell Canada One 300 product-xOctober Shell Canada One 800 product-zOctober Shell Canada One 10000 product-w
50
Ex 2: English semantics of oil-industry SQL data
estimated demand this-id in this-region is for this-quantity gallons of this-finished-product in this-month of this-year===================================================================================
523 NJ 1000 product-y October 2005
Facts:
in this-season an order for this-product1 can be filled with the alternative this-product2==============================================================
Fall product-y product-xFall product-y product-z
in this-month the refinery this-name has committed to schedule this-amount gallons of this-product=======================================================================
October Shell Canada One 500 product-yOctober Shell Canada One 300 product-xOctober Shell Canada One 800 product-zOctober Shell Canada One 10000 product-w
we have this-method transportation from refinery this-name to region this-region==========================================================
truck Shell Canada One NJrail Shell Canada One NJ
51
Ex 2: English semantics of oil-industry SQL data Rules:
estimated demand some-id in some-region is for some-quantity gallons of some-finished-productin some-month of some-year
for estimated demand that-id some-fraction of the order will be some-product from some-refinerythat-quantity * that-fraction = some-amount------------------------------------------------------------------------------------------------------------------------------------------------for demand that-id that-region for that-quantity that-finished-product we use that-amount that-product from that-refinery
52
Ex 2: English semantics of oil-industry SQL data Rules:
estimated demand some-id in some-region is for some-quantity gallons of some-finished-productin some-month of some-year
for estimated demand that-id some-fraction of the order will be some-product from some-refinerythat-quantity * that-fraction = some-amount------------------------------------------------------------------------------------------------------------------------------------------------for demand that-id that-region for that-quantity that-finished-product we use that-amount that-product from that-refinery
estimated demand some-id in some-region is for some-quantity gallons of some-finished-product in some-month of some-year
for demand that-id for that-finished-product refinery some-refinery can supply some-amount gallons of some-productfor demand that-id the refineries have altogether some-total gallons of acceptable base productsthat-amount / that-total = some-long-fractionthat-long-fraction rounded to 2 places after the decimal point is some-fraction----------------------------------------------------------------------------------------------------------------for estimated demand that-id that-fraction of the order will be that-product from that-refinery
53
Ex 2: English semantics of oil-industry SQL data Rules:
estimated demand some-id in some-region is for some-quantity gallons of some-finished-productin some-month of some-year
for estimated demand that-id some-fraction of the order will be some-product from some-refinerythat-quantity * that-fraction = some-amount------------------------------------------------------------------------------------------------------------------------------------------------for demand that-id that-region for that-quantity that-finished-product we use that-amount that-product from that-refinery
estimated demand some-id in some-region is for some-quantity gallons of some-finished-product in some-month of some-year
for demand that-id for that-finished-product refinery some-refinery can supply some-amount gallons of some-productfor demand that-id the refineries have altogether some-total gallons of acceptable base productsthat-amount / that-total = some-long-fractionthat-long-fraction rounded to 2 places after the decimal point is some-fraction----------------------------------------------------------------------------------------------------------------for estimated demand that-id that-fraction of the order will be that-product from that-refinery
estimated demand some-id in some-region is for some-amount gallons of some-product in some-month of some-yearsum a-num :
for demand that-id for that-product refinery some-name can supply some-num gallons of some-product1 = a-total-------------------------------------------------------------------------------------------------------------------------for demand that-id the refineries have altogether that-total gallons of acceptable base products
54
Ex 2: English semantics of oil-industry SQL data
An answer table:
for demand this-id this-region for this-quantity this-finished-product we use this-amount this-product from this-refinery======================================================================================
523 NJ 1000 product-y 190.0 product-x Shell Canada One523 NJ 1000 product-y 310.0 product-y Shell Canada One523 NJ 1000 product-y 500.0 product-z Shell Canada One
To run or change this example, please point Firefox or Chrome to the demo Oil-IndustrySupplyChain1 at www.executable-english.com
55
Ex 2: English semantics of oil-industry SQL data An explanation:
estimated demand 523 in NJ is for 1000 gallons of product-y in October of 2005 for estimated demand 523 0.19 of the order will be product-x from Shell Canada One 1000 * 0.19 = 190 ------------------------------------------------------------------------------------------------------for demand 523 NJ for 1000 product-y we use 190 product-x from Shell Canada One
56
Ex 2: English semantics of oil-industry SQL data An explanation:
estimated demand 523 in NJ is for 1000 gallons of product-y in October of 2005 for estimated demand 523 0.19 of the order will be product-x from Shell Canada One 1000 * 0.19 = 190 ------------------------------------------------------------------------------------------------------for demand 523 NJ for 1000 product-y we use 190 product-x from Shell Canada One
estimated demand 523 in NJ is for 1000 gallons of product-y in October of 2005 for demand 523 for product-y refinery Shell Canada One can supply 300 gallons of product-x for demand 523 the refineries have altogether 1600 gallons of acceptable base products 300 / 1600 = 0.1875 0.1875 rounded to 2 places after the decimal point is 0.19 ------------------------------------------------------------------------------------------------------------------for estimated demand 523 0.19 of the order will be product-x from Shell Canada One
57
Ex 2: English semantics of oil-industry SQL data An explanation:
estimated demand 523 in NJ is for 1000 gallons of product-y in October of 2005 for estimated demand 523 0.19 of the order will be product-x from Shell Canada One 1000 * 0.19 = 190 ------------------------------------------------------------------------------------------------------for demand 523 NJ for 1000 product-y we use 190 product-x from Shell Canada One
estimated demand 523 in NJ is for 1000 gallons of product-y in October of 2005 for demand 523 for product-y refinery Shell Canada One can supply 300 gallons of product-x for demand 523 the refineries have altogether 1600 gallons of acceptable base products 300 / 1600 = 0.1875 0.1875 rounded to 2 places after the decimal point is 0.19 ------------------------------------------------------------------------------------------------------------------for estimated demand 523 0.19 of the order will be product-x from Shell Canada One
estimated demand 523 in NJ is for 1000 gallons of product-y in October of 2005 sum eg-amount :
for demand 523 for product-y refinery eg-refinery can supply eg-amount gallons of eg-product1 = 1600 ---------------------------------------------------------------------------------------------------------------------------------for demand 523 the refineries have altogether 1600 gallons of acceptable base products
To run or change this example, please point Firefox or Chrome to the demo Oil-IndustrySupplyChain1 at www.executable-english.com
58
Ex 2: English semantics of oil-industry SQL data
Rules for finding SQL data on the Internet:
we have this-method transportation from refinery this-name to region this-region==========================================================
truck Shell Canada One NJrail Shell Canada One NJ
A data table
url:www.example.com dbms:9i dbname:ibldb tablename:T1 port:1521 id:anonymous password:oracle-----------------------------------------------------------------------------------------------------------------------------------we have this-method transportation from refinery this-name to region this-region
A rule that says how to find the table on the internet
To run or change this example, please point Firefox or Chrome to the demo Oil-IndustrySupplyChain1 at www.executable-english.com
59
Programmer
Theory ofDeclarativeKnowledge
End User / Author
Writes Business Rules in open vocabulary English Directly into a browser
Runs the Rules Using the browser
Sees Englishexplanations of the Results
Who does research.Into the Semantic Web?
Semantics3
Semantics2
Ex 2: English semantics of oil-industry SQL data
InternetBusiness Logic
Application Independent
SQL
RDF
Semantics1
60
Ex 2: English semantics of oil-industry SQL data A SQL query generated automatically from the business rules:
select distinct x6,T2.PRODUCT,T1.NAME,T2.AMOUNT,x5 fromT6 tt1,T6 tt2,T5,T4,T3,T2,T1,T6,(select x3 x6,T6.FINISHED_PRODUCT x7,T6.ID x8,tt1.ID x9,tt2.ID x10,sum(x4) x5 fromT6,T6 tt1,T6 tt2,((select T6.ID x3,T3.PRODUCT1,T1.NAME,T2.AMOUNT x4,T2.PRODUCT fromT1,T2,T3,T4,T5,T6,T6 tt1,T6 tt2 whereT1.NAME=T2.NAME and T1.REGION=T6.REGION and T2.MONTH1=T4.MONTH1 andT2.MONTH1=T6.MONTH1 and T2.PRODUCT=T3.PRODUCT2 and T4.MONTH1=T6.MONTH1 andT3.PRODUCT1=T6.FINISHED_PRODUCT and T3.SEASON=T4.SEASON and T3.SEASON=T5.SEASON andT4.SEASON=T5.SEASON and T6.ID=tt1.ID and T6.ID=tt2.ID and tt1.ID=tt2.ID)union(select T6.ID x3,T2.PRODUCT,T1.NAME,T2.AMOUNT x4,T2.PRODUCT fromT1,T2,T3,T4,T5,T6,T6 tt1,T6 tt2 whereT1.NAME=T2.NAME and T1.REGION=T6.REGION and T2.MONTH1=T6.MONTH1 andT2.PRODUCT=T6.FINISHED_PRODUCT and T6.ID=tt1.ID and T6.ID=tt2.ID and tt1.ID=tt2.ID)) group by T6.FINISHED_PRODUCT,T6.ID,tt1.ID,tt2.ID,x3) whereT6.ID=tt2.ID and tt1.ID=T6.ID and T6.FINISHED_PRODUCT=x7 and T6.ID=x8 and tt1.ID=x8 andtt2.ID=x8 and T1.NAME=T2.NAME and T1.REGION=tt2.REGION and T2.MONTH1=T4.MONTH1 andT2.MONTH1=tt2.MONTH1 and T2.PRODUCT=T3.PRODUCT2 andT3.PRODUCT1=tt1.FINISHED_PRODUCT and T3.PRODUCT1=tt2.FINISHED_PRODUCT andT3.SEASON=T4.SEASON and T3.SEASON=T5.SEASON and T4.MONTH1=tt2.MONTH1 andT4.SEASON=T5.SEASON and T6.ID=x6 and tt1.FINISHED_PRODUCT=tt2.FINISHED_PRODUCT andtt1.ID=tt2.ID and tt1.ID=x6 and tt2.ID=x6order by x6,T2.PRODUCT,T1.NAME,T2.AMOUNT,x5;
61
Ex 2: English semantics of oil-industry SQL data
• It would be difficult to write the SQL query on the previous slide by hand, or to manually reconcile it with the business knowledge specified in the rules.
• How do we know that the automatically generated SQL yields results that are correct with respect to the business rules ?
The concern is eased by the fact that we can get step-by-step business level English explanations
62
Ex 2: English semantics of oil-industry SQL data
• Could a programmer write more readable SQL by hand ?
Yes, but we would need to add comments in English to help people to
reconcile the hand-written query with the business knowledge
By their nature, the comments would not be used during machine processing,
so the correctness of the hand written-SQL would rely on lengthy,
and perhaps error prone, manual verification
Comments are sometimes not kept up to date when the code that they
supposedly document is changed
63
Agenda• The World Wide Database vision
• Only experts have the skills to use the current tools
• An easier future for Semantic Technology -- combine:
– Semantics1 - Data Semantics = the current Technology
– Semantics2 - what a reasoner should do
– Semantics3 - Application Semantics = English meanings at the UI
• A browser-based system for writing and running applications in English
• Examples : Semantics of ontology data, and of oil-industry SQL data
• Google indexes and searches applications that are written in English
• Summary
64
Google indexes and searches applications that are written in English Search: for estimated demand that-id fraction of the order
65
Google indexes and searches applications that are written in English
Search: for estimated demand that-id fraction of the order
Result:
Search: for estimated demand that-id fraction of the order
66
Google indexes and searches applications that are written in English
Search: for estimated demand that-id fraction of the order
Result:
Search: for estimated demand that-id fraction of the order
The executable English rulesand facts that define the application
A paper that describesthe application
67
Summary • The World Wide Database vision
– all the data in the world as one database
• Only experts have the skills to use the current tools
– OwlResearchOnt -- Bob does research into Semantic Web
• An easier future for Semantic Technology -- combine:
– Semantics1 - Data Semantics = the current Technology
– Semantics2 - what a reasoner should do
– Semantics3 - Application Semantics = English meanings at the UI
• A browser-based system for writing and running applications in English
• Examples : Semantics of ontology data, and of oil-industry SQL data
• Google indexes and searches applications that are written in English
68
1. The NIST / UMBC paper listed in the presentation can be downloaded from : http://www.mel.nist.gov/msidlibrary/publications.html
2. What a reasoner should do:Backchain Iteration: Towards a Practical Inference Method that is Simple Enough to be Proved Terminating, Sound and Complete. Journal of Automated Reasoning, 11:1-22.
3. The English inferencing examples OwlResearchOntSemanticResolution1Oil-IndustrySupplyChain1Oil-IndustrySupplyChain1MySql1
(and many other examples provided) can be run, changed, and re-run as follows:1. Point Internet Explorer 6, Netscape 7, Firefox or Mozilla to www.executable-english.com2. Click on Internet Business Logic3. Click on the GO button4. Click on the Help button to see how to navigate through the pages5. Select OwlResearchOnt
4. You are cordially invited to write and run your own examples. Shared use of the system is free.
Links
69
About the Author• Author of over 20 papers, and an Addison-Wesley book, on business rule
systems and databases
• Assistant Professor at Rutgers University
• Manager of Principles and Applications of Logic Programming, IBM
Yorktown Research Laboratory
• Manager, Internet Development at Eventra
(a manufacturing supply chain company)