<?xml version="1.0" encoding="UTF-8"?>
<?oxygen RNGSchema="tei_odds.rng" type="xml"?>
<TEI xmlns="http://www.tei-c.org/ns/1.0" xmlns:rng="http://relaxng.org/ns/structure/1.0" xml:lang="en">
 <teiHeader>
  <fileDesc>
   <titleStmt>
    <title>Customization of TEI schema for NKJP (structural level), version 0.4.5</title>
    <author>Piotr Bański and Adam Przepiórkowski</author>
   </titleStmt>
   <publicationStmt>
    <availability status="restricted">
     <p>This template file is not freely available until it gets released in the (pre)final form.</p>
    </availability>
   </publicationStmt>
   <sourceDesc>
    <p>Based on "TEI for Corpora" by Sebastian Rahtz</p>
   </sourceDesc>
  </fileDesc>
 </teiHeader>
 <text>
  <body>
   <head>NKJP Corpus -- schema for the structural layer</head>
   <p>This is the schema for the structural layer of the NKJP corpus (http://www.nkjp.pl/).</p>
   <list type="glossed" n="changelog">
    <item>
     <label>Version 0.1</label>
     <list type="bulleted">
      <item>Removed the "corpus", "linking" and "namesdates" modules.</item>
      <item>Added XLink attributes to <gi>p</gi>.</item>
      <item>Removed <gi>typeNote</gi> from the header module.</item>
      <item>Restricted the root to <gi>teiCorpus</gi>.</item>
     </list>
    </item>
    <item>
     <label>Version 0.2, 22 May 2009</label>
     <list type="bulleted">
      <item>Modified the header: <gi>category</gi> can now contain a sequence of <gi>catDesc</gi>, rather than just a single instance of it.</item>
      <item>Added modules "corpus" and "namesdates", for <gi>particDesc</gi> and <gi>listPerson</gi>.</item>
     </list>
    </item>
    <item>
     <label>Version 0.3, 21 July 2009</label>
     <list type="bulleted">
      <item>AP: Added <gi>nkjp:topic</gi> to the header.</item>
      <item>AP: Added the @nkjp:subcorpus attribute to the header.</item>
      <item>AP: Added the required attribute @nkjp:file to the header element <gi>extent</gi>.</item>
      <item>AP: Added the "spoken" module for <gi>recordingStmt</gi>.</item>
     </list>
    </item>
    <item>
     <label>Version 0.3.1, 29 July 2009</label>
     <list type="bulleted">
      <item>AP: Removed <att>xlink:href</att>, as TEI's own <att>corresp</att> may be used for the same purpose.</item>
     </list>
    </item>
    <item>
     <label>Version 0.4, 01 August 2009</label>
     <list type="bulleted">
      <item>AP: Introduced <gi>nkjp:fsLib</gi> which may contain <gi>fLib</gi> and <gi>fvLib</gi>. Solution adapted from tei_jos.xml (Tomaž Erjavec's "JOS 100k A" corpus).</item>
      <item>AP: In connection with the above, introduced the iso-fs module.</item>
      <item>AP: Added module tagdocs, so that <gi>gi</gi>, <gi>att</gi>, etc., may be used in headers.</item>
     </list>
    </item>
    <item>
     <label>Version 0.4.1, 23 August 2009</label>
     <list type="bulleted">
      <item>AP: Removed (commented out) the modification of <gi>category</gi>; <gi>desc</gi> will be used instead of <gi>catDesc</gi> for the bilingual description of categories.</item>
      <item>AP: Added <att>xml:lang</att> to <gi>nkjp:topic</gi>.</item>
     </list>
    </item>
    <item>
     <label>Version 0.4.2, 15 September 2009</label>
     <list type="bulleted">
      <item>AP: Restricted the contents of <gi>marco.paraContent</gi> (i.e., of <gi>p</gi>, <gi>ab</gi>, <gi>head</gi> and <gi>titlePart</gi>) and <gi>u</gi>.</item>
     </list>
    </item>
    <item>
     <label>Version 0.4.3, 25 September 2009</label>
     <list type="bulleted">
      <item>AP: Modified the reportoire of possible values of <att>nkjp:subcorpus</att>.</item>
     </list>
    </item>
    <item>
     <label>Version 0.4.4, 8 October 2009</label>
     <list type="bulleted">
      <item>AP: Added the linking module, for <gi>ab</gi>.</item>
     </list>
    </item>
    <item>
     <label>Version 0.4.5, 3 May 2011</label>
     <list type="bulleted">
      <item>AP: Changed the order of some specifications, to make comparison to NKJP_text.xml easier.</item>
     </list>
    </item>
   </list>

   <schemaSpec ident="NKJP_structure" start="teiCorpus" prefix="tei_">
    <!-- required modules -->
    <moduleRef key="header"/>
    <moduleRef key="core"/>
    <moduleRef key="corpus"/>
    <moduleRef key="spoken"/>
    <moduleRef key="namesdates"/>
    <moduleRef key="tei"/>
    <moduleRef key="textstructure"/>
    <moduleRef key="tagdocs"/>
    <!-- required to avoid Sanity Checker complaint -->
    <elementSpec ident="handNote" mode="delete" module="header"/>
    <elementSpec ident="typeNote" mode="delete" module="header"/>
    <!-- end of Sanity-Checker-related mods -->
    <!-- optional modules -->
    <moduleRef key="iso-fs"/>
    <moduleRef key="linking"/>
    <elementSpec module="linking" ident="alt" mode="delete"/>
    <elementSpec module="linking" ident="altGrp" mode="delete"/>
    <elementSpec module="linking" ident="anchor" mode="delete"/>
    <elementSpec module="linking" ident="join" mode="delete"/>
    <elementSpec module="linking" ident="joinGrp" mode="delete"/>
    <elementSpec module="linking" ident="link" mode="delete"/>
    <elementSpec module="linking" ident="linkGrp" mode="delete"/>
    <elementSpec module="linking" ident="timeline" mode="delete"/>
    <elementSpec module="linking" ident="when" mode="delete"/>

    <!-- Restriction of <p>, <ab>, <head> and <titlePart>: -->
    <elementSpec ident="macro.paraContent" module="tei" mode="change"> 
     <desc>Clean restriction of TEI's para content.</desc>
     <content>
      <rng:zeroOrMore>
       <rng:choice>
        <rng:text/>
        <rng:ref name="gap"/>
        <rng:ref name="hi"/>
        <rng:ref name="lb"/>
        <rng:ref name="list"/> <!-- only in header -->
        <rng:ref name="ref"/>  <!-- only in header -->
        <rng:ref name="model.phrase.xml"/> <!-- only in header -->
       </rng:choice>
      </rng:zeroOrMore>
     </content>
    </elementSpec>

    <elementSpec ident="u" module="spoken" mode="change">
     <desc>Clean restriction of TEI's u(tterance).</desc>
     <content>
      <rng:zeroOrMore>
       <rng:choice>
        <rng:text/>
        <rng:ref name="gap"/>
        <rng:ref name="vocal"/>
        <rng:ref name="incident"/>
       </rng:choice>
      </rng:zeroOrMore>
     </content>
    </elementSpec>

    <elementSpec ident="publicationStmt" module="header" mode="change">
     <attList>
      <attDef ident="subcorpus" mode="add" ns="http://www.nkjp.pl/ns/1.0" usage="opt">
       <desc>Possible values are: "balanced" (for text in the 300-million-word balanced subcorpus), "unbalanced" (for other texts which may be distributed by NKJP), "restricted" (for texts available only for the internal NKJP purposes, not to be distributed), "one_million" (for texts in the 1-million-word manually annotated sample).</desc> <defaultVal>restricted</defaultVal>
       <valList type="closed">
        <valItem ident="balanced"/>
        <valItem ident="unbalanced"/>
        <valItem ident="restricted"/>
        <valItem ident="one_million"/>
       </valList>
      </attDef>
     </attList>
    </elementSpec>

    <elementSpec ident="extent" module="header" mode="change">
     <attList>
      <attDef ident="file" mode="add" ns="http://www.nkjp.pl/ns/1.0" usage="req">
       <desc>Which file (level) does the extent refer to? (Possible
        values are text.xml, ann_segmentation.xml, etc.)</desc>
       <defaultVal>text.xml</defaultVal>
      </attDef>
     </attList>
    </elementSpec>

    <elementSpec ident="fsLib" ns="http://www.nkjp.pl/ns/1.0" mode="add">
     <desc>Contains feature and feature-value libraries.</desc>
     <classes>
      <memberOf key="model.encodingDescPart"/>
     </classes>
     <content>
      <rng:oneOrMore>
       <rng:choice>
        <rng:ref name="fLib"/>
        <rng:ref name="fvLib"/>
       </rng:choice>
      </rng:oneOrMore>
     </content>
    </elementSpec>

    <elementSpec ident="topic" ns="http://www.nkjp.pl/ns/1.0" mode="add">
     <desc>The topic of spoken conversation. It might seem that
      textDesc/domain could be used for this pupose, but, alas!,
      inclusion of textDesc makes it necessary to use all of its 8
      subelements (channel, constitution, derivation, etc.), while we
      only need something like domain...</desc>
     <classes>
      <memberOf key="model.profileDescPart"/>
     </classes>
     <content>
      <rng:text/>
     </content>
     <attList>
      <attDef ident="lang" mode="add" ns="http://www.w3.org/XML/1998/namespace" usage="opt">
       <desc>The usual xml:lang attribute.</desc>
       <datatype minOccurs="1" maxOccurs="1">
        <rng:ref name="data.name"/>
       </datatype>
      </attDef>
     </attList>
    </elementSpec>

   </schemaSpec>
  </body>
 </text>
</TEI>

<!-- Local Variables: -->
<!-- eval: (auto-fill-mode 0) -->
<!-- End: -->

