Open olenz opened 10 years ago
It would be very easy to do so by adding some scripts on a page
page = wiki.site.Pages['SnowWhite'] old_content = page.edit() new_content = old_content + "[[Category:Princess]][[friend of::Grumpy]]" page.save(new_content)
https://github.com/baojie/smw/commit/330055cadd0fe2e133100a35cf0d3b92f243a0fb
That's not exactly what I meant. I thought that there would be a function to more directly modify the SMW data, e.g. by allowing to upload an RDF file (basically the inverse of "getRDF"). However, I see that this might be a problem, as all data should somehow be reflected in the contents of the article, I guess.
In SMW, the page content is primary, and database version is secondary. If we directly write to the database, the written data could be lost when the subject page is refreshed.
I agree that it would be very useful to import RDF data into wiki. The RDFIO extension [1] maybe used, although it requires a bit more setup at server side.
It may be useful to enable client-side Python support (without changing server code) by rewriting RDF triples to wiki scripts. Let's keep it in the roadmap
Do you see a chance to support writing the Semantic data in the wiki? The RDF export is handled via the Special page, but there is no corresponding thing for writing data, is there?