[open-literature] Further work on openletters / opencorrespondence.org

print.crimes print.crimes at yatterings.com
Wed May 5 19:23:50 UTC 2010


Cheers for this Ben. Your suggestion is what I'm trying to get at with 
the RDF. I'm working on an endpoint in the Python version so I'll add it 
to that one and largely consign the PHP version to 0.01a. Should have a 
fix (or beginnings of) for Friday/Saturday morning (as I'm at back work 
tomorrow). I'll take a look at the parser as well.

Iain
On 05/05/2010 17:51, Ben O'Steen wrote:
> I've had a quick browse of the RDF - I'm not sure that the serialisation
> is what you are intending. Are you really trying to use rdf:ID, or are
> you aiming to give URI's to things?
>
> I think this is a representative chunk of the RDF as it stands:
>
> ...
> <text:uri
> rdf:ID="http://austgate.co.uk/dickens/letter.php?recipient=46mrgeorgecattermole">46mrgeorgecattermole</text:uri>
> <dc:author>Charles Dickens</dc:author>
> <text:Correspondent
> rdf:ID="http://austgate.co.uk/dickens/rdf.php?type=correspondent&correspondent=mr.georgecattermole">Mr. George Cattermole</text:Correspondent>
> <text:referredPerson>Lord George Gordon</text:referredPerson>
> <text:referredPerson>Mr Haredale</text:referredPerson>
> <text:referredPerson>Mr Chester</text:referredPerson>
> <text:referredPerson>Mr Haredale</text:referredPerson>
> <text:referredPerson>Mr Haredale</text:referredPerson>
> <text:referredPerson>Mr Haredale</text:referredPerson>
> <text:referredPerson>Master Humphrey</text:referredPerson>
> <date>1841</date>
> ...
>
> (Eg it currently doesn't validate: http://www.w3.org/RDF/Validator/)
>
>
> I think what you mean is:
>
> <rdf:Description
> rdf:about="http://austgate.co.uk/dickens/letter.php?recipient=46mrgeorgecattermole">
>    <dc:author>Charles Dickens</dc:author>
>    <text:Correspondent
> rdf:resource="http://austgate.co.uk/dickens/rdf.php?type=correspondent&correspondent=mr.georgecattermole"/>
>    <text:referredPerson>Lord George Gordon</text:referredPerson>
>    <text:referredPerson>Mr Haredale</text:referredPerson>
>    <text:referredPerson>Mr Chester</text:referredPerson>
>    <text:referredPerson>Mr Haredale</text:referredPerson>
>    <text:referredPerson>Mr Haredale</text:referredPerson>
>    <text:referredPerson>Mr Haredale</text:referredPerson>
>    <text:referredPerson>Master Humphrey</text:referredPerson>
>    <dc:date>1841</dc:date>
> </rdf:Description>
>
>
> Note that the URIs above are likely not to be very valid:
> eg:
> http://austgate.co.uk/dickens/letter.php?recipient=46mrgeorgecattermole
>
> --->  a better uri for this might be --->
>
> http://austgate.co.uk/dickens/correspondents/46mrgeorgecattermole
> (RDF resource per correspondent)
> or
> http://austgate.co.uk/dickens/correspondents#46mrgeorgecattermole
> (RDF resource with all the correspondents info in)
>
> There is a tedious and long-debated issue over the endings of uris which
> you can look into if you want (google httpRange-14) but there's a lot of
> discourse on it.
>
> There are RDF parsers and constructors built into the rdflib library -
> it's a lot easier to create valid and parsable RDF if you use that.
>
> I've written a wrapper that might make it easier?
>
> http://pastebin.com/XWj6E4cM
>
>
> Ben
>
> On Sun, 2010-05-02 at 18:21 +0100, print.crimes wrote:
>    
>> Ben,
>>
>> Not sure if its ready for download yet. I'm still working on the rdf
>> parsing here and realised that it would be raeasier to create a store
>> at loading rather than on the fly.
>>
>> There is a "first draft" of the rdf export here:
>> http://austgate.co.uk/dickens/export.php?type=rdf&author=Dickens
>>
>> Rufus: cool. still working on rewriting the rdf parser. As above, it
>> dawned on me at 11 last night, it would perhaps be easier to create
>> the store at loading and use sparql to create the individual letters
>> rather than re-parse each time something is viewed. It would also
>> create an endpoint which allows re-use of the data as well.
>>
>> Hope this helps,
>>
>> Iain
>>
>> On 02/05/2010 15:03, Ben O'Steen wrote:
>>      
>>> Cool - is there a way for me to start playing with this?
>>>
>>> Ben
>>>
>>>        
>>>> On May 2, 2010 11:18 AM, "Rufus Pollock"<rufus.pollock at okfn.org>
>>>> wrote:
>>>>
>>>> Everyone: Iain and I have been working away on openletters /
>>>> http://opencorrespondence.org/
>>>>
>>>> We're now nearly at the point where we have the letters parsed
>>>> into
>>>> the db and in the web interface ...
>>>>
>>>> Iain: I've now committed the updated cli/loader stuff so you can
>>>> now
>>>> load letters (main.py) by doing:
>>>>
>>>> $ paster load dickens
>>>> # or if you want to specify an ini file other than development.ini
>>>> $ paster load --config test.ini dickens
>>>>
>>>> I plan to do some more work later on putting in some templates and
>>>> using them from controllers (e.g. for displaying letters).
>>>>
>>>> Rufus
>>>>
>>>> _______________________________________________
>>>> open-literature mailing list
>>>> open-literature at lists.okfn.org
>>>> http://lists.okfn.org/mailman/listinfo/open-literature
>>>>          
>>      
>
>
>
>    






More information about the open-literature mailing list