+ All Categories
Home > Documents > Proof System

Proof System

Date post: 01-Jan-2016
Category:
Upload: velma-cardenas
View: 17 times
Download: 0 times
Share this document with a friend
Description:
Proof System. HY-566. Proof layer. N ext layer of SW is logic and proof layers. allow the user to state any logical principles, computer can to infer new knowledge by applying these principles on the existing data. - PowerPoint PPT Presentation
Popular Tags:
29
Proof System HY-566
Transcript
Page 1: Proof System

Proof System

HY-566

Page 2: Proof System

Proof layer

Next layer of SW is logic and proof layers. – allow the user to state any logical principles,– computer can to infer new knowledge by applying

these principles on the existing data.

This project implements a defeasible reasoning system which presents explanations to users for the answers to their queries.

Page 3: Proof System

Defeasible Logic

A defeasible theory is a triple (F, R, >)– F is a set of literals (called facts)– R a finite set of rules– > a superiority relation on R

Two kind of rules– Strict rules (A→P) can’t be defeated– Defeasible rules (A=>P) can be defeated

Page 4: Proof System

Defeasible Logic Metaprogram

Simulates the proof theory of defeasible logic contains clauses :– denite provability– defeasible provability– When rule is blocked/unblocked – When rule is defeated/undefeateds

Page 5: Proof System

Explanation Example

An e-shop tell to Bob’s that he owns 30$ Explanation (facts and rules):

– purchase(Bob,DVD) - fact

– price(DVD,30) - fact– delivered(DVD,Bob) - fact– purchase(Bob,DVD), price(DVD,30),

delivered(DVD,Bob) → owes(Bob,30) - rule

Page 6: Proof System

Extension of RULML

RuleML is an XML based language that supports rule representation for the Semantic Web.

A new XML schema, extension of RuleML, is proposed for explanation representation in defeasible logic

Page 7: Proof System

Ext. RULML - Atom, Fact

Atom: operator, var or const, optionaly NOT <Atom>

<Not>

<Op> rich </Op>

<Ind> Bob </Ind>

</Not>

</Atom>

A Fact is consisted by an Atom that comprise a certain knowledge

Page 8: Proof System

Ext. RULML - Rules

Strict - Defeasible Rules. – Head: is an Atom – Body: number of Atoms

<Defeasible_rule Label="r1"> <Head> <Atom> <Op> rich </Op> <Ind> Bob </Ind> </Atom> </Head>

<Body> <Atom> <Op> wins_lotto </Op> <Ind> Bob </Ind> </Atom> </Body></Defeasible_rule>

Page 9: Proof System

Ext. RULML - Explanations

Definitely Provable Explanations– Denote the Atom– Definite Proof

Definite Proof– Fact for that Atom– Strict Rule with Head the Atom and Body

(multiple) atoms that must be proved definitely.

Page 10: Proof System

Explanations Example

<Definitely_provable><Atom> <Op> rich </Op> <Ind> Bob </Ind></Atom><Definite_Proof> <Strict_rule Label="r1"> <Head>

<Atom> <Op> rich </Op> <Ind> Bob </Ind>

</Atom> </Head> <Body> <Atom> <Op> wins_lotto </Op>

<Ind> Bob </Ind> </Atom> </Body> </Strict_rule>

<Definitely_provable> <Definite_Proof> <Fact>

<Atom> <Op> wins_lotto

</Op> <Ind> Bob </Ind>

</Atom> </Fact> </Definite_Proof> </Definitely_provable></Definite_Proof>

</Definitely_provable>

Page 11: Proof System

Proof tree construction (1/3)

The foundation of the proof system – Prolog metaprogram implements rules of Defeasible Logic– The trace of the XSB implementation of prolog

XSB: logic programming engine used to run the metaprogram.

To communicate with the XSB the invocation of the XSB executable was used (Javas exec method)

– Send commands to the XSB interpreter – Receive the output that was produced as an effect.

Load the metaprogram and the defeasible theory

Page 12: Proof System

Proof tree construction (2/3)

Load the metaprogram and the defeasible theory

At the evaluation of a query XSB will print a message each time a predicate is:– Initially entered (Call)– Successfully returned from (Exit),– Failed back into (Redo), and– Completely failed out of (Fail).

Page 13: Proof System

Proof tree construction (3/3)

A tree whose nodes are traced predicates is constructed by the Java XSB invoker when trace is parsed.

Each node has information– A string for the predicates name– The predicates arguments– Whether it was found to be true (Exit) or false

(Fail)– Whether it was failed back into (Redo)– Boolean attribute tells if predicate is negated.

Page 14: Proof System

Why the tree needs pruning?

XSB trace contains data not needed for proof – A metaprogram to translate the DL into logic

programming is used. Additional clauses are needed which add information to trace

– Prolog shows successful and unsuccessful paths

The tree produced by the XSB trace is built according to the metaprogram structure but the final tree needs to be compliant with the XML schema

Page 15: Proof System

Pruning Rules

Heuristic rules are used in order to prune the proof tree

According to the truth value and the type of the root node we may want to maintain– only successful paths– only failed paths – combinations of them.

Page 16: Proof System

Pruning Motivation Example1

Suppose we have the following defeasibly theory translated in logic programming as:– fact(a).– fact(e).– defeasible(r1,b,a).– defeasible(r2,b,e).– defeasible(r3,~(b),d).

Page 17: Proof System

Example1: Defeasible provability of b

Pruned

Page 18: Proof System

Example1: Defeasible provability of b

We are interested in successful (True) paths The pruning algorithm removes

– the subtree with the false goal to prove that b is denitely provable

– the false predicate to find a strict supportive rule for b

– the metaprogram additional negation clause.

Page 19: Proof System

Pruning Motivation Example2

Suppose we have the following defeasibly theory translated in logic programming as:– fact(a).– defeasible(r1,b,a).– defeasible(r2,~(b),a).

Page 20: Proof System

Example2: Defeasible provability of b

We are interested in unsuccessful paths and the pruning algorithm keeps the initial proof tree.

Page 21: Proof System

Pruning resume

The proof tree after using the heuristic techniques is similar to an explanation derived by the use of pure DL

Drawback: heuristics are fully dependent on the metaprogram. – Changes at metaprogram => changes at pruning

implementation.

Page 22: Proof System

Pruning Example

The marked rule is pruned

Page 23: Proof System

Pruning Example 2

The marked rule is pruned

Page 24: Proof System

Agent Interface to the Proof System

The system makes use of two kinds of agents– 'Agent' which issues queries– 'Main Agent' which is responsible to answer the

queries. Both agents are based on JADE (Java Agent

DEvelopment Framework) – a software framework to develop agent-based

applications

Page 25: Proof System

Process to answer a query (1/3)

MainAgent

XSB

XML Writter

Invoker

Pruner

Agent

2) Predicate 1)Question3) Predicate

4) result trace

5) result tree

7) Pruned result6) result tree

8) Pruned result 9) XML proof

10) answer or proof

Page 26: Proof System

Process to answer a query (2/3)

1. An agent issues a query to the Main Agent.- predicate::(proof|answer)

2. Main Agent sends Predicate to the Invoker– Invoker is responsible to communicate with XSB

3. Invoker executes the Predicate.

4. XSB returns the full result trace.

5. Invoker returns result tree to Main Agent.

6. Main Agent sends result tree to the Pruner

Page 27: Proof System

Process to answer a query (3/3)

7. Pruner returns pruned result to Main Agent.8. Main Agent sends the pruned result to the

XML writer (only if proof requested)9. XML writer returns the XML Proof.10. Main Agent returns Answer or Proof

- ANSWER(true | false)- PROOF:(proof string)- ERROR:(error message)

Page 28: Proof System

Visual Agent

Page 29: Proof System

Command Line Agent

Reads in a random way the questions from a configuration file

Sends the question to the Main Agent with the order read

The format of the questions is of the form – predicate::(proof|answer)

The answers and proofs are stored at a files


Recommended