Aaron Swartz s A Programmable Web An Unfinished Work.pdf/65

Exported from Wikisource on August 8, 2024

8. CONCLUSION: A SEMANTIC WEB?

53

Naturally, it can also search through the resulting data to answer your questions in much the same way SPARQL does.

But cwm goes a step further. It doesn’t just search through data; it thinks about it. cwm can follow logical rules; take this one for example:

{ ?x a :Man } => { ?x :mortality :mortal } .

(If something is a man, then it’s mortal.) Feed this into cwm, along with:

:Socrates a :Man .

And it will logically deduce that Socrates is mortal. Such rulesets obviously have all sorts of uses, from logical parlor games to actual programming. But one obvious use is providing conversions between different RDF formats. Imagine two schemas: “joe:”, which has “small”, “medium”, and “large” and “starbucks:” which has “short”, “tall”, “grande”, and “venti”. Now we can just write a few rules to convert between them:

{ ?x joe:size joe:small } <=> { ?x starbucks:size starbucks:tall } .

{ ?x joe:size joe:medium } <=> { ?x starbucks:size starbucks:grande } .

{ ?x joe:size joe:large } <=> { ?x starbucks:size starbucks:venti } .

Feed these rules into cwm, along with the data in one format, and cwm will “think” about it and spit out data in the other format.

But cwm can do much more than just basic logical inference. It also has a wide variety of built-ins, that can do everything from mathematical processing to advanced cryptography. With them, and some clever rules, you can even build entire programs using cwm.

Incidentally, none of this is new—nearly all this stuff was written in 2001.

cwm is also smart enough to go onto the Web and find more rules like these, crawling through web pages for more bits of RDF to make it smarter. Following links and URLs and getting more data, it can surf the Web for data in the same way a bored teenager surfs the Web for fun.

If you’re interested in giving this process a spin for yourself, you can try Tim’s latest project: the Tabulator. It’s a little add-on to your web browser that lets it see

About this digital edition

This e-book comes from the online library Wikisource. This multilingual digital library, built by volunteers, is committed to developing a free accessible collection of publications of every kind: novels, poems, magazines, letters...

We distribute our books for free, starting from works not copyrighted or published under a free license. You are free to use our e-books for any purpose (including commercial exploitation), under the terms of the Creative Commons Attribution-ShareAlike 4.0 Unported license or, at your choice, those of the GNU FDL.

Wikisource is constantly looking for new members. During the transcription and proofreading of this book, it's possible that we made some errors. You can report them at this page.

The following users contributed to this book:

- Erick Soares3

- Einstein95

Table of Contents

Title page

Aaron Swartz s A Programmable Web An Unfinished Work.pdf/65

About