From ae8779ef8368f68c30ee825a098eb289769f9f4c Mon Sep 17 00:00:00 2001 From: Simon Brooke Date: Sat, 25 Apr 2020 13:25:26 +0100 Subject: [PATCH] More on propositions and knowledge representation --- doc/Bialowieza.md | 180 ++++++++++++++++++-- doc/PredicateSubtext.md | 39 ----- docs/codox/AgainstTruth.html | 2 +- docs/codox/Analysis.html | 2 +- docs/codox/Arboretum.html | 2 +- docs/codox/Arden.html | 2 +- docs/codox/BatesonKammerer.html | 2 +- docs/codox/Bialowieza.html | 98 ++++++++++- docs/codox/Errata.html | 2 +- docs/codox/Experience.html | 2 +- docs/codox/HegemonicArgument.html | 2 +- docs/codox/History.html | 2 +- docs/codox/HuxleyKropotkin.html | 2 +- docs/codox/Implementing.html | 2 +- docs/codox/JAccuse.html | 2 +- docs/codox/KnacqTools.html | 2 +- docs/codox/Manifesto.html | 2 +- docs/codox/OnHylasAndPhilonus.html | 2 +- docs/codox/TheProblem.html | 2 +- docs/codox/index.html | 2 +- docs/codox/intro.html | 2 +- docs/codox/wildwood.advocate.html | 2 +- docs/codox/wildwood.bialowieza.html | 2 +- docs/codox/wildwood.caesar.html | 2 +- docs/codox/wildwood.dengine.engine.html | 2 +- docs/codox/wildwood.dengine.node.html | 2 +- docs/codox/wildwood.knowledge-accessor.html | 2 +- docs/codox/wildwood.mongo-ka.html | 2 +- docs/codox/wildwood.schema.html | 2 +- 29 files changed, 282 insertions(+), 87 deletions(-) delete mode 100644 doc/PredicateSubtext.md diff --git a/doc/Bialowieza.md b/doc/Bialowieza.md index 6a05f80..52d673c 100644 --- a/doc/Bialowieza.md +++ b/doc/Bialowieza.md @@ -10,23 +10,50 @@ Bialowieza is the second iteration of the Wildwood engine, and this following co The current motivation for restarting work on Wildwood is to provide non-player characters in a game world with sufficient intelligence that they can enter into meaningful unscripted conversations about objects and events in that world. -## Major components of Bialowieza +## Knowledge representation -### Knowledge Accessors +It's my intention that knowledge will be represented in Bialowieza not as Features, as were used in Arboretum, but as propositions, and in this section I intend to state what I mean by a proposition. -The `wildwood.knowledge-accessor/Accessor` protocol defines a bidirectional transducer which can fetch data from whatever storage representation the calling application uses into the representation defined by `wildwood.schema`. +### On propositional and predicate calculi -### Advocates +But firstly I should be clear that Bialowieza does *not* represent a propositional calculus. On the contrary, Arboretum, which dealt with features, is a propositional calculus. How so? -The `wildwood.advocate/Advocate` protocol describes an agent which can take part in decision processes. +A feature, in Arboretum, was a one-position predicate; an example would be, 'is a widow'. Propositions were (in effect) constructed by applying that predicate to the case. Thus, suppose we were considering the case of someone called Calpurnia, the feature 'is a widow' expands to the proposition 'Calpurnia is a widow'; and this proposition is, to Arboretum, atomic. -### The engine itself +Thus Arboretum can reason about whether Calpurnia is a widow. It can have a rule (and indeed, did have a rule) which says -The engine is implemented by the namespace `wildwood.bialowieza`. + if + is a woman, and + has been married, and + husband is dead + then + is a widow + unless + was divorced, or + has remarried. + +The features are given as predicates, because all must apply to the same subject; expanding them to propositions gives us, in this case + + if + Calpurnia is a woman, and + Calpurnia has been married, and + Calpurnia's husband is dead + then + Calpurnia is a widow + unless + Calpurnia was divorced, or + Calpurnia has remarried. + +However, another proposition about a claimant that might have been been interesting to an adjudicating officer might be 'is a widowed mother'. One might define that in common sense terms as + + if + Calpurnia is a widow, and + there exists some person whose mother is Calpurnia, and + that person is still a child + then + Calpurnia is a widowed mother -### Inference processes -Advocates are entitled to use whatever inference processes they like, but they have access to `wildwood.dengine`, which is an implementation of the DTree engine described in the chapter on [Arboretum](Arboretum.html) adapted to propositions as defined in `wildwood.schema`. ### Propositions @@ -84,7 +111,7 @@ Recall that in the chapter on Arboretum I observed that [the working of the DTre { **TODO**: investigate how this notion of a proposition - and a Toulmin structure - relates to situation semantics; especially, consider how locating a proposition in time and space captures the notion of a situation. } -#### Are located two-position propositions sufficient? +### The located proposition Aristotle's propositions are essentially two position: they describe a relationship between two entities, a subject and an object. But they're not located. @@ -109,9 +136,11 @@ But if we say 3. Dagger1 caused Wound1 in the Forum on the Ides of March 4. Caesar died of Wound1 in the Forum on the Ides of March -then provided the atomicity of our notions of time and space is sufficiently fine, we're getting pretty close. +then provided the atomicity of our notions of time and space is sufficiently fine, we're getting pretty close. Adding a notion of location to propositions leads to the notion of an event, a small bundle or ball of time and space which gives them context; and we can reason with this. -Adding a notion of location to propositions leads to the notion of an event, a small bundle or ball of time and space which gives them context; and we can reason with this. +The size of an event is, of course, a slightly slippery notion. The inference that Caesar died (at least partly) from the blow struck by Brutus is only possible if the envelope of the event is fairly small - no more than a few metres, no more than a few minutes. But if we replace Dagger1 with Rifle1 then the spatial extent of the event can be considerable expanded; and if it's LandMine1, then the temporal aspect similarly so. + +### Are located two-position propositions sufficient? The reason I like the idea of investigating whether located two position propositions are sufficient is that a very regular knowlege representation is easy to compute over. The reason I think it might not be is this: @@ -133,12 +162,113 @@ Writing it down like that, it kind of works, but I'm not yet wholly persuaded. I As an exercise for the reader, how would we represent 'Dirck, Joris and I carried the good news from Ghent to Aix' using only located two position propositions? It feels, as I said, clumsy. -There is, of course, also a lurking combinatorial explosion here. If for each proposition which is learned, two further propositions must be learned as warrant for the first proposition, the world blows up. In an ideal platonic world we may indeed have turtles all the way down, but in a finite machine we need to say, arbitrarily but ruthlessly, that some classes of proposition will be stored unwarranted. +There is, of course, also a lurking combinatorial explosion here. If for each proposition which is learned, two further propositions must be learned as warrant for the first proposition, the world blows up. In an ideal platonic universe we may indeed have turtles all the way down, but in a finite machine we need to say, arbitrarily but ruthlessly, that some classes of proposition will be stored unwarranted. -#### Learning, consistency and confidence +### The event is (like) a situation -{ **TODO**: if we receive a new proposition which confirms a proposition we already know, our confidence in both increases. If we learn a new one which contradicts one we already know, our confidence in both decreases. Expand! -} +I would draw the reader's attention, here, to the similarity between the notion of an event, discussed above, and the [notion of a situation](Analysis.html#towards-a-situation-semantic-account-of-explanation), as discussed by Barwise & Perry. In particular, I'd like to draw attention to similarity between the account I've given of how Drusilla's belief that Brutus killed Caesar is warranted by + +* P2 := 'Calpurnia uttered P1 at E1.' +* P3 := 'Drusilla heard P1 at E1.' + +and the account of explanation as a situation E defined: + + E := at I1: understands, a, c; no + understands, b, c; yes + enquirlng, a; yes + addressing, a, b; yes + saying, a, q; yes + subject, q, c; yes + + at I2: responding, b, q; yes + addressing, b, a; yes + saying, b, u; yes + subject, u, c; yes + + at I3: understands, a, c; yes + understands, b, c; yes + + I1 < I2 < I3 + +where: a, b are some actors; c is some concept; q, u are some +utterances. + +Explicitly: + +* Drusilla => **a** +* Calpurnia => **b** +* P1 => **c** +* E1 => **I2** + +I'd argue that these are clearly very similar. + +My schema does not specify that "at I1: ... understands, a, c; no", but there's a reason for that. + +### Learning, consistency and confidence + +Let us suppose that Drusilla already knows the proposition that + +* Brutus killed Caesar in Rome in March. + +Calpurnia now tells her that + +* Brutus killed Caesar in the Forum on the Ides of March. + +The two accounts are compatible; this compatibility migh be represented, if you choose, by two further propositions: + +* P4 The Forum is within Rome. +* P5 The Ides of March is within March. + +Philosophers, after Plato, very often argue as though they inhabited ideal universes in which every agent always tells the truth, but the real world is not like that. For any person, there are few other people that that person trusts implicitly. The very notion that we need a warrant for a belief is an explicit recognition of the fact that knowledge is imperfect. + +So (unless she witnessed it herself, in which case you'd expect her to have more precise information), Drusilla does not *know*, in a strong sense, that Brutus killed Caesar in Rome in March. She has some degree of confidence in that proposition, which is likely to be less than perfect. + +When she learns from Calpurnia that Brutus killed Caesar in the Forum on the Ides of March, because the two claims are compatible, her confidence in each is likely to increase. + +By contrast, if Falco then says 'No, I heard from Gaius that it happened in April', then that casts doubt on both the first two claims - but also on this new claim. Because the claims are not compatible, they can't all be right. + +For the time being, I'm going to leave the issue of how confidence is derived and adjusted as an implementation detail; I don't - yet, at any rate - have an account of how this should work that I can defend. However, there's one further significant point to make about propositions before we move on. + +### On the subtext of propositions + +Propositions are not atomic. They do not come single spies, but freighted +with battalions of inferable subtexts. Suppose Calpurnia says + +* Brutus killed Caesar in Rome during the ides of March + +I learn more than just that 'Brutus killed Caesar in Rome during the +ides of March'. I also learn that + +* Brutus is a killer +* Caesar has been killed +* Rome is a place where killings happen +* The Ides of March are a time to be extra cautious + +Suppose Cassius now says + +* Longus killed Caesar in Rome during the ides of March + +this may cast some doubt on Calpurnia's primary claim, and on the belief that +Brutus is a killer. It doesn't rule it out - the accounts are compatible - but it +certainly doesn't confirm it. However it does reinforce the beliefs that + +* Caesar has been killed +* Rome is a place where killings happen +* The ides of March are a time to be extra cautious. + +If Falco then says + +* No, I heard from Gaius that it happened in April + +the beliefs that + +* Caesar has been killed +* Rome is a place where killings happen + +are still further strengthened. + +In proposing a formalism to express propositions, we need to consider how +it allows this freight to be unpacked. #### Proposition minimisation @@ -178,6 +308,24 @@ This means that every implementation of the `wildwood.knowledge-accessor/Accesso protocol must transduce whatever token its backing store uses as the primary key for an object to `:id` when it performs a `fetch` operation. +## Major components of Bialowieza + +### Knowledge Accessors + +The `wildwood.knowledge-accessor/Accessor` protocol defines a bidirectional transducer which can fetch data from whatever storage representation the calling application uses into the representation defined by `wildwood.schema`. + +### Advocates + +The `wildwood.advocate/Advocate` protocol describes an agent which can take part in decision processes. + +### The engine itself + +The engine is implemented by the namespace `wildwood.bialowieza`. + +### Inference processes + +Advocates are entitled to use whatever inference processes they like, but they have access to `wildwood.dengine`, which is an implementation of the DTree engine described in the chapter on [Arboretum](Arboretum.html) adapted to propositions as defined in `wildwood.schema`. + ## Thoughts on the shape of a knowledge base The object of building Bialowieza as a library is that we should not constrain diff --git a/doc/PredicateSubtext.md b/doc/PredicateSubtext.md deleted file mode 100644 index 045ae38..0000000 --- a/doc/PredicateSubtext.md +++ /dev/null @@ -1,39 +0,0 @@ -# On the subtext of a predicate - -Predicates are not atomic. They do not come single spies, but freighted -with battalions of inferable subtexts. Suppose Anthony says - - Brutus killed Caesar in Rome during the ides of March - -I learn more than just that 'Brutus killed Caesar in Rome during the -ides of March'. I also learn that - -- Brutus is a killer -- Caesar has been killed -- Rome is a place where killings happen -- The ides of March are a time to be extra cautious - -Suppose Drusilla now says - - Longus killed Caesar in Rome during the ides of March - -this casts doubt on Anthony's primary claim, and on the belief that -Brutus is a killer; but it reinforces the beliefs that - -- Caesar has been killed -- Rome is a place where killings happen -- The ides of March are a time to be extra cautious. - -If Falco then says - - No, I heard from Gaius that it happened in April - -the beliefs that - -- Caesar has been killed -- Rome is a place where killings happen - -are still further strengthened. - -In proposing a formalism to express predicates, we need to consider how -it allows this freight to be unpacked. diff --git a/docs/codox/AgainstTruth.html b/docs/codox/AgainstTruth.html index b57928d..1c521d8 100644 --- a/docs/codox/AgainstTruth.html +++ b/docs/codox/AgainstTruth.html @@ -1,6 +1,6 @@ -Against Truth

Against Truth

+Against Truth

Against Truth

Simon Brooke

“Hey, what IS truth, man?” Beeblebrox, Z, quoted in [Adams, 1978]

diff --git a/docs/codox/Analysis.html b/docs/codox/Analysis.html index d387c6b..192846f 100644 --- a/docs/codox/Analysis.html +++ b/docs/codox/Analysis.html @@ -1,6 +1,6 @@ -Analysis

Analysis

+Analysis

Analysis

Accounts from the Philosophy of Science

(Towards another chapter. What l want to do is: ,

    diff --git a/docs/codox/Arboretum.html b/docs/codox/Arboretum.html index dd478ba..439b2c5 100644 --- a/docs/codox/Arboretum.html +++ b/docs/codox/Arboretum.html @@ -1,6 +1,6 @@ -Arboretum

    Arboretum

    +Arboretum

    Arboretum

    This chapter describes briefly an inference mechanism, implemented in the Arboretum prototype; this is included here to show the results achieved in the author’s early work on explanation, on which it is hoped to build in the current work. A fuller description of this mechanism, and of the Arboretum prototype, will be found in [Mott & Brooke 87], from which this chapter is largely drawn.

    Arboretum was written in InterLisp-D[4] using LOOPS [5] object oriented facilities, to allow people to manipulate DTree structures through graphical representations: to build arbitrarily large knowledge bases, to use these to provide answers to questions about objects in domains admitting incomplete information - and to provide natural language explanations of these answers. The inference process by which answers are produced is shown as an animated graph. The user can ask the system how the value of any particular feature was arrived at, and what that value was. . It was developed for the Alvey DHSS Large Demonstrator Project, and sought to meet early perceptions of the needs of DHSS Adjudication Officers. Adjudication Officers decide claimants’ eligibility over a wide range of welfare benefits. There is a very large volume of work to be done, so they work under considerable pressure.

    The Adjudication process within the DHSS has its own levels of authority culminating in the

    diff --git a/docs/codox/Arden.html b/docs/codox/Arden.html index 0d3474f..5bb81df 100644 --- a/docs/codox/Arden.html +++ b/docs/codox/Arden.html @@ -1,6 +1,6 @@ -Arden

    Arden

    +Arden

    Arden

    Why Arden?

    It was something of tradition in the InterLisp-D community to give successive versions of a project codenames with successive alphabetical initials. So the first version would have a name starting ‘A’, the second ‘B’, and so on. The first prototype for Wildwood was called ‘Arden’, because it starts with an ‘A’, and because it is a fantastical dream-like forest depicted in Shakespeare’s play ‘As You Like It’, which if I recall correctly was performed as a promenade performance by the Duke’s Theatre in Lancaster in that year. While Arboretum - that carefully tended garden of trees - had been, as I’ve said, largely Peter’s in concept, Wildwood would be mine.

    Background

    diff --git a/docs/codox/BatesonKammerer.html b/docs/codox/BatesonKammerer.html index 35607eb..59a65ce 100644 --- a/docs/codox/BatesonKammerer.html +++ b/docs/codox/BatesonKammerer.html @@ -1,4 +1,4 @@ -The Bateson / Kammerer debate

    The Bateson / Kammerer debate

    +The Bateson / Kammerer debate

    The Bateson / Kammerer debate

    { TODO: analyse the style and motivations of the Bateson / Kammerer debate, drawing out the use of polemic and rhetoric to achieve hegemony }

    \ No newline at end of file diff --git a/docs/codox/Bialowieza.html b/docs/codox/Bialowieza.html index fb7df27..cccf5ea 100644 --- a/docs/codox/Bialowieza.html +++ b/docs/codox/Bialowieza.html @@ -1,6 +1,6 @@ -Bialowieza

    Bialowieza

    +Bialowieza

    Bialowieza

    { this chapter is in active development; quite a lot of the technical detail in this chapter at present will probably end up in Implementing, while additional high level and conceptual design, as it develops, will be here. }

    Why Bialowieza?

    Bialowieza is the second iteration of the Wildwood engine, and this following convention its name should start with ‘B’. Białowieża is Europe’s last great wild wood, and it is currently under threat.

    @@ -53,7 +53,7 @@

    So what, then, is an ‘argument structure’, as described above? It seems to me that it may be exactly a proposition, with the special feature that the value of the :data key is not minimised.

    Recall that in the chapter on Arboretum I observed that the working of the DTree decision algorithm caused precisely those nodes to be collected whose fragments which provided the most relevant explanation to support the decision, in a natural sequence from the general to the particular. I believe that precisely the same fortuitous alchemy will provide the argument structure to provide Toulmin’s D - out :data term. The DTree itself then becomes the W - the :warrant; and the author of the DTree becomes the :authority.

    { TODO: investigate how this notion of a proposition - and a Toulmin structure - relates to situation semantics; especially, consider how locating a proposition in time and space captures the notion of a situation. }

    -

    Are located two-position propositions sufficient?

    +

    The located proposition

    Aristotle’s propositions are essentially two position: they describe a relationship between two entities, a subject and an object. But they’re not located.

    Thus:

      @@ -75,8 +75,9 @@
    • Dagger1 caused Wound1 in the Forum on the Ides of March
    • Caesar died of Wound1 in the Forum on the Ides of March
-

then provided the atomicity of our notions of time and space is sufficiently fine, we’re getting pretty close.

-

Adding a notion of location to propositions leads to the notion of an event, a small bundle or ball of time and space which gives them context; and we can reason with this.

+

then provided the atomicity of our notions of time and space is sufficiently fine, we’re getting pretty close. Adding a notion of location to propositions leads to the notion of an event, a small bundle or ball of time and space which gives them context; and we can reason with this.

+

The size of an event is, of course, a slightly slippery notion. The inference that Caesar died (at least partly) from the blow struck by Brutus is only possible if the envelope of the event is fairly small - no more than a few metres, no more than a few minutes. But if we replace Dagger1 with Rifle1 then the spatial extent of the event can be considerable expanded; and if it’s LandMine1, then the temporal aspect similarly so.

+

Are located two-position propositions sufficient?

The reason I like the idea of investigating whether located two position propositions are sufficient is that a very regular knowlege representation is easy to compute over. The reason I think it might not be is this:

Suppose Calpurnia told Drusilla that Brutus killed Caesar in the Forum on the Ides of March. For simplicity, let’s call