Coder Social home page Coder Social logo

Comments (9)

emylonas avatar emylonas commented on June 25, 2024

The bibliography, as it is now displayed, is not formatted properly. In the example below, from
https://library.brown.edu/iip/viewinscr/caes0305/ , shows a full bibliographic entry (the second part of bibliography, at the bottom right of the page.) You will see that there is the text (IIP-068) right before "American Schools of Oriental Research" That shouldn't be there. I'm not even sure that we want to keep the bibliographic IIP id, but if we do, it should appear after "American Schools of Oriental Research" and be greyed out or otherwise not prominent. The bibliographic entry is retrieved from the Zotero API, and then some regular expressions are used to further format/massage the text. The bibliographic IIP id is probably added, or not removed, at that point. The bibliographic ID is a tag in Zotero that uniquely identifies an entry.

So we need to find where the bibliograhic entry is retrieved from Zotero and further processed.

Lehmann, C. M., & Holum, K. G. (2000). The Greek and Latin Inscriptions of Caesarea Maritima. In Joint Expedition to Caesarea Maritima Excavation Reports, vol. 5 (IIP-068). American Schools of Oriental Research. ( p. plate CXLV, no. 305 ) (See in Zotero)

from iip-production.

atbradley avatar atbradley commented on June 25, 2024

@emylonas Are all these "IIP-nnn" numbers 3 digits? If they're sometimes more or less, I'll need to make a minor change to this fix.

from iip-production.

emylonas avatar emylonas commented on June 25, 2024

@atbradley The bibliographic IDs are always IIP-000 (three numbers). We may have to change this in the future, but you could throw caution to the winds and use an expression like "IIP-\d+" because it's unlikely to be anything else than the bibID.

from iip-production.

atbradley avatar atbradley commented on June 25, 2024

@emylonas I was looking at a page like akld0003, where there's a page reference along with the IIP number: "(IIP-053; pp. 57–72)". On the assumption we don't need those page numbers, I used /\ \(IIP-\d{3}.*?\)/. If we do, I can change it.

from iip-production.

emylonas avatar emylonas commented on June 25, 2024

@atbradley I have found 2 cases.

  1. https://library.brown.edu/iip/viewinscr/idum0047/, the bibliography appears as follows:
Porten, B., & Yardeni, A. (2014). Textbook of Aramaic Ostraca from Idumea. Volume 1. Dossiers 1-10: 401 Commodity Chits. (IIP-555). Eisenbrauns.
(See in Zotero)
( A1.47 )

This comes from a Zotero citation of a book. In this case, the string to remove is \(IIP-\d+\) or \(IIP-\d{3}\)

  1. https://library.brown.edu/iip/viewinscr/bshe0015/ where the bibliography appears as follows: ```
    Lifshitz, B. (1974). The Ancient Synagogue of Hamat-Tiberias, its Floor and Inscriptions. In B. Oded, U. Rappaport, A. Shochat, & J. Shatzmiller (Eds.), Studies in the History of the Jewish People and the Land of Israel (IIP-579; Vol. 3, pp. 99–109). University of Haifa.
    (See in Zotero)
    ( 46-7 )
This comes from the Zotero citation of a book section and seems to want to provide the page range. Unfortunately, I think in this case, you are looking for something like:  `(\()]IIP-\d{3}; ([^\)]\))` and returning `\1\2` - basically matching the whole expression in the parentheses that contains `IIP-\d{3}; ` and then writing out the parts that remain after you've removed that string. 

Ugh. I don't know why Zotero wants to include the archive location information as part of this information. It makes no sense at all. 

Maybe you could check what bibliographic format we are exporting, because I just tried a regular Chicago author date export from the Zotero app. and got no strange results at all. 

from iip-production.

atbradley avatar atbradley commented on June 25, 2024

My current fix is two steps:

  1. Remove /IIP-\d{3}\;\ /, so the page numbers (if they exist) still appear.
  2. Remove /\(IIP-\d{3}\)/, to remove all trace of any IIP references without page numbers.

Maybe you could check what bibliographic format we are exporting, because I just tried a regular Chicago author date export from the Zotero app. and got no strange results at all.

Looks like we're exporting APA style citations:

req.open("GET", "https://api.zotero.org/groups/" + GROUP + "/items?tag=" + ztag + "&include=bib" + "&style=apa", true);

According to the docs, Chicago style references are the default, so removing the &style=apa bit from the URL should give us Chicago style data. This seems hit-or-miss.

https://api.zotero.org/groups/180188/items?tag=IIP-579&include=bib doesn't include an IIP reference number in the bibliography (the version we're currently displaying has one, with a page reference):

Lifshitz, Baruch. “The Ancient Synagogue of Hamat-Tiberias, its Floor and Inscriptions.” In Studies in the History of the Jewish People and the Land of Israel, edited by B. Oded, U. Rappaport, A. Shochat, and J. Shatzmiller, 3:99–109. Haifa: University of Haifa, 1974.

https://api.zotero.org/groups/180188/items?tag=IIP-563&include=bib does include one, at the end, without a page reference:

Di Segni, Leah. “Dated Greek Inscriptions from Palestine from the Roman and Byzantine Periods.” PhD Dissertation, Hebrew University, 1997. (IIP-563).

I've updated the dev instance to use Chicago citations and left my other fixes in place. This works fine on the pages I've checked.

from iip-production.

emylonas avatar emylonas commented on June 25, 2024

done, @emylonas has to check and approve.

from iip-production.

emylonas avatar emylonas commented on June 25, 2024

@atbradley this looks great and should go live.

from iip-production.

atbradley avatar atbradley commented on June 25, 2024

It's now live.

from iip-production.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.