rdf, python head's up

Johan, I’m not following what you’re doing with the python port much
(just hoping for unit tests and nice doc strings so that an API doc
can be auto-generated), but do want to make sure you think about
something I’ve been meaning to mention, but keep forgetting:

Your implementation should not rely on XML tools for processing RDF .

I’m not saying you should yourself worry now about using an RDF
library like RDFLib [1], but you should design the code so that it is
trivial for some RDF hacker to jump in and change to that richer, more
robust) RDF support later; ideally without having to any hacking to
the core library.

Bruce

[1] http://en.wikipedia.org/wiki/RDFLib

Hi Bruce,

Thanks for the link. I am currently focusing on MODS and not so much
on RDF because it’s much easier for me to obtain MODS data than RDF
(because of bibutils). My citation processing doesn’t depend on the
format of the references, it always accesses the data through the
Reference object. A RDF implementation can either prefill such
References or subclass it to provide data on-demand.

A very easy way to see what I’m up to until now is if you have the
project open in TextMate by pressing cmd-R when you have citeproc.py
opened in the frontmost window. From the commandline it is:

cd citeproc-py/lib
python citeproc.py

Some debugging prints will come first, then the list of citations,
references, the bibliography and finally the data put back into the
original xml file.

Nice doc strings will surely come. I don’t know about the testing yet.
I don’t have much experience working with tests.

Johan

Thanks for the link. I am currently focusing on MODS and not so much
on RDF because it’s much easier for me to obtain MODS data than RDF
(because of bibutils).

Yup. reminds me, I need to finish the MODS2RDF XSLT, and/or bug Chris
again for an RDF output mode.

My citation processing doesn’t depend on the
format of the references, it always accesses the data through the
Reference object. A RDF implementation can either prefill such
References or subclass it to provide data on-demand.

Sounds good.

A very easy way to see what I’m up to until now is if you have the
project open in TextMate …

I don’t use TextMate (oXygen for XML development, VIM usually for
scripting stuff, and emacs for XML authoring), but sounds cool!

This reminds me of a cool little tool for emacs that Peter Flynn once
tolld me about called “Remembrance Agent.” The idea I had was, what if
your editor could watch what you are writing, and present a list of
matching citations for easy insertion into the document? No switching
back-and-forth betwen editor and database.

Nice doc strings will surely come. I don’t know about the testing yet.
I don’t have much experience working with tests.

I’m betting the time it’ll take you to learn now (two hours?) will
save you a LOT more time in the future. I only wish XSLT had good
testing support!

Bruce