On 9/25/07, Markus Krötzsch mak@aifb.uni-karlsruhe.de wrote:
On Dienstag, 25. September 2007, Thomas Dalton wrote:
Markus and Thomas,
Yes, I'm aware of http://ontoworld.org/wiki/Semantic_MediaWiki (I believe I referenced it in my original post + cc'd the semediawiki list(s)?).
I call my project 'semarbtri' to distinguish it from the existing Semantic Mediawiki project.
My biggest beef w/ Semantic Mediawiki (the reason I'm writing my own extension) is that you can only add semantic information for the page you're editing.
For example, on the Lucy page, you could say:
Lucy has a younger brother [[has_brother::Linus]]
However, you couldn't add any semantic information about Linus on the Lucy page. Instead, you'd have to create a new page for Linus, and add the semantic information there.
This can be really tedious if you're listing all the characters in a comic strip (for example)-- you have to create pages for each one, instead of just including the semantic info when you list them.
In my opinion, this is why startup wikis end up w/ so many blank pages.
I think having a plugin that lets you add info to other pages would be really helpful.
That's an interesting point. Semantically, a different person should be on a different page, but you make a good point that in practice, that isn't always the best option. I would suggest adding your feature to the existing extension, rather than reinventing the wheel, though.
It would be not to hard to add something like this to SMW, even in a fairly modular way (although the DB layout obviously would need extension). The reason that we did not do it is that we felt that it impairs maintainability (if you discover a wrong search result, what page do you edit to fix it?), and that it might lead to a "semantic shadow wiki" (people creating very complex structures on a single page, which is hard to control; e.g. locking the page on Lucy during an edit war [controversial girl, that Lucy] still would not prevent people to add the disputed information elsewhere). I know that there are all kinds of ideas to prevent this, but this certainly adds some complexity.
I don't necessarily disagree with you. This is really more of an experiment. I want to code this extension (or pay someone else to code it), and then create 2-3 wikis with it. I sense this extension will result in rapidly-growing wikis, but, as you point out, once the wikis reach a certain size, they may be really hard to maintain. I'm just interested in seeing what happens (it may be a lousy idea, but I think it's worth testing). Locking is one challenge (redirection, page deletion, inverse/implicit relations, etc are others)
Anyway, rebuilding everything from scratch just to add this feature seems to be a lot of avoidable work. We can also assist you with extending SMW (by providing extension interfaces etc.). But do as you like.
I originally tried to edit SMW to do this, but decided it was too hard, gave up, and tried editing MediaWiki code directly. I'm willing to try editing SMW again.
I actually don't think this is a hard problem. Using the ArticleSaveComplete and ArticleAfterFetchContent hooks, along with the powerful built-in doEdit() method, this should be quite do-able.
The theory:
% Each page has a special "Stuff That Comes From Other Pages" section.
% When you update page X, your ArticleSaveComplete hook figures out what pages you're adding data to, and uses doEdit() to add the data [there are special cases here: for example, if you were previously adding data to a page but aren't anymore]
% When viewing page X, ArticleAfterFetchContent() can cleanup all the funny [[x!!this is added to page x]] links and change them to "this is added to page x".
% Since hooks can have multiple function, this shouldn't interfere w/ SMW hooks
I've attached my latest attempt, which has 2 major problems:
% It's designed for MediaWiki, not SMW
% It doesn't actually work.
Anyone interested in making it work, either for free or for pay?
Markus