CSL Bluebook extensions

I have completed a tour through the code of Zotero, tweaking and
extending the code to support the Bluebook style, for use in our
faculty writing programs. Unavoidably, some of the changes have
touched on CSL. To the extent that CSL contemplates Bluebook support,
the functionality we have implemented here will be required. I would
welcome a discussion of the changes, with a view to including them, or
some concrete alternative, in official CSL. I have no special
attachment to the solutions I have implemented here; but the use cases
do need to be covered.

Here are the changes, and the use cases that they address.

[A] Note number backreferences

Example:

  1. John Doe, The Laws of Lilliput 123 (1900)
  2. Jane Roe, A Lilliputian Disputation (1905)
  3. Doe, supra note 1.

Problem:
The note number is required in the back-reference.

Solution:

[B] Previous reference in same note:

Example:

  1. John Doe, The Laws of Lilliput 123 (1900); Jane Roe, A Lilliputian
    Disputation (1905). Doe relates the laws of Lilliput to those of
    Brobdingnag throughout his work. Doe, supra.

Problem:
The supra reference in this case does not have a note number, because
it is in the same footnote as the target reference.

Solution:
SUPRA TEXT


NOTE TEXT

[C] Reset first reference

  1. Putting Things on Top of Other Things Act sec. 123, 999 USC 234 (1900).
  2. 99 USC 235 (1900).
  3. 99 USC 277 (1900).
  4. 99 USC 255 (1900).
  5. 99 USC 240 (1900).
  6. Putting Things on Top of Other Things Act sec. 124, 99 USC 235 (1900).

Problem:
A statute must be cited with the full form if the short form does not
occur within the last five footnotes. Supra is not used.

Solution:


FULL


SHORT

I have completed a tour through the code of Zotero, tweaking and
extending the code to support the Bluebook style, for use in our
faculty writing programs. Unavoidably, some of the changes have
touched on CSL. To the extent that CSL contemplates Bluebook support,
the functionality we have implemented here will be required. I would
welcome a discussion of the changes, with a view to including them, or
some concrete alternative, in official CSL. I have no special
attachment to the solutions I have implemented here; but the use cases
do need to be covered.

Here are the changes, and the use cases that they address.

[A] Note number backreferences

Example:

  1. John Doe, The Laws of Lilliput 123 (1900)
  2. Jane Roe, A Lilliputian Disputation (1905)
  3. Doe, supra note 1.

Problem:
The note number is required in the back-reference.

Solution:

Makes sense. Care to propose the comment text for the schema?

[B] Previous reference in same note:

Example:

  1. John Doe, The Laws of Lilliput 123 (1900); Jane Roe, A Lilliputian
    Disputation (1905). Doe relates the laws of Lilliput to those of
    Brobdingnag throughout his work. Doe, supra.

Problem:
The supra reference in this case does not have a note number, because
it is in the same footnote as the target reference.

Solution:
SUPRA TEXT


NOTE TEXT

For this use case, why is this necessary? Variables don’t print if
they’re null, so shouldn’t your case A work for B also?

[C] Reset first reference

  1. Putting Things on Top of Other Things Act sec. 123, 999 USC 234 (1900).
  2. 99 USC 235 (1900).
  3. 99 USC 277 (1900).
  4. 99 USC 255 (1900).
  5. 99 USC 240 (1900).
  6. Putting Things on Top of Other Things Act sec. 124, 99 USC 235 (1900).

Problem:
A statute must be cited with the full form if the short form does not
occur within the last five footnotes. Supra is not used.

Solution:


FULL


SHORT

Might it not better to just add a new option?

Bruce

Oops; no, since it won’t be null.

Bruce

For this use case, why is this necessary? Variables don’t print if
they’re null, so shouldn’t your case A work for B also?

Oops; no, since it won’t be null.

I’ll check, though. It will be zero, which would return false in
the case of , I think. And that would cover
the use case. I’ll give it a whirl and report back.

For this use case, why is this necessary? Variables don’t print if
they’re null, so shouldn’t your case A work for B also?

Oops; no, since it won’t be null.

I’ll check, though. It will be zero, which would return false in
the case of , I think. And that would cover
the use case. I’ll give it a whirl and report back.

D’oh! The distance is zero, but the number is some integer, huh. So
you’re right again of course. There could be a "note-distance"
variable (that’s needed internally for [C] anyway), but I’m not sure
there will be additional use cases that it would be needed for. Hmm.

I have completed a tour through the code of Zotero, tweaking and
extending the code to support the Bluebook style, for use in our
faculty writing programs. Unavoidably, some of the changes have
touched on CSL. To the extent that CSL contemplates Bluebook support,
the functionality we have implemented here will be required. I would
welcome a discussion of the changes, with a view to including them, or
some concrete alternative, in official CSL. I have no special
attachment to the solutions I have implemented here; but the use cases
do need to be covered.

Here are the changes, and the use cases that they address.

[A] Note number backreferences

Example:

  1. John Doe, The Laws of Lilliput 123 (1900)
  2. Jane Roe, A Lilliputian Disputation (1905)
  3. Doe, supra note 1.

Problem:
The note number is required in the back-reference.

Solution:

Makes sense. Care to propose the comment text for the schema?

I’ll get cracking on that right away.

[B] Previous reference in same note:

Example:

  1. John Doe, The Laws of Lilliput 123 (1900); Jane Roe, A Lilliputian
    Disputation (1905). Doe relates the laws of Lilliput to those of
    Brobdingnag throughout his work. Doe, supra.

Problem:
The supra reference in this case does not have a note number, because
it is in the same footnote as the target reference.

Solution:
SUPRA TEXT


NOTE TEXT

For this use case, why is this necessary? Variables don’t print if
they’re null, so shouldn’t your case A work for B also?

Aha! Exactly right. I love it when that happens.

[C] Reset first reference

  1. Putting Things on Top of Other Things Act sec. 123, 999 USC 234 (1900).
  2. 99 USC 235 (1900).
  3. 99 USC 277 (1900).
  4. 99 USC 255 (1900).
  5. 99 USC 240 (1900).
  6. Putting Things on Top of Other Things Act sec. 124, 99 USC 235 (1900).

Problem:
A statute must be cited with the full form if the short form does not
occur within the last five footnotes. Supra is not used.

Solution:


FULL


SHORT

Might it not better to just add a new option?

This applies to statutes only in Bluebook, but if it were used for op
cit. in Chicago, it would apply to everything. Can the effect of an
option be limited a particular item type?

[C] Reset first reference

  1. Putting Things on Top of Other Things Act sec. 123, 999 USC 234 (1900).
  2. 99 USC 235 (1900).
  3. 99 USC 277 (1900).
  4. 99 USC 255 (1900).
  5. 99 USC 240 (1900).
  6. Putting Things on Top of Other Things Act sec. 124, 99 USC 235 (1900).

Problem:
A statute must be cited with the full form if the short form does not
occur within the last five footnotes. Supra is not used.

Solution:


FULL


SHORT

Might it not better to just add a new option?

This applies to statutes only in Bluebook, but if it were used for op
cit. in Chicago, it would apply to everything. Can the effect of an
option be limited a particular item type?

Ugh; no.

Something seems wrong about your proposed solution though. If I look
at that markup, it’s not intuitively obvious to me what “if
reset-first=‘5’” means.

Bruce

PS - I can’t avoid adding that … op cit is evil!

Would something like

FULL SHORT

be clearer?

Rintze

But we might consider if there may be need for other examples, such
that we might have a more generic option like:

… with me not quite sure what “foo” should be called. Kind of
related to previous discussion of the counting case, where we had
proposed attributes like min-value and max-value (or something like
that).

Bruce

Would something like

be clearer?

Problem:
A statute must be cited with the full form if the short form does not
occur within the last five footnotes. Supra is not used.

Solution:

sorry if I jump in this discussion even though I’ve not been following
it very closely, but it is not very clear to me how a CSL
implementation could be aware of something like the footnote number a
citation is occurring in?

Does Zotero support something like this?

Andrea

Just in case Simon is slow to respond re: Zotero-specific details …On Thu, Jan 22, 2009 at 12:54 PM, Andrea Rossato <@Andrea_Rossato1> wrote:

sorry if I jump in this discussion even though I’ve not been following
it very closely, but it is not very clear to me how a CSL
implementation could be aware of something like the footnote number a
citation is occurring in?

I imagine there’d be an array of references somewhere, where one might
annotate those references with additional information (first
reference, year suffix, etc.), and that in such a context would could
note this information?

Might not be as easy with pandoc though :wink:

Bruce

I would like to point out the fact that my implementation is not
pandoc specific. You could use it as a stand alone library to provide
citation formatting for a anything you want (actually I’m planning to
write a small utility to provide a CSL backend that can deal with Open
Document files: you could use a character style to insert citation
keys with OpenOffice and then use citeproc-hs to format them,
similarly to the Zotero plugin)

This is why I fill a bit uncomfortable with this kind of options (the
same for indent option that has been discussed a few line above or
below). I’m really trying to write a library that is not format
specific, but you guys are making it quite a very hard job…:wink:

Andrea

I would like to point out the fact that my implementation is not
pandoc specific. You could use it as a stand alone library to provide
citation formatting for a anything you want (actually I’m planning to
write a small utility to provide a CSL backend that can deal with Open
Document files: you could use a character style to insert citation
keys with OpenOffice and then use citeproc-hs to format them,
similarly to the Zotero plugin)

Cool.

This is why I fill a bit uncomfortable with this kind of options (the
same for indent option that has been discussed a few line above or
below). I’m really trying to write a library that is not format
specific, but you guys are making it quite a very hard job…:wink:

I sympathize. Here’s what I really want: to make you and Frank (and
all the other users who need x or y functionality) happy :slight_smile:

Right now, in the Bluebook style, the output for back-references of
this kind is just a “___”, here the user then has to manually fill
them in when they’re done with their document. So this is the use case
that drives Frank’s proposal, and it’s a reasonable one to
accommodate.

I realize this may not be so easy to implement in all environments,
but it’s not like not implementing it will result in worse output than
what these users currently get.

Bruce

I too want Frank to be happy - I’m a comparative lawyer too and so I
happen to have some familiarity with the Bluebook style, unfortunately
I’d like to add… :slight_smile:

I’ll add a library function that can take some extra information, like
footnote numbers, for environment that could provide it. And I’m sure
I’ll be able to add this support to pandoc too.

Andrea

Yeah, I was thinking you might have such familiarity.

Damn … this is a heinous, sadistic, style! It’s amazing how much
more complex CSL has had to become to accommodate some of the most
widely used styles, where that complexity really has no logical basis
in the 21st century.

But alas, the academy and the legal profession are among the most
conservative of institutions …

Bruce

Would something like

FULL SHORT

be clearer?

From my perspective, yes.

But we might consider if there may be need for other examples, such
that we might have a more generic option like:

… with me not quite sure what “foo” should be called. Kind of
related to previous discussion of the counting case, where we had
proposed attributes like min-value and max-value (or something like
that).

This would be great to have, if “foo” is just variable. The fact that
I like it may cut the other way, though. :slight_smile:

This would open the way to jurisdiction-specific styling. For example:

MACRO FOR VIETNAMESE STATUTES DEFAULT STATUTE MACRO

I’ve been thinking that I’ll want this kind of conditional branching
when I get to statutory material, but I’ve also been thinking that the
structure of the style code could run out of control if you weren’t
careful – instead of puzzling over exceptional cases, having a
discussion, and coming up with a minimal solution, I could just add
some stringy code to the style for each case (and then add some more,
and then …).

Not sure what Simon will say about this idea; but if used carefully,
it certainly would add a welcome flexibility. Personally, I’m very
much in favour. Andrea? Other folks?

Just in case Simon is slow to respond re: Zotero-specific details …

sorry if I jump in this discussion even though I’ve not been following
it very closely, but it is not very clear to me how a CSL
implementation could be aware of something like the footnote number a
citation is occurring in?

I imagine there’d be an array of references somewhere, where one might
annotate those references with additional information (first
reference, year suffix, etc.), and that in such a context would could
note this information?

That’s the deal. Zotero proper can’t do this yet, but it turns out to
be not too difficult, with one little caveat.

There are clustered references in an author-date style. (Smith 1990;
Jone 2000). In a footnote style, Zotero pushes those references into
a single note. (The naming of the internal variables in the Zotero
source code is a little confusing; the cluster is “Citation”, and the
individual references are “Item”.) In our local implementation of Z,
during the scan of the document each Item object is stamped with its
own cluster number (“thisRef”) and the cluster number of the first
reference (“firstRef”). When the Items are passed to the CSL
processor, “firstRef” provides the note number for a supra
back-reference, and “thisRef” is used with a fresh array inside the
CSL processor (“lastFirstRef”) to calculate the elapsed distance to
the nearest full citation generated. Our toy implementation is here:

http://gsl-nagoya-u.net/appendix/software/bluebook

(Be sure to run this one in a clean Firefox profile, it touches some
of the system tables.)

So it’s pretty simple when all is said and done, but it does assume
that item clusters == footnotes. In our case, I’ll just caution my
students that they should create all of their footnotes as Zotero
references, and steer clear of the Insert -> footnote menu item in
their word processors when they are using Zotero.

So it’s pretty simple when all is said and done, but it does assume
that item clusters == footnotes. In our case, I’ll just caution my
students that they should create all of their footnotes as Zotero
references, and steer clear of the Insert -> footnote menu item in
their word processors when they are using Zotero.

But WRT to the other discussion on zotero-dev, I keep finding myself
confused by your description of this. :wink:

Why would you tell your students not to use insert --> footnote when
there are times an author legitimately wants to write a footnote that
just happens to include one or more citations, and that this is a
different case than the normal case of citations that refer to in-text
content but which get rendered as footnotes.

Or is this just not the case for law people; that if you were to use a
different style you’d expect all those citations to be rendered
in-text?

Bruce

So it’s pretty simple when all is said and done, but it does assume
that item clusters == footnotes. In our case, I’ll just caution my
students that they should create all of their footnotes as Zotero
references, and steer clear of the Insert -> footnote menu item in
their word processors when they are using Zotero.

But WRT to the other discussion on zotero-dev, I keep finding myself
confused by your description of this. :wink:

I’m not a model of clarity – but I try to make up for it with enthusiasm! :-/

Why would you tell your students not to use insert --> footnote when
there are times an author legitimately wants to write a footnote that
just happens to include one or more citations, and that this is a
different case than the normal case of citations that refer to in-text
content but which get rendered as footnotes.

Or is this just not the case for law people; that if you were to use a
different style you’d expect all those citations to be rendered
in-text?

It’s kind of a mix of practice and principle at the moment.
Practically, the Zotero CSL processor still gets back-references wrong
when reference items are inserted into a user-created footnote. This
isn’t specific to Bluebook, you can test it with the Chicago note
style. Create a footnote, enter some text, create a reference to
Smith before the text, create another reference to Smith after the
text. Hit the Zotero refresh button, and boom: the FIRST cite becomes
"Ibid." and the second becomes the full cite to Smith. I don’t even
want to think about explaining that result to a student.