Category Archives: Posts

Scraping XML from CAMENA

CAMENA – Latin Texts of Early Modern Europe was a great project at the University of Mannheim. The project ended in 2011, making available many thousands of pages of Neo-Latin texts, not only by German authors. Some of the texts are available in a machine-readable XML form, though (as the project carefully warns) the texts were not fully corrected, and are therefore to be considered as “raw material”. All material produced by CAMENA is available under a CC-BY-SA Open License.

CAMENA Thesaurus logo

An opportunity to experiment with a large collection of Neo-Latin XML is for us immensely attractive; we can use everything we had learned and developed for the Croatica et Tyrolensia project on other material.

The first step is, however, to collect machine-readable files of CAMENA. As its interface was designed more like a library than a database — perfect for reading, but less suited for other analytical approaches — finding all XML files (or, as will be seen, at least all that we could get) was a time-consuming operation.

We solved it by writing two Python scripts to scrape CAMENA’s index pages for links to their XML. The scripts can be seen as Github gists: Script 1 (which downloads XML files) and Script 2 (which only writes XML links to a file; the links are downloaded by a Linux Bash command such as wget -nd -i ../listthes2.txt).

The other approach — just collecting the links — enabled us to remove duplicates (CAMENA texts sometimes come from the same book, so the links point to thesame document).

There were some links which had to be corrected by hand, however, and some links which we were not able to retrieve at all. We also did not try to download page images (this time).

The textual part of CAMENA which is retrievable in XML consists of four collections (CERA, Historica et politica, Poemata, Thesaurus; the ITALI collection seems to lack any machine-readable XML), with ca. 1751 XML files.

We plan to publish here the full list of CAMENA XML links, and the files themselves.

Analysing XML with BaseX

TEI XML, often used for encoding texts in the humanities, actually carries in its elements certain semantic load. This means that just knowing which elements are used for encoding a file could provide some basic information about the file and its salient points.

We decided to experiment with two XQuery functions. One, currently called croala-analist, lists all documents in a database, e. g. for the database latty: latty. At the same time, as an orientational help, the function lists number of distinct elements used for encoding; e. g. there are eight different elements in the text part of the document putsch-c-brevis.xml.

The other function provides information on distinct elements: in XML/XPath parlance, who are their parents and their children, and how many occurrences of a certain element there are in the document. Here is the information for a latty document mentioned above: putsch-c-brevis.xml.

Joe Futrelle, "Guernica" (from Flickr)
Joe Futrelle, “Guernica” (from Flickr)

An additional challenge for our coding skills was making these functions as general as possible, i. e. applicable to all databases on our server. The two functions can be found inside the croala.xqm module in our Bitbucket repository (croalatransform / plutonbasex / repo /); functions are croala:analist and croala:anatomia.

Papers connected with Croatia in the IANLS 2015 Vienna conference


From the rich programme of the IANLS 2015 conference we have culled abstracts of twelve papers connected with Croatia, or neighbouring regions. Members of the Croatica et Tyrolensia project are strongly represented.

Dominik Bartsch, Lonely walk at Schönbrunn, Vienna  View from Neptune's fountain to Schönbrunn Castle, Vienna.
Dominik Bartsch,
Lonely walk at Schönbrunn, Vienna
View from Neptune’s fountain to Schönbrunn Castle, Vienna.

Continue reading Papers connected with Croatia in the IANLS 2015 Vienna conference

Technical note: installing PhiloLogic 4 on localhost

PhiloLogic, developed by the ARTFL Project and the Digital Library Development Center at the University of Chicago, is an excellent system for serving and querying XML texts. CroALa and LatTy are currently deployed using PhiloLogic 3, but version 4 is almost ready to be published; try it out on Github (

Some notes on how we tried — and, thanks to PhiloLogic 4 developers, also succeeded — to get PhiloLogic 4 working and serving Croatian Latin texts on a local machine (localhost in computer networking parlance) are published on the Croatica et Tyrolensia wiki:

Philologia Latina

Technical note: XSLT to number elements consecutively across parent elements

What follows is a solution to an XSLT problem.

The problem: in an XML document, we want to number consecutively elements which share a grandparent element, but not parent. The document contains multiple grandparents. In each we want to restart the counter (imagine a book with chapters which have section; we want to number paragraphs of each chapter consecutively, but across sections: Chapter 1 / Section 1 / Para 1 , Para 2 / Section 2 / Para 3, Para 4 / Chapter 2 / Section 1 / Para 1, Para 2 / Section 2 / Para 3 , Para 4 /).

We want to accomplish this with an XSLT stylesheet.

Short answer: add counts of all preceding paras in sections and preceding paras in current section; subtract the count of all preceding paras in other chapters, and add 1. Like this:

count(preceding::section/para) +
count(preceding-sibling::para) -
count(preceding::chapter/section/para) + 1

For a long answer, read more here: z:xslt-number.

CroALa i CroTyr na festivalu (digitalizacije)

Željka Salopek, voditeljica stručne zbirke klasične filologije u Knjižnici Filozofskog fakulteta Sveučilišta u Zagrebu i suradnica projekta Croatica et Tyrolensia, predstavila je naš projekt na Petom festivalu hrvatskih digitalizacijskih projekata i objavljuje o tome kratak izvještaj.

Salopek izlaganje

U Nacionalnoj i sveučilišnoj knjižnici u Zagrebu od 20. do 21. ožujka 2015. održan je jubilarni, 5. festival hrvatskih digitalizacijskih projekata. Ovogodišnja su izlaganja bila iz područja digitalne humanistike, autorskog prava, korištenja digitalne kulturne baštine i digitalizacije specifičnih vrsta građe.

Naglašene su promjene koje digitalna građa unosi u istraživanja u humanistici te mogućnost interdisciplinarne suradnje u digitalizacijskim projektima. Upozoreno je na važnost kvalitetnog menadžmenta tih projekata. Iskustva gotovih digitalizacijskih projekata pokazala su koliko je digitalizacija danas važna u očuvanju i predstavljanju kulturne i znanstvene baštine.

Tema drugog dana festivala bila su autorska prava i prava korisnika u digitalnom okruženju. Rasprave te brojna pitanja nakon izlaganja istakla su potrebu za boljim smjernicama za primjenu i zaštitu ovih prava.

U izlaganju pod naslovom Pet godina zbirke Croatiae auctores Latini i prva godina projekta Croatica et Tyrolensia sudionike smo bolje upoznali s rastućom zbirkom CroALa (koja već broji 451 tekst 194 autora) te predstavili prve bibliografske i tekstualne rezultate projekta. Prikazali smo i tehnološku pozadinu zbirke te proces nastanka, označavanja i objave digitalnih tekstova. (Prezentaciju s izlaganja moguće je naći na stranicama festivala [PDF].)

CroALa se već šestu godinu upotpunjuje digitalnim izdanjima djela hrvatskih latinista nastalim u sklopu raznih domaćih i međunarodnih projekata. Već šestu godinu služi kao referentno mjesto i istraživački alat znanstvenicima koji se u svom radu koriste tim tekstovima. Osim toga, ima i njen velik potencijal u učenju latinskog jezika.

Continue reading CroALa i CroTyr na festivalu (digitalizacije)

Špoljarić on politics, patronage and intellectual culture at the Hungarian court

The volume 38 of Građa za povijest književnosti hrvatske (Materials for Croatian literary history), published by the Croatian Academy of Sciences and Arts, appeared recently. The long-awaited volume presents an impressive selection of writings by past Croatian authors in Latin, Italian, Croatian, and German (including Croatian translations and paraphrases from Italian and Latin); most of the texts are edited from manuscripts, and appear in critical editions. The earliest work in this volume is the Navicula Petri, a short theological treatise composed during summer of 1463 by Nicholas bishop of Modruš, and edited by our own Croatica et Tyrolensia postdoc, Luka Špoljarić. For the blog, Luka has provided a summary of his contribution.

Remains of the city of Modruš on a drawing from the 17th century.
Remains of the city of Modruš on a drawing from the 17th century.

Politics, Patronage and Intellectual Culture at the Hungarian Court in the First Years of Matthias Corvinus’ Reign: Nicholas of Modruš and Peter’s Barge (Study, Critical Edition and Translation)

The article presents a new critical edition accompanied by a facing Croatian translation of Peter’s Barge (Navicula Petri), a theological treatise on the problem of physical evil composed by Nicholas bishop of Modruš (ca. 1425–1480). Nicholas was a Croatian Renaissance prelate who enjoyed close contacts with the court of the Hungarian king Matthias Corvinus (1458–1490) before embarking on a successful career at the papal Curia. The edition is based on the sole extant witness of the text, preserved as part of a fifteenth-century miscellany located in the Archive of the Croatian Academy of Sciences and Arts (AHAZU) under shelfmark II.b.3. Two earlier editions of the work (Veličan 1999; Hrkać 2006) are not only marred by errors in transcription, but have moreover failed to recognize two major scribal errors and have thus included not the end of Peter’s Barge but the end of Leonardo Bruni’s Short Oration before Pope Martin V, the work which follows in the manuscript. The critical edition presented here corrects the transcription errors of previous editions, includes for the first time the ending of the work which can be found two folios further in the manuscript, and establishes the original sequence of
this final portion of the text.

Continue reading Špoljarić on politics, patronage and intellectual culture at the Hungarian court

Croatica et Tyrolensia u godišnjem planu rada NSK Zagreb (za 2014)

Na svoje smo zadovoljstvo nedavno otkrili da je planom rada NSK Zagreb za 2014. (PDF) predviđena suradnja s projektom Croatica et Tyrolensia:

Planira se uključivanje u rad na projektu Croatica et Tyrolensia 2013. – 2015. koji je pokrenut radi prikupljanja i objavljivanja latinskih tekstova u tiskanome i elektroničkome obliku te stvaranja digitalne bibliografije hrvatskih latinista. Osim Filozofskoga fakulteta u Zagrebu, koji je i pokretač projekta, u njem sudjeluju Institut für neulateinische Studien u Innsbrucku, Sveučilište Jurja Dobrile u Puli te Marulianum u Splitu.

Naravno, od početka projekta teče naša suradnja s knjižničarkom NSK dr. sc. Irenom Galić Bešker, koja za Croatica et Tyrolensia sastavlja tipologiju žanrova hrvatskog latinizma (usp. radni nacrt za epiku i njezine podžanrove). No, ugodno je naći trag te suradnje u službenom dokumentu.

Auctores per saecula

Quot auctores Croati, nobis noti et a nobis annotati, Latine scripserint oratione soluta, quot autem scripserint versus, inveniri potest (ope programmatum XQuery et BaseX) in pagina sequenti: croalabib-gen-saec.

How many Croatian authors wrote Latin prose, how many wrote verse? The answer, at least for those annotated in our database, can be found (via XQuery and BaseX XML database) on the following page: croalabib-gen-saec.

Razmilović, a Latin elegy
Beginning of an elegy written and transcribed by Bonaventura Razmilović, Split, c. 1650.

Croatica et Tyrolensia

Notes and news about the research project Croatica et Tyrolensia (2013-2015), a cooperation of University of Zagreb (Croatia), Ludwig Boltzmann Institute of Neo-Latin Studies (Innsbruck, Austria), Juraj Dobrila University Pula (Croatia) and Marulianum – Split Literary Circle (Split).