diff options
| author | Ralph Amissah <ralph.amissah@gmail.com> | 2026-09-29 14:02:30 -0400 |
|---|---|---|
| committer | Ralph Amissah <ralph.amissah@gmail.com> | 2026-10-12 21:48:46 -0400 |
| commit | 7532a04beb6f51665011cf3117d2b29c651a3442 (patch) | |
| tree | 0c7a9fb53724ed3648399c5994156a71df915a9a /ocda-model.md | |
| parent | derived values that the model left unstated (diff) | |
format 2.1: on poems and editor's notesHEADmainclaude-check-main
- editor's notes:
Updated here, spine now apart from author's notes recognises existing
markup's editor's notes, ~[* ]~ and ~[+ ]~, and writes them as notes
of their own numbered series: *1, *2 ... and +1, +2 ... document.
- a poem is a container of its verse:
.ocn_range, the first and last ocn of what a container holds, as one
.ssp property and two .ocda.db columns. A poem is the one container:
its verses are the citable units rather than the poem. A poem now
comes before its first verse, carries ocn 0 and no identifier, and
states the range, where it came after its last verse carrying that
verse's ocn and identifier.
So the model can now say that a non-zero ocn is unique within a
document, and does, keeping the older rule for artefacts written
before 2.1. A minor bump: an addition, a poem was never rendered and
has no text, the verses are unchanged, and a 2.0 reader reads a 2.1
file.
The property-count table is recounted over the regenerated reference
set, the method first checked against the old set, which it reproduces.
The one new endnote, a note in a poem's last verse now gathered,
accounts for the other moved counts; the poems' segment names account
for .segment_html_is and .segment_epub_is.
(assisted by Claude-Code)
Diffstat (limited to 'ocda-model.md')
| -rw-r--r-- | ocda-model.md | 65 |
1 files changed, 39 insertions, 26 deletions
diff --git a/ocda-model.md b/ocda-model.md index 065677a..1c173b1 100644 --- a/ocda-model.md +++ b/ocda-model.md @@ -55,24 +55,24 @@ An object is classified twice, and the two answer different questions. **Kind** (`is_a`) says *what the object is*, one of sixteen. Each kind belongs to one section, except `heading`, which appears in all nine: -| kind | section | what it is | count | -|----------------|--------------|----------------------------------------------|--------| -| `para` | body | a paragraph, the ordinary unit of a document | 41,885 | -| `heading` | *all nine* | a heading at one of the eight levels | 3,503 | -| `toc` | toc | an entry in the generated table of contents | 3,215 | -| `bookindex` | bookindex | an entry in the generated book index | 3,034 | -| `endnote` | endnotes | a note, gathered from where it was called | 2,158 | -| `code` | body | a code block | 1,623 | -| `bibliography` | bibliography | a bibliography entry | 585 | -| `comment` | body | markup comment, carried and not rendered | 450 | -| `verse` | body | one verse of a poem | 151 | -| `glossary` | glossary | a glossary entry | 56 | -| `quote` | body | a block quotation | 53 | -| `poem` | body | a poem, holding verses | 48 | -| `block` | body | a block of grouped text | 45 | -| `table` | body | a table, with its columns described | 32 | -| `blurb` | blurb | a blurb entry | 28 | -| `group` | body | a group block | 16 | +| kind | section | what it is | count | +|----------------|--------------|--------------------------------------------------------------------------------|--------| +| `para` | body | a paragraph, the ordinary unit of a document | 41,885 | +| `heading` | *all nine* | a heading at one of the eight levels | 3,503 | +| `toc` | toc | an entry in the generated table of contents | 3,215 | +| `bookindex` | bookindex | an entry in the generated book index | 3,034 | +| `endnote` | endnotes | a note, gathered from where it was called | 2,294 | +| `code` | body | a code block | 1,623 | +| `bibliography` | bibliography | a bibliography entry | 585 | +| `comment` | body | markup comment, carried and not rendered | 450 | +| `verse` | body | one verse of a poem | 151 | +| `glossary` | glossary | a glossary entry | 56 | +| `quote` | body | a block quotation | 53 | +| `poem` | body | a poem: the container of its verses, OCN `0`, cited as their range (section 5) | 48 | +| `block` | body | a block of grouped text | 45 | +| `table` | body | a table, with its columns described | 32 | +| `blurb` | blurb | a blurb entry | 28 | +| `group` | body | a group block | 16 | **Type** (`is_of_type`) says *how the object's text behaves*, and takes only three values: @@ -107,9 +107,12 @@ otherwise: document reference collection. - **`0` is therefore not an identity.** Objects sharing `0` are not the same object, and `0` must never be used as a key. -- **An OCN is not unique within a document even when non-zero.** A poem and - its verses share one; `through_the_looking_glass` has 21 such cases. Key - on position within a section when one row is wanted. +- **A non-zero OCN is unique within a document**, from format 2.1: checked + over the reference collection, no non-zero OCN occurs twice in any of the + 36 document-languages. **Before 2.1 it was not**: a poem carried the OCN of + its last verse, so the same number named two objects (48 such pairs in the + collection, 21 in `through_the_looking_glass`). A reader of an older + artefact keys on position within a section when one row is wanted. ### 3.1 The identifier @@ -181,6 +184,16 @@ be flat and the model be walked in either direction. - **`last_descendant`** - the last OCN under a heading, which makes a subtree a **range** rather than a traversal: everything from the heading's OCN to its last descendant is inside it. +- **`ocn_range`** - for a **container**, the first and last OCN of what it + holds (2.1). A poem is the one container: its verses are the citable + units, one object each, and the poem is not; it carries OCN `0` and no + identifier, **comes immediately before its first verse**, and is cited as + the range of them (`173-180`). So a writer that meets a poem knows what + follows and where it ends, and can wrap the verses in one pass. The poem + has no text of its own. `0 0`, or absent, where the object is not a + container. + **Before 2.1** the poem came *after* its last verse, carried that verse's + OCN and identifier, and stated no range. ## 6. Sections @@ -263,11 +276,11 @@ document. So, on loading: -| field | when absent | take | -|-------|-------------|------| -| identifier | OCN is non-zero | the OCN as text | -| identifier | OCN is `0` | whatever the serialisation gave; there is nothing to derive from | -| anchor | the object has a segment | the segment name | +| field | when absent | take | +|------------|--------------------------|------------------------------------------------------------------| +| identifier | OCN is non-zero | the OCN as text | +| identifier | OCN is `0` | whatever the serialisation gave; there is nothing to derive from | +| anchor | the object has a segment | the segment name | **This is a property of the model, not of either format**, which is why it is stated here and not only in the two format specifications. It is stated |
