bible-technology / scripture-burrito

Scripture Burrito Schema & Docs 🌯
http://docs.burrito.bible/
MIT License
21 stars 13 forks source link

JSON representation of VRS needs to handle one-to-many mappings #253

Closed mvahowe closed 3 years ago

mvahowe commented 3 years ago

Right now the mapping section of the "vrs-as-json" schema looks something like this:

        "mappedVerses": {
            "propertyNames": {
                "$ref": "#/definitions/bcvRange"
            },
            "additionalProperties": {
                "$ref": "#/definitions/bcvRange"
            }
        },

I don't think this handles one-to-many mappings, eg

PSA 51:0 = PSA 51:1
PSA 51:0 = PSA 51:2

In this case we have one property but need to represent two BCV ranges. This happens in standard versifications, and happens a lot more when mappings are reversed. Something like

PSA 51:0 = PSA 51:1-2

will create problems since existing VRS logic says that ranges have the same number of verses on each side.

I think that the cleanest way to address this is to make the properties an array of BCV ranges. (In the majority of cases there would be exactly one BCV range in each array.)

jag3773 commented 3 years ago

@jonathanrobie Can the versification working group take a look at this?

jonathanrobie commented 3 years ago

Moved to https://github.com/Copenhagen-Alliance/versification-specification/issues/16

jag3773 commented 3 years ago

Looks like it's actually at https://github.com/Copenhagen-Alliance/versification-specification/issues/15, closing this for now.