Tiny Example

From LMNLWiki

A minimalistic example of LMNL showing overlapping ranges.

This is intended to show the basic syntax in concise form, but does not demonstrate advanced features such as empty ranges, atoms, complex structured annotations, or arbitrary mixing ("self-overlap"). For those, see other examples, especially the Exercise Example.

Note: whitespace has been altered for legibility. These examples do not demonstrate tag fidelity and they won't transpose properly into one another due to variations in whitespace. Otherwise, they are the same document.

Needed on this page: links to the specs.

Contents

LMNL (sawtooth) syntax

[excerpt [source}The Housekeeper{source] [author}Robert Frost{author]}
[s}[l [n}144{n]}He manages to keep the upper hand{l]
  [l [n}145{n]}On his own farm.{s] [s}He's boss.{s] [s}But as to hens:{l]
  [l [n}146{n]}We fence our flowers in and the hens range.{l]{s]
{excerpt]

ECLIX syntax

<excerpt xmlns:c="http://lmnl.net/clix"
  source="The Housekeeper" author="Robert Frost">
  <l n="144">
    <s c:sID="s1"/>He manages to keep the upper hand</l>
    <l n="145">On his own farm.<s c:eID="s1"/>
    <s c:sID="s2"/>He's boss.<s c:eID="s2"/>
    <s c:sID="s3"/>But as to hens:</l>
    <l n="146">We fence our flowers in and the hens range.<s c:eID="s3"/></l>
</excerpt>

CLIX syntax

<c:clix xmlns:c="http://lmnl.net/clix">
  <excerpt c:sID="clix:excerpt-1">
    <source>The Housekeeper</source>
    <author>Robert Frost</author>
  </excerpt>
  <l c:sID="clix:l-1">
    <n>144</n>
  </l>
  <s c:sID="s1"/>
  He manages to keep the upper hand
  <l c:eID="clix:l-1"/>
  <l c:sID="clix:l-2">
    <n>145</n>
  </l>
  On his own farm.
  <s c:eID="s1"/>
  <s c:sID="s2"/>
  He's boss.
  <s c:eID="s2"/>
  <s c:sID="s3"/>
  But as to hens:
  <l c:eID="clix:l-2"/>
  <l c:sID="clix:l-3">
    <n>146</n>
  </l>
  We fence our flowers in and the hens range.
  <s c:eID="s3"/>
  <l c:eID="clix:l-3"/>
  <excerpt c:eID="clix:excerpt-1"/>
</c:clix>

An alternative ECLIX rendering

Note that construed as flat LMNL, this is the same document; but its XML form shows an alternative hierarchy.

<excerpt xmlns:c="http://lmnl.net/clix"
  source="The Housekeeper" author="Robert Frost">
  <s>
    <l c:sID="clix:l-1" n="144"/>
    He manages to keep the upper hand
    <l c:eID="clix:l-1" n="144"/>
    <l c:sID="clix:l-2" n="145"/>
    On his own farm.
  </s>
  <s>He's boss.</s>
  <s>
    But as to hens:
    <l c:eID="clix:l-2" n="145"/>
    <l c:sID="clix:l-3" n="146"/>
    We fence our flowers in and the hens range.
    <l c:eID="clix:l-3" n="146"/>
  </s>
</excerpt>