This is a public chat log generated from the #semsol IRC channel.
23:24:51
bengee: seems the turtle parser doesn't like unicode in the backslash-u-digits form (or something), none of the 3 graphN.nt files in http://www.wasab.dk/morten/2008/01/example3.zip can be parsed (fully)
00:02:03
bengee: seems there are uses of mysql_real_escape_string in (at least) ARC2_StoreSelectQueryHandler.php without an active db connection (returning empty strings). for me it makes the default endpoint query fail with missing offset value...
00:16:09
methinks the present irc logger and/or display code needs a bit of fixing: http://arc.semsol.org/community/irc/logs/2008/01/06#T22:29:22Z <- not displayed in correct order
00:16:21
mortenf calls it a day :)
02:28:51
bye
09:41:42
bengee creates http://arc.semsol.org/dev to track bug reports and feature requests
09:43:01
bengee: I see you've got RDFJSN serialiser, nice one ;)
09:43:41
is it possible to get at an rdfjson structure unserialised? ie: native PHP ?
09:44:58
no, no parser in there, unfortunately
09:45:01
(I already have code that does it, but if arc already does it, the component could be a little smaller)
09:46:01
do you serialise it by constructing a string then? (rather than serialising JSON generically)
09:46:15
yeah, constructing a string
09:46:57
cool
09:47:40
I'm thinking of trying ARC with my eRDFt code y'see, so that it would work with RDFa too
09:47:50
and presumably also microformats
09:48:09
ARC is getting a way to add plugins, in case you'd like to contribute code that re-uses parts of ARC ;)
09:48:13
though that would be a little opaque
09:48:42
keithA remembers he was going to read about that in the scrollback, and does so now :p
10:05:07
bengee - you mean the eRDFt code as a plugin? would that fit d'y'think?
10:06:03
I suppose it's six and half-a-dozen
10:06:35
possibly, or the rdf/json parser
10:06:59
it's not really a parser - I just use someone else's JSON parser/serialiser
10:07:15
and munge triples from arc into the right structure
10:07:53
ARC's include mechanism is based on single-file includes (e.g. a parser class, or serializer class, or something like that)
10:08:14
erdft might be more like a whole app
10:09:52
needs a different name if it's not just erdf
10:09:56
what do you think?
10:11:31
bengee: probably doesn't matter whether it sits in a plugin directory of arc, or arc sits in a lib directory of 'erdft'
10:13:07
but since anyone interested would be likely to have arc already anyway, the first is probably the best
10:14:42
I'm in a similar situation with an rdfwiki script I'm trying to make work with tabulator, it's not really a plugin as it includes ARC
10:15:08
sounds interesting
10:15:28
bengee: is it possible to manually add namespaces to the parser, for parsing html fragments?
10:16:21
lemme check
10:17:52
did you try to simply prepend your fragment with a ns def (<a rel="schema.foo" ...)?
10:18:10
i could do that too
10:18:44
what's your rdfwiki script?
10:19:30
it creates and updates files in the local file system based on sparqly inserts and deletes
10:19:59
sparqly?
10:20:25
tabulator can POST a SPARQL INSERT/DELETE to a file URL
10:20:28
the filesystem is the store?
10:21:52
you open http://example.com/myfoaf.rdf in tabulator, change something, tab'r sends back a sparql update, and the file is updated
10:22:39
cool
10:23:21
and now that timbl told me how it works, I can make my rdf editor use the same mechanism, so that they are compatible
10:23:31
so is myfoaf.rdf a real file? or dynamic from the arc store?
10:24:20
it can be real, or it can be a virtual one. in the latter case, you just send the update to the local rdf store
10:24:57
bengee: how does it work? the tabulator part I mean - what does tabulator send to your server?
10:25:33
POST /myfoaf.rdf INSERT INTO ...
10:26:05
or rather INSERT { triples here }, the target graph is the file location
10:26:38
I have a .htaccess that catches the POST and sends it to the wiki script
10:27:05
a GET is just processed as usual
10:28:15
I think timbl wants to make the editing capability based on file extension, i.e. when you change a file's extension to .rdfe, it can be edited
10:28:47
hmmm
10:29:05
my test script enables writes in a whole directory
10:29:16
yeah
10:29:51
tab'r needs a "MS-Author-Via: SPARQL" header to enable editing via its UI
10:31:05
so, the .htaccess sends the header and catches posts, the sparql stuff is handled by arc, and the file writer is a simple plugin
10:31:23
I was thinking about a script that would make editing of stuff in talis platform stores possible with tabulator
10:32:03
should be pretty possible using your technique I'd think
10:33:14
yeah, I think the setup is rather straightforward
10:35:25
does tabulator follow http://jena.hpl.hp.com/~afs/SPARQL-Update.html ?
10:38:07
t uses ericp's approach, but they are similar
10:41:58
does arc parse that then?
10:42:08
is SPARQL+ a superset?
10:42:23
arc needs an INTO which I have to inject
10:43:18
but I've changed the sparql+ spec yesterday to bring ARC closer to SPARUL and SPARQL/Update
10:44:36
is your code for the file based wiki update online anywhere?
10:45:31
no, not yet, gotta finish danbri's wp plugin first
10:45:44
and fix some other bugs...
11:49:02
Hi
11:49:43
I'm naibed, I entered yesterday
11:50:08
I managed ARC2 to load a very small ontology and It seems to work
11:50:35
But now my question is, how can I "save" the result of the new ontology, once I modify It?
11:51:04
Something like $store->toRDFXML($triples);
11:51:19
$triples=$store->toNTriples(...?¿
11:53:41
not sure what other otions there are, but try:
11:53:45
CONSTRUCT { ?s ?p ?o } WHERE { ?s ?p ?o . }
11:53:53
$triples=$parser->getTriples(); $rdfxml=$parser->toRDFXML($triples);
11:53:55
but that works in my sparql endpoint webform
11:54:08
danbri bows to the master :)
11:54:15
;)
11:54:53
Call to a member function getTriples() on a non-object
11:55:05
$triples=$parser->getTriples();
11:55:23
Oh OK, but I have no $parser...
11:55:29
Just a $store
11:55:52
then you have to pull out the triples first
11:56:00
$store = ARC2::getStore($config);$store->query('LOAD <ontology.owl>');
11:56:08
Yeah but how?
11:56:18
$store->toNTriples(whatgoeshere?)
11:56:43
$rows = $store->query("SELECT * WHERE {?s ?p ?o }", "rows");
11:57:15
$rdfxml = $store->toRDFXML($rows);
11:57:20
I just do not understand that
11:57:31
I want to do a "INSERT"
11:57:46
And then modify or retrieve the whole ontology
11:57:53
In RDF
11:58:04
1) LOAD
11:58:15
2) sparql insert/delete/whatever
11:58:19
yes
11:58:21
3) select the triples
11:58:31
4) serialize
11:58:41
So I have to do a "select all" like query
11:58:48
to select all the triples and then get the result in rdf?
11:58:49
you may want to read "internal structures" in the documentation
11:59:04
( steps 3 and 4)
11:59:19
ARC supports resource indexes and a certain triples aray format
11:59:25
bengee: I've been doing that but I'm not smart enough XD
11:59:28
and it can serialize those
12:00:14
and when you do a SELECT which returns s,p, and o keys, it can even treat that tabular result as a triples array, i.e. you can serialize it right away
12:00:39
Ok
12:00:45
otherwise you can follow danbri's exampe and do a DESCRIBE or CONSTRUCT
12:00:52
It seems it works but some information is lost
12:01:00
or just build an ARC-compliant array structure manually
12:01:01
From the original file of course
12:01:44
:-?
12:07:43
Wow, the RDFXML result is not like the original one...
12:08:00
p1:Restriction Process... what's that? lol :(
12:10:35
you may want to wait til the parser is fixed
12:11:32
Ok, thanks
12:11:34
the rdfxml will of course look different from the input doc, though
12:12:00
If it's a bit different it doesn't matter
12:12:11
but at least the same classes and properties...
12:12:13
it's always flat
12:25:55
see you later
12:25:58
thank you!
12:26:08
'k, cya
12:55:12
bengee, did you see http://deliciouslymeta.com/projects/xfn/test_data.html ?
12:55:44
wonder if those validaty tests could be expressed in sparql over the output of your parser?
12:55:50
related: http://isegserv.itd.rl.ac.uk/schemarama/
12:56:22
interesting, didn't know it
12:57:13
meanwhile in twitter: _masaka: aahhh, 'ARC does not support direct in-memory SPARQLing' ...
12:57:31
would be cool if kanzaki gets into ARC... he churns out great demos
12:57:47
oh, who wrote that component ?
12:57:51
;)
12:58:04
component?
12:58:34
but looks like I should add in-memory sparqling some day, there seems to be demand for it
12:58:56
so far, ARC needs a mysql db for sparql
13:00:33
is it a huge job? basically a second engine? or you can re-use code from the sql-backed one somehow?
13:01:07
not much re-use, unfortunately
13:02:09
figures
13:02:32
i had 2 separate engines in rubyrdf ... one sql-backed, the other i somehow managed to write, despite not really knowing how :)
13:02:42
but that was for a simpler QL, Squish
13:02:51
happy to leave it to others now
13:03:02
you might be able to transliterate one from another scripting lang
13:03:07
eg. python?
13:03:22
yeah, perhaps
13:03:55
or just start with something simple like basic group graph patterns, limit and offset, etc
13:04:15
yep
13:27:48
ah, /me misread the kanzaki quote: not/now
13:36:50
ah :)
14:19:22
bengee ... feature req for htmltab output: can it display some "no matches" text if you get 0 hits?
14:19:30
a blank page can be confusing
14:20:23
trying ./dataloader http://redmonk.net/about-this-site/
14:20:45
yeah, just replied
14:20:46
i see co-worker in a redmonk.net namespace not xfn, is that intended?
14:21:18
do you use co-worker and xfn properties as links to documents, or to people/agnts?
14:21:43
to people
14:22:13
he says "Wow, that's lot of data!" but i only see about 10 triples
14:22:15
I have co-worker as xfn:co-worker only here, hmm
14:22:35
try http://sandbox.foaf-project.org/2008/foaf/ggg.php?query=SELECT+%3Fs+%3Fp+%3Fo+WHERE+%7B%0D%0AGRAPH+%3Chttp%3A%2F%2Fredmonk.net%2Fabout-this-site%2F%3E%0D%0A%7B++%3Fs+%3Fp+%3Fo+.+%7D%0D%0A%7D%0D%0ALIMIT+10%0D%0A++++++++++++&output=htmltab&jsonp=
14:22:40
292 triples here
14:22:44
DOH
14:22:46
"LIMIT 10"
14:22:52
heh
14:22:58
that's the stupidest mistake I've made today!
14:23:32
but i see http://redmonk.net/about-this-site/co-worker in predictate field
14:23:37
http://sandbox.foaf-project.org/2008/foaf/ggg.php?query=SELECT+%3Fs+%3Fp+%3Fo+WHERE+%7B%0D%0AGRAPH+%3Chttp%3A%2F%2Fredmonk.net%2Fabout-this-site%2F%3E%0D%0A%7B++%3Fs+%3Fp+%3Fo+.+%7D%0D%0A%7D%0D%0A%0D%0A++++++++++++&output=htmltab&jsonp=
14:25:13
and lots of dupes, too
14:27:02
hmm _:b1672287707__steve_ivy http://xmlns.com/foaf/0.1/homepage aim:goim?screenname=monkinetic
14:28:22
that's prolly coming from an xfn:me
14:29:08
if we crawl some xfn, we can ask Qs like "who says that x is friend, but x just has them as a contact?"
14:30:07
yeah, but you need to cosoidate the bnodes first
14:30:29
unless you formulate the query using foaf:homepage
14:31:59
I wonder why your triples are so borken
14:32:10
bengee tries it via LOAD, too
14:32:18
325 triples
14:32:20
bnodes, yeah
14:32:58
in my loader script, can i get more feedback on how many triples it added?
14:33:38
the query() method returns an array with information about duration and triple-count
14:36:11
yeah, I get those broken triples, too
14:37:06
but also the correct ones
14:37:26
I guess the broken stuff comes from one of the other default extractors
14:38:34
aha, it's the RDFa extractor
14:42:05
danbri, you can disable the RDFa extractor via the config array
14:42:59
... "sem_html_formats" => "erdf dc openid hcard-foaf xfn" ...
14:43:14
or some other subset
14:43:48
or wait for the next rev ;)
14:46:40
bengee receives ARC2_RemoteEndpointPlugin class file from mortenf :)
14:47:55
bengee is starting to drown a bit
14:48:14
cool to see all that activity, though
14:49:41
hi
14:49:45
bengee puts reply to Steve on hold for the minute
14:49:53
hi terraces
14:50:05
bengee: is there a way to return query results in json with the query() method ?
14:52:25
no, not directly
14:52:32
(I think)
14:56:17
ok, I see I have to call something like getSPARQLJSONSelectResultDoc to translate it
14:57:47
i'll wait for next rev
14:57:53
where you fix it? or just disable rdfa?
14:58:01
i have some rdfa in my homepage btw, not a lot yet
14:59:48
terraces, the endpoint extends the store, it should be possible to instantiate the endpoint instead of the store, then do query() as usual, and then get the json via $this->...
15:01:16
but it will create a public endpoint ?
15:01:19
danbri, not sure. there is a new rdfa syntax ED, but I'm not sure if I can squeeze that in on top of all the other pending requests..
15:01:26
terraces, no
15:02:10
bengee: ok, so that should be ok for what I need
15:02:38
no public endpoint w/o a dedicated somescript.php that instantiates the endpoint and explicitly calls $endpoint->handleRequest()
15:03:55
bengee .nextAction: finally fix that damn rdf collection bug
15:09:39
bengee adds "no results found" message to endpoint table generator
15:22:31
bengee, do you have an arc filter on twitter?
15:22:35
"_masaka: cannot understand why ARC complains like "Table 'arc.arc_o2val' doesn't exist:" while tables arc_triples etc were created"
15:25:26
hmm
16:36:34
terraces really likes the 6-lines-of-php way of creating an endpoint
16:43:42
:)
16:58:42
I'm trying to set up a service_uri / api_key system to allow some services to add new files in the store
16:59:27
is there already something similar in the endpoint class ?
17:02:58
no, the endpoint is pretty basic
17:04:29
you could use the getSetting/setSetting methods of the store to save your preferences, though
17:05:07
(they are stored in a separate table and can't be accessed from sparql)
17:06:53
bengee looks at correctly parsed collections
17:06:59
at last :)
17:55:50
bengee runs rdf core tests
20:27:38
bengee finishes rdf syntax test parsing
20:27:58
much better now
21:27:21
bengee uploads a new rev
21:27:36
.. and collapses. g'night everyone
