[topicmapmail] Inheriting Scope
Murray Altheim
m.altheim@open.ac.uk
Mon, 18 Apr 2005 04:22:09 +0100
Steven Hammond wrote:
> Let me know if I'm pestering too much. I don't have a knowledge
> representation background, but I've been reading everything I can find
> on topic maps and XTM for a few weeks now and I'm just getting to the
> point where I can start asking questions and putting the pieces
> together. This discussion is really pulling a lot of pieces together for me.
Good -- I was wondering if I wasn't just further clouding the waters
or not. No, I don't feel pestered. You're a great distraction from
the paper I should be writing. If I smoked, I'd be out on the balcony.
Maybe I could see about that mermaid netsuke on eBay...
> Murray Altheim wrote:
>
>>Understood. In some circles within the knowledge representation community
>>there are those who make a tight distinction between a "schema" and a
>>"knowledge base." Those people would consider what you're calling a
>>"generic map" as a schema, as it would have no Topics referring to
>>specific
>>instances of its Topics. For example, one would define "Character" but
>>not
>>contain any actual character Topics -- these would all be stored within
>>the "knowledge base."
>
> Ok, I've been using template because the theoretical users of my
> application understand document templates, like for Word or OpenOffice
> and schema might get confused with XML schema. But it is a schema. It
> seemed natural to me to separate the schema from the specific instances.
> I do see that it is one context in the complete map.
Oh, I don't have a problem with the use of the term. I think in the
Topic Map community most of us have used "template" to refer to a
single template for an association, not in any larger sense. So
"schema" would be a collection of Topics-defining-PSIs (if we want
to share with others) and a set of Association templates. As I said
before, there just doesn't happen to be a standardized way of
establishing the latter. I have a way in Ceryle, but it probably
doesn't match the way it's done in other tools.
I say "Topics-defining-PSIs," because sometimes it's important to
explicitly state which Topics in an exchanged XTM document are
meant to be stable and useful as "published" subject indicators.
There may be temporary or utility Topics that are distinctly
meant by an author *not* to be stable and exchange-able, or an
author might state that *all* Topics in an exchanged XTM document
are meant as PSIs. In my own work, I have created small, specific
sets (such as one for Faceted Classification, containing about a
half dozen PSIs), but because I am distributing a base ontology
with my application, almost all of the Topics in the upper and
middle ontologies (again, absent the utility Topics) might be
considered as stable PSI Topics. Then again, for a different
purpose, say trying to simulate some of my application's behaviours
such as node color or position, somebody might want to use those
Topics. So I think to some degree what is or isn't a PSI might be
dependent upon content, hence we might decide to use scope to
determine which Topics are part of a given PSI set. Or include
each set as members in an Association whose purpose is to compose
that set.
>>I myself don't find this distinction particularly useful, as the
>>distinction
>>is itself simply one form of context within a potentially recursive graph
>>of contexts. I don't personally use OCML, the language primarily used in
>>the Knowledge Media Institute, but part of what was controversial about
>>it (back in the late 80s and early 90s) was that it freely mixed instance
>>terms within the ontology. Enrico Motta told me he saw no reason to
>>exclude
>>the things he was modelling from the ontology -- they were literally the
>>things he was modelling -- so they were simply included in the ontology.
>>There is apparently little or no distinction made between a schema and a
>>knowledge base in OCML.
>>
>>I'm not suggesting you're wrong in using scope this way, but it is
>>a novel approach. I feel like I've implemented a template-usage
>>scenario that provides the basic functionality you're talking about,
>>and I haven't had to resort to scope to do that. I tend to think of
>>scope as a synonym for "context."
>
> This is where I'm a little confused. I'm also using scope as a synonym
> for context. I'm envisioning an application where I can select a topic
> and study its relationship in a variety of contexts: social or
> geographic or other to be defined. The "lives-in" shares a context with
> all other geographical associations. I guess the OO programmer in me
> just doesn't want to make it explicit everytime a "lives-in" association
> is specified; so my thought was to make a supertype that carried the
> scope (contextual) information. But your saying that associations are
> always explicit, topics can be more or less explicit.
As I said, I don't think you're wrong, you're just using a different
modeling approach than I've been using. I've tended to avoid scoping
for the purposes of the base ontology, as I think of all of those
Topics and Associations as kinda living in one big scope, of the
ontology itself, reserving scoping for my instances, my "knowledge
base." But there is certainly no reason why this must be so. There's
actually a few scoped Associations in my middle ontology, but when
I think about it, they're even there more as examples, such as
Moby Dick is a whale in a fictional context.
where "in a fictional context" is a Topic being used to scope the
"is a" whale Association, the predicate of this sentence.
As for that OO thing, in XTM you simply have to express the Association
type, and each of the role types, if you want to be expressing a fully-
described relation. We made those things optional in the syntax, but
an underspecified Association is simply that. If one has a marriage
but the bride and groom roles are specified, heck, we have to begin
to ask who wears the pants in the family. Sorry. I sometimes get a
kick out of being stupid. Usually it involves alcohol; tonight it's
overtiredness and the ability to write these emails rather than work
on a paper I should be writing whose topic is essentially a great
deal of what we've been talking about. If only I could cut and paste...
>>Ah, sorry. You might want to glance through the XTM 1.0 Specification
>>before we go on too much further. PSIs, or Published Subject Indicators,
>>are simply Topics that we have decided are to be used as stable
>>indicators for Topics we wish to exchange with others. For example,
>>Kal Ahmed has published a set of PSIs for taxonomies. If you and I
>>were to both use those PSIs (by referencing their URLs as subject
>>indicators) when building our taxonomies, we could then interchange
>>them. Here's a ref to the place in the XTM spec:
>>
>> http://www.topicmaps.org/xtm/1.0/#desc-psis
>
> I've read it, but I'm still making sense of it. PSI's weren't referenced
> in any of the examples I've seen and I didn't really get them until just
> now. Seems as we both have applications that relating writing we could
> define a set of PSI's for writing concepts. This would make our maps
> more interchangeable because we agree on vocabulary. Is there a resource
> that collects the PSI's that have been defined?
I don't know if you've played with LTM, but it's a bit easier to
express examples in an email, so here's an example:
/* Moby Dick is a fictional whale. */
class-instance([Moby : Character = "Moby Dick"] : instance ,
[Whale : Animal = "Whale" @"http://purl.org/ceryle/authoring/#Whale"] : class ) / FictionalContext
{Moby, Description, [[The great white whale.]]}
/* Ahab is a fictional person. */
class-instance([Ahab : Character = "Captain Ahab"] : instance ,
[Person = "Person" @"http://purl.org/ceryle/authoring/#Person"] : class ) / FictionalContext
{Ahab, Description, [[The captain of the ship.]]}
Now, I happen to have a <topic> element whose ID is 'class-instance'.
In order to hook into the whole XTM 1.0 PSI framework, I need to
reference those PSIs in my own XTM document. There's a number of
ways of doing that, such as first making <topic> elements whose
subject identity points to those PSIs using <subjectIndicator> links,
and then referencing those <topic> elements via their IDs using
<topicRefs> within my XTM document, or directly referencing the
XTM PSIs by using <subjectIndicator> links and never bothering to
"reify" those with local Topics. It doesn't matter to the processor;
the same thing occurs in either case in the behind-the-scenes Topic
Map graph.
In the above example, I preface that whole mess with this, which
establishes all of the base semantics for those two sentences:
#MERGEMAP "http://purl.org/ceryle/psi/ceryle/middle.ltm" "ltm"
[Description @"http://purl.org/ceryle/psi/ceryle/#Description"]
[Character @"http://purl.org/ceryle/psi/ceryle/#Character"]
[FictionalContext ; Context = "Fictional Context"
@"http://purl.org/ceryle/psi/ceryle/#FictionalContext"]
[class-instance : Hidden @"http://www.topicmaps.org/xtm/1.0/core.xtm#class-instance"]
[class : Hidden @"http://www.topicmaps.org/xtm/1.0/core.xtm#class"]
[instance : Hidden @"http://www.topicmaps.org/xtm/1.0/core.xtm#instance"]
[FictionalContext ; Context = "Fictional Context"
@"http://purl.org/ceryle/authoring/#FictionalContext"]
>>One could imagine several XTM DTDs, used for different purposes. We
>>tried to create one that would suit most people most of the time.
>>
>
> Understood. That makes sense.
I was the editor of the modular XHTML DTDs, and I've got various
versions of those in different "strengths" for different purposes.
The whole idea of modularization is partly to allow this kind of
modification. (and no, I didn't invent this, its predecessor is
the extremely-modular DocBook DTD, which was written by Eve Maler
and Terry Allen, two particularly brilliant people).
>>It seems that "lives-in" is really a subclass, subtype or
>>subcollection (depending on your modelling structure) of
>>"social-association," not an instance. An instance would
>>be an *actual* instance of an association (as in that
>>concept of a knowledge base I described earlier). As I
>>mentioned previously, I'd built up an entire upper and
>>middle ontology using XTM's superclass-subclass association
>>type, where "lives-in" would have been a subclass of
>>"social-association", but now I have come to realize that
>>the base structure is not class but collection. The
>>distinction to some is subtle, though is actually quite
>>important.
>
> Can you explain this a little deeper for me? I now understand
> why its not an instance and now that I understand PSI, I can
> see how the relationships are defined. I don't understand the
> distinction between classes and types and what you mean
> by the base structure is a collection not a class. Can you
> elaborate or point me to some additional information?
This is where I fear I may be overly loading this conversation.
A LOT of people in knowledge representation (such as the OWL
folks) use classes kinda mindlessly, throwing words like
intensionality and extensionality around to scare off the kids.
But the more I looked into what the oddballs like Doug Lenat
were doing, they weren't basing their subsumption hierarchies
on class-based taxonomic structures, they are using collections.
It's as I said a subtle but profound difference, and I honestly
don't think it's within the scope of this email conversation
to try to cover it. The Cyc tutorials are a good place to
start, and also any papers on subsumption, identity, etc. from
Nicola Guarino and/or Chris Welty, two people whose work I
tend to trust (though their approach to ontology is entirely
different than mine, for reasons again that are waaaay out of
scope here -- suffice it to say, it involves the later
Wittgenstein, Wilfred Sellars, Richard Rorty, Robert Brandom,
etc. I'm still figuring out this whole mess myself.). In brief,
it comes down to what constitutes a "class" (is it a mathematical
structure, a linguistic or social convention, etc.?).
>>But the basic premise holds: I don't think of this as a
>>form of filtering, it's thought of in knowledge represen-
>>tation circles as a subsumption relationship, such that all
>>characteristics of the superclass are always true of its
>>subclasses -- a transitive relation.
>
> Agreed. I'm looking to use a property (namely scope) of a
> subsumption relationship for filtering..
Okay -- perhaps a bit more complicated than what I'm doing
but I can't see any reason why not. I use a similar thing
when I say things like "in a fictional context." Perhaps
you've explored the use of scope more than I have. Part of
the reason I've avoided it is that Ceryle *can* visualize
scoped Associations, but it makes the displayed graph just
that more complicated. But in user testing, so far people
seem able to glean the sentence with no problem. Perhaps
for version 2.0....
>>I'm not clear on how using scope could accomplish this,
>>because you're no longer dealing with the inheritance of
>>the subsumption relation, it seems as though you're now
>>relying on a bit of magic, that somehow by applying a
>>domain based scope, as in social associations vs. geo-
>>graphic association, you've got a system that correctly
>>filters out those things that should be inherited from
>>the ones that shouldn't. This is simply conflating the
>>idea of "lives-in" in the social domain with "lives-in"
>>in the geographic domain, and while you may have named
>>them the same, they are simply different relations. In
>>XTM you could use a scope to keep those two different
>>topics from accidentally being merged (by scoping each
>>base name "lives in" with its respective domain), but
>>I *think* what you're after is a subsumption hierarchy,
>>not scoping.
>
> I'm thinking you're right, but now I'm wondering how to use
> scope? Can you give me some examples of scope in the context
> of your application?
I think I have above already. FictionalContext is one, and when
I grep on Context, I get things like
[FactualContext ; Context = "FactualContext"]
[FictionalContext ; Context = "Fictional Context"
@"http://purl.org/ceryle/psi/ceryle/#FictionalContext"]
[Story ; FictionalContext = "Story"]
[Narrative ; FictionalContext = "Narrative"]
[Dream ; FictionalContext = "Dream"]
[Fantasy ; FictionalContext = "Fantasy"]
[HistoricalContext ; Context = "Historical Context"]
[ReligiousContext ; Context = "Religious Context"]
[MythologicalContext ; Context = "Mythological Context"]
[DreamContext ; Context = "Dream Context"]
As you can see, I'm tending to use them not so much for my common
sense ontology as particularly in the area that you're concentrating,
that of fiction writing. They could certainly be used in the ways
you've mentioned, but I'd be careful not to confuse "filtering" with
a subclass, which is certainly a simpler way of modeling it. There
may be advantages and disadvantages of each, depending on what one
is trying to do. This is one of the things I learned early about
models -- there aren't any universal ones, they're always developed
for a specific purpose.
Oh, BTW, the ";" in the LTM above is a syntax component unique to
Ceryle, which was not adopted in Ontopia's version (they didn't think
the superclass-subclass relation particularly important). In one of
my earlier emails I mentioned that I'd mistakenly been using XTM's
superclass-subclass relation, and was using the ";" to express that
in LTM (where the colon is used as class-instance, or instance-of,
depending on the direction one is facing). What I've done in my
most recent version of Ceryle is simply redefine the semicolon as
expressing a collection relation instead. Simple change, profound
semantic difference. As Ontopia didn't adopt my semicolon proposal,
I don't even have to worry about compatibility anymore anyway, so
there turned out to be a minor silver lining in their refusal.
I just now have to convince the world that collections are a better
approach than classes.
My laptop's chron jobs begin at 4:15am, and my hard drive just
started spinning. This would signal bedtime if I were smart
enough to take my laptop's advice. *sigh* that paper didn't get
written. As I mentioned to someone in private email, if I could
just somehow translate my enthusiasm for writing emails to writing
papers, I'd have a heck of a published corpus by now.
I sometimes wonder if as I'm getting older I'm getting less and
less disciplined. I sometimes think about joining a Zen monastery,
as I hear the girls are cute. Or perhaps I'm confusing that with
something else.
Murray
......................................................................
Murray Altheim http://kmi.open.ac.uk/people/murray/
Knowledge Media Institute
The Open University, Milton Keynes, Bucks, MK7 6AA, UK .
Bob did give me the secret to world domination, which was pretty
startling. He looked at me and he said, "Don" (he called me Don),
"think how dumb the average guy is." And I thought about that for
a moment, and he said, "Half of them are dumber than that."
http://www.austinchronicle.com/issues/vol17/issue47/screens.webb.html