The CITE Architecture Technology-independent, machine-actionable citation of scholarly resources

New OHCO2 library

ohco2 is a library for working with citable texts. Like the xcite library announced yesterday, the 3.x series of ohco2 is cross-compiled for both the JVM and ScalaJS using scala versions 2.10, 2.11 and 2.12, and is therefore available for JVM environments and for use in javascript compiled with ScalaJS.

Version 3.1 adds the twiddle operator ~~ for URN matching on corpora of texts. In xcite, twiddling two URNs is a boolean function, e.g.,

val iliad = CtsUrn("urn:cts:greekLit:tlg0012.tlg001:")
val venetusA = CtsUrn("urn:cts:greekLit:tlg0012.tlg001.msA:")
assert (iliad ~~ venetusA)

In ohco2, twiddling a corpus with a URN is a functio mapping the corpus to a (possibly empty) new corpus of text contents with matching URN, e.g., you could select the text of the Venetus A edition of the Iliad by twiddling a larger corpus like so:

val corpus = Corpus("YOURDATASET...")
val vaText = corpus ~~ venetusA

Binaries for all platforms are available from jcenter ( Source code is hosted on github (