citation-style-language / locales

Official repository for Citation Style Language (CSL) locale files.
https://citationstyles.org/
140 stars 198 forks source link

Duplicate terms: "book", "chapter", etc #268

Closed zepinglee closed 2 years ago

zepinglee commented 2 years ago

I just find book and chapter terms are used as both item types and locators in locale files. For example:

https://github.com/citation-style-language/locales/blob/62dcca65d754b5e603750838e909a5e90c32e3cc/locales-en-US.xml#L108

https://github.com/citation-style-language/locales/blob/62dcca65d754b5e603750838e909a5e90c32e3cc/locales-en-US.xml#L248-L251

The duplicate term definition may cause unexpected result in citeproc output. Here is the full list of duplicate terms: interview, book, chapter, book,form:short, and chapter,form:short.

Additionally, PR #254 fixed missing form="short" attribute in only en-US and en-GB but the missing attributes in other languages cause duplicates. I'm happy to make a PR to resolve them.

bwiernik commented 2 years ago

Ah, yeah, that's right. They should be removed from the item types list and a note like the one for figure added in their places

denismaier commented 2 years ago

Can we let the other locales automatically inherit these changes?

bwiernik commented 2 years ago

Not sure what you mean. If they are defined in the other locales, they should be removed there too

denismaier commented 2 years ago

Sure. But can we automate this process?

zepinglee commented 2 years ago

Ah, yeah, that's right. They should be removed from the item types list and a note like the one for figure added in their places

Another approach is appending a -locator suffix like article-locator.

https://github.com/citation-style-language/locales/blob/62dcca65d754b5e603750838e909a5e90c32e3cc/locales-en-US.xml#L103

https://github.com/citation-style-language/locales/blob/62dcca65d754b5e603750838e909a5e90c32e3cc/locales-en-US.xml#L212-L215

denismaier commented 2 years ago

Yes. I don't remember, but was there a specific reason we did not do that for figure?

bwiernik commented 2 years ago

The item type and locator "figure" are literally the same object. The same would apply to chapter presumably. Book, I'm not sure--in German, if I cited "author, year, Book 2" is that the same term as for "a book"?

zepinglee commented 2 years ago

The item type and locator "figure" are literally the same object. The same would apply to chapter presumably. Book, I'm not sure--in German, if I cited "author, year, Book 2" is that the same term as for "a book"?

It seems that the "book" locator is only used in legal areas (e.g., Civil Code of China).

bwiernik commented 2 years ago

It's also used, eg, in classics and religious studies research

denismaier commented 2 years ago

The item type and locator "figure" are literally the same object. The same would apply to chapter presumably. Book, I'm not sure--in German, if I cited "author, year, Book 2" is that the same term as for "a book"?

You mean as "a book" as opposed to e.g. "a webpage"? Then yes, it would be "Buch" in both cases.

denismaier commented 2 years ago

But that should be solved by #269 right?

denismaier commented 2 years ago

It's also used, eg, in classics and religious studies research

Also philosophy.

bwiernik commented 2 years ago

But that should be solved by #269 right?

Yes, and it seems there is no need for separate book and book-locator terms