> > As an interested onlooker hoping to one day see SMW on the wikis I
> > regularly use,
> Contact their admins! Vote early and often! :-)
I've already put in the suggestion. ;)
> > Can relationships and/or their objects be gathered into defined
> > heirarchies? If I assign a relationship [[born in::Tokyo]] to Keiko
> > Matsui, can "Tokyo" be heirarchically defined as being within Japan,
> Yes to "defined", but not really "hierarchically defined".
> The Tokyo page can have the property [[located in::Japan]] and browsing
> will reveal a located_in hierarchy (try
> http://ontoworld.org/wiki/Special:Browse/Japan ).
That's a neat feature that I hadn't looked at before. :)
> > which would then be similarly defined as being within Asia? I'd like to
> > see "Keiko Matsui" show up automatically in lists of "People born in
> > Japan" and "People born in Asia" without manually also assigning the
> > relationships [[born in::Japan]] and [[born in::Asia]].
> Using subqueries
> (http://ontoworld.org/wiki/Help:Semantic_search#Subqueries ), this query
> [[born in::<q>[[located in::Japan]]</q>]]
> will find every page with a Born_in relation to a page that in turn has
> a Located_in relation to Japan. Try it at
> http://ontoworld.org/wiki/Special:Ask ,
> it should find Ken Watanabe.
Okay, yes, very handy.
> Subquerying is pretty nifty and buys a lot. But it doesn't
> automatically "follow" the Located_in relationship. So
> [[born in::<q>[[located in::Asia]]</q>]]
> won't find anyone, even though ontoworld's Japan page says it's located
> in Asia. You would have to put [[located in::Asia]] on each Japanese
> city's page, or you would have to explicitly nest another subquery to
> follow three levels:
> [[born in::<q>[[located in::<q>[[located in::Asia]]</q>]]</q>]]
> Also, if all you knew of someone was they were born in Japan, that first
> query won't find that person, unless the Japan page says Japan itself is
> [[located in::Japan]].
> So either you craft complex queries to catch all the levels of
> Relation:Located_in, or you add extra redundant Located_in relations to
> pages to make the simple subquery work.
Okay, I see the problem.
> SMW *is* aware of hierarchies of categories. Querying for
> [[Category:Person]] will find people in the subcategories of person,
> e.g. Architect. So if SMW's magic handling of categories could be
> applied to other relations, you could write a query that "follows" the
> Located_in relationship.
Aha! So maybe this is a solution, or a path to one. So if I were to use
the query [[born in::<q>[[located in::<q>[[Category:Asia]]</q>]]</q>]], I
could find all people born in places that are located in places that belong
to the category Asia or its subcategories... right?
But I'd have to be careful, as your Turkey example points out below. I'd
either have to be sure to put into the category only those articles that are
wholly subsets of it, or else I'd have to use a special category, perhaps
replacing [[Category:Asia]] in my query with something like
[[Category:Subset of Asia]]. (Japan would be both [[Category:Asia]] and
[[Category:Subset of Asia]], but Turkey would only be [[Category:Asia]].
Then, if I was to be meticulously complete, I'd have to divide up all the
provinces that are [[located in::Turkey]] and categorize them as either
[[Category:Subset of Asia]] or [[Category:Subset of Europe]].)
> I think a more formal expression of your reasonable expectation is that
> Relation:Located_in is transitive (owl:TransitiveProperty) and reflexive
> (??), therefore the subquery [[Located in::Japan]] should find
> everything located in things that are located in things ... that are
> located in Japan, and also find Japan itself. As I said in my first
> reply, maybe you could export the RDF and import it into some
> ontological wonder AI system.
> By the way, someone wrote interesting text at
> http://ontoworld.org/wiki/Relation:Located_in explaining why Located_in
> *isn't* transitive. E.g. Edirne province is located in Turkey, Turkey
> is both located in Europe and located in Asia, but Edirne province is
> not located in Asia, only Europe. Saying something is "hierarchical"
> isn't nearly precise enough, read
> http://www.w3.org/2001/sw/BestPractices/OEP/SimplePartWhole/ and
> http://en.wikipedia.org/wiki/Mereology (I haven't :-) )
A very good illustration of a critical flaw in my concept. I'm glad you
pointed it out.
> > Similarly, a person who was /born in /Tokyo should automatically be
> > considered to be /from /Tokyo, just like those who were not born there
> > but later moved there. So is it possible to define "born in" as a
> > heirarchical subset of "from"?
> In SMW you can add annotations to relation pages for these sort of
> meta-relationships (e.g. look at
> http://ontoworld.org/wiki/Relation:Family_member ), but SMW queries
> won't magically use them.
That's too bad. Well, perhaps in a future version.
> > Having assigned the relationship [[born
> > in::Tokyo]], I'd like to see "Keiko Matsui" show up in a list of "People
> > from Tokyo" without also manually assigning the relationship
> > [[from::Tokyo]].
> Not within SMW. As above, you either make more complex queries, or
> mechanically put redundant information in pages to make simpler queries
> give the right answers.
Okay, so I'd have to apply both relationships, probably to the same link (as
described below): [[born in::Tokyo| ]][[from::Tokyo]].
> > Finally, is there an easy way to assign multiple relationships to the
> > same object? Keiko Matsui is not only a [[composer of::jazz]] but also
> > a [[musician of::jazz]] and a [[performer of::jazz]]. Is there a way to
> > put all three relationships on the same link?
> Yes, amazingly and undocumentedly,
> [[composer of::musician of::performer of::jazz]]
> works. I think the help used to document this weird chaining, but it's
> gone from http://ontoworld.org/wiki/Help:Annotation
> That style would confuse a lot of human editors.
Excellent! That's just the sort of thing I was looking for. Although, I
suppose you're right, that could be confusing, and especially so without
> > Or would I have to create
> > one real and two false links, like [[composer of::jazz|]][[musician
> > of::jazz|]][[performer of::jazz]]? Would that even work?
> Yes although I believe you need whitespace after the pipe symbol, thus
> [[composer of::jazz| ]][[musician of::jazz| ]][[performer of::jazz]]
> works, and is a more obvious way to annotate than the "chaining" above.
Got it. I'd probably go this way just to avoid the potential for confusion
inherent in the chained notation above.
> > Or would it
> > be possible to nest the relationships, like [[composer
> > of::jazz|[[musician of::jazz|[[performer of::jazz]]]]]]?
> I'm not sure what you expect that to achieve.
Just another notation that might have achieved the same thing. I've seen
nested links in the documentation, such as
john@...]]] (from http://ontoworld.org/wiki/Help:Annotation). I
like the brevity of the chained method more, though, and I like the clarity
of the empty-piped link more, too.
> These are great questions.
Thanks. It's been said that one of the hallmarks of a great, innovative
system is that it inspires the imagination to find new ways to expand,
improve and use it. "Wow, where else could we take this?" I think SMW
definitely falls into that realm. :)