RDFa support

17 views
Skip to first unread message

Frank Bennett

unread,
Apr 3, 2011, 12:08:43 PM4/3/11
to zotero-dev
After a discussion with Phillip Lord, I've made some changes in
citeproc-js to provide access to the itemID inside the function used
to generate the bibliography entry wrapper. One of the things this
opens a path to is the inclusion of simple RDFa structures in HTML
output as a set of hidden tags. While not as fancy as wrapping content
in RDFa, this would still offer a basis (once an RDFa parser is sorted
out) for round-tripping citation data between the Web and reference
managers.

To anyone interested in contributing, RDFa output should be pretty
simple to implement. Everything you need to know is in a little
comment in the format.js source file of citeproc-js.

http://groups.google.com/group/citeproc-js/browse_thread/thread/8095a38f21e0327d

Bruce D'Arcus

unread,
Apr 3, 2011, 12:26:09 PM4/3/11
to zoter...@googlegroups.com, development discussion for xbiblio
cc-ing xbib-dev on reply ...

On Sun, Apr 3, 2011 at 12:08 PM, Frank Bennett <bierc...@gmail.com> wrote:
> After a discussion with Phillip Lord, I've made some changes in
> citeproc-js to provide access to the itemID inside the function used
> to generate the bibliography entry wrapper. One of the things this
> opens a path to is the inclusion of simple RDFa structures in HTML
> output as a set of hidden tags.

So just to be clear, this is because of something about the way you've
designed the code that means that output tokens lose association to
metadata content during processing?

Effectively, then, you need to dump a separate representation of the
bib item. This would facilitate RDFa, but also any other format
really.

But it does have the cost of requiring duplication of content.

Do I have that all right?

> While not as fancy as wrapping content
> in RDFa, this would still offer a basis (once an RDFa parser is sorted
> out) for round-tripping citation data between the Web and reference
> managers.
>
> To anyone interested in contributing, RDFa output should be pretty
> simple to implement. Everything you need to know is in a little
> comment in the format.js source file of citeproc-js.
>
> http://groups.google.com/group/citeproc-js/browse_thread/thread/8095a38f21e0327d

And if anyone has BIBO/RDFa specific questions, there's google group.

<http://groups.google.com/group/bibliographic-ontology-specification-group>

Bruce
Bruce

Frank Bennett

unread,
Apr 4, 2011, 6:11:04 AM4/4/11
to zotero-dev
On Apr 4, 1:26 am, "Bruce D'Arcus" <bdar...@gmail.com> wrote:
> cc-ing xbib-dev on reply ...
>
> On Sun, Apr 3, 2011 at 12:08 PM, Frank Bennett <biercena...@gmail.com> wrote:
> > After a discussion with Phillip Lord, I've made some changes in
> > citeproc-js to provide access to the itemID inside the function used
> > to generate the bibliography entry wrapper. One of the things this
> > opens a path to is the inclusion of simple RDFa structures in HTML
> > output as a set of hidden tags.
>
> So just to be clear, this is because of something about the way you've
> designed the code that means that output tokens lose association to
> metadata content during processing?
>
> Effectively, then, you need to dump a separate representation of the
> bib item. This would facilitate RDFa, but also any other format
> really.
>
> But it does have the cost of requiring duplication of content.
>
> Do I have that all right?

Answered over on xbiblio-devel, the gist of which is that while there
are things I would do differently if, mercy, I were to code the
processor all over again, but the output format isn't one of them. The
adjustments required here amounted to all of two lines of code. As for
duplicating content, you have to do that anyway, since the actual
field content of items often differs significantly from what is
rendered.

Anyway, just thought this would be of interest. No worries.

Frank


>
> > While not as fancy as wrapping content
> > in RDFa, this would still offer a basis (once an RDFa parser is sorted
> > out) for round-tripping citation data between the Web and reference
> > managers.
>
> > To anyone interested in contributing, RDFa output should be pretty
> > simple to implement. Everything you need to know is in a little
> > comment in the format.js source file of citeproc-js.
>
> >http://groups.google.com/group/citeproc-js/browse_thread/thread/8095a...
>
> And if anyone has BIBO/RDFa specific questions, there's google group.
>
> <http://groups.google.com/group/bibliographic-ontology-specification-g...>
>
> Bruce
> Bruce
Reply all
Reply to author
Forward
0 new messages