<?xml version="1.0" encoding="UTF-8"?>
<?xml-model href="../../../_utils/schema/yaps.rnc" type="application/relax-ng-compact-syntax"?>
<?xml-model href="../../../_utils/schema/yaps.isosch" type="application/xml" schematypens="http://purl.oclc.org/dsdl/schematron"?>
<?xml-stylesheet type="text/css" href="../../../_utils/stylesheets/yaps-tei.css"?>
<!-- $Id: basic_encoding.xml 51709 2026-05-28 23:29:13Z syd $ -->
<TEI xmlns="http://www.wwp.northeastern.edu/ns/yaps"
     xmlns:y="http://www.wwp.northeastern.edu/ns/yaps"
     xmlns:eg="http://www.tei-c.org/ns/Examples"
     version="5.0">
  <teiHeader>
    <fileDesc>
      <titleStmt>
        <title>Basic Tagging</title>
        <author>Julia Flanders</author>
      </titleStmt>
      <editionStmt>
        <edition>Introduction to TEI Encoding and Schema Design, Northeastern University, 2018-04</edition>
      </editionStmt>
      <publicationStmt>
        <distributor>Women Writers Project (via website)</distributor>
        <address>
          <addrLine>url:mailto:wwp@northeastern.edu</addrLine>
        </address>
        <date when="2018-04-04"/>
        <availability status="restricted">
          <p>Copyright 2007 Syd Bauman, Julia Flanders, and the Women Writers Project</p>
          <p>This TEI-encoded XML file is available under the terms of the <ref
              target="http://creativecommons.org/licenses/by-sa/3.0/">Creative Commons
              Attribution-ShareAlike 3.0 (Unported)</ref> license.</p>
        </availability>
        <pubPlace>Boston, MA  USA</pubPlace>
      </publicationStmt>
      <sourceDesc>
        <p>Covers basic "core" TEI vocabulary and genres using examples.</p>
      </sourceDesc>
    </fileDesc>
    <revisionDesc>
      <change who="personography.xml#sstanley.fxj" when="2015-10-12">Added some tutorials.</change>
      <change when="2012-01-16" who="jflanders.lfw">Added some lecture notes, targetted at
        Kristen</change>
      <change when="2011-04-20" who="jflanders.lfw">Added coverage of <gi>choice</gi>, <gi>add</gi>,
          <gi>del</gi>, other ms and transcription features, from advanced_encoding.xml.</change>
      <change when="2010-12-06" who="jflanders.lfw">Updated to match revised content if
        necessary</change>
      <change when="2008-06-18" who="#sbauman.emt">added plain-text version of first example;
        removed numeric character references in examples as JF had for UW.</change>
      <change>added encoding showing list example</change>
      <change>automatically converted from presentation.odd conforming to yaps.odd conforming using
        p2y.xslt and p2y.perl</change>
      <change>Replaced first slide with an example</change>
    </revisionDesc>
  </teiHeader>
  <text>
    <presentation>
      <abstract>
        <p>This tutorial covers the basic elements used to encode a TEI document, focusing on the
          fundamental structural elements for marking up your text (in particular, for basic prose,
          poetry, and drama). Building from these foundational elements, the tutorial covers
          phrase-level elements, like names, references, and linguistic features. These slides also
          cover: How to correct, regularize, or modernize the text while still acknowledging the
          original; how to encode authorial or editorial deletions and revisions of the text; and
          how to show uncertainty about your reading of the text.</p>
      </abstract>
      <section>
        <head>A Sample Text Fragment</head>
        <slide>
          <p>
            <eg><![CDATA[    ]]><hi rend="class(interest)">Chapter 1: The Manor House</hi><![CDATA[
              
  Charles hadn’t visited the manor house since Easter,
1955, and now he remembered why.
              
  “Hullo”, he called out as he walked up the drive, and
then, as if to himself, “To be or not to be?, to walk or not to
walk...oh, ]]><hi rend="class(interest)">hang</hi><![CDATA[ it all!” His meditation on Hamlet was interrupted
as he collided with a peacock. “Sacré bleu!” he exclaimed with
irritation, his sang-froid completely deserting him. It was going
to be a long week. His catalog of irritations included:
  1. The weather
  2. The peacocks
  3. His meagre grasp of French]]></eg>
          </p>
        </slide>
        <lectureNote>
          <p>This is a very primitive, simple example that we've cooked up to demonstrate some basic
            markup; it has some basic features that are common to prose documents: <list>
              <item>a heading</item>
              <item>a few paragraphs</item>
              <item>a list</item>
              <item>some embedded features like names, quotations, foreign words</item>
            </list> It's worth noting before we even look at the markup that in fact there's already
            structure being expressed here, using typography and layout, but the structure is
            intended to be legible by humans. Part of what we're doing in our XML markup is to
            translate this typographical markup into a form that the computer can understand.</p>
        </lectureNote>
        <tutorial>
          <p>This is a very simple example that we've cooked up to demonstrate some basic markup; it
            has some basic features that are common to prose documents, such as: <list>
              <item>a heading</item>
              <item>a few paragraphs</item>
              <item>a list</item>
              <item>some embedded features like names, quotations, foreign words</item>
            </list> It's worth noting before we even look at the markup that there's already
            structure being expressed here. We notice from signals conveyed by typography and layout
            what structure is being conveyed. Part of what we're doing in our XML markup is
            translating these typographical cues into a form that a computer can understand.</p>
        </tutorial>
      </section>

      <section>
        <head>Basic Prose Tagging</head>
        <slide>
          <p>Simple, intuitive elements:
          <egMarkup scheme="TEI">
            <div type="chapter">
              <head>Chapter 1: The Manor House</head>
              <p><name type="person">Charles</name> hadn’t visited the manor
                house since <date when="1955-04-10">Easter, 1955</date>,
                and now he remembered why.</p>
              <p>“Hullo”, he called out as he walked up the drive, and
                then, as if to himself, “To be or not to be?, to walk or 
                not to walk...oh, <emph>hang</emph> it all!” His meditation on Hamlet was
                interrupted as he collided with a peacock. “Sacré bleu!” 
                he exclaimed with irritation, his sang-froid
                completely deserting him. It was going to be a long
                week. His catalog of irritations included:
                <list>
                  <item>1. The weather</item>
                  <item>2. The peacocks</item>
                  <item>3. His meagre grasp of French</item>
                </list>
              </p>
            </div>
          </egMarkup>
          </p>
        </slide>
        <lectureNote>
          <p>These are simple, intuitive elements, many of which have direct corollaries in HTML</p>
          <p>There are several levels of structure being represented here:</p>
          <p>Large-scale elements that represent major document divisions:</p>
          <list>
            <item><gi>div</gi>: basic structural chunking, can nest recursively inside itself</item>
          </list>
          <p>Mid-level structural elements that can go inside a major division, and that contain
            words and phrase-level elements</p>
          <list>
            <item>
              <gi>head</gi>
            </item>
            <item>
              <gi>p</gi>
            </item>
            <item><gi>list</gi>, <gi>item</gi></item>
          </list>
          <p>Small elements that represent individual words and phrases:</p>
          <list>
            <item><gi>name</gi></item>
            <item><gi>date</gi></item>
            <item><gi>emph</gi></item>
          </list>
          <p/>
        </lectureNote>
        <tutorial>
          <p>These are simple, intuitive TEI elements, many of which have direct corollaries in
            HTML. There are several levels of structure being represented here, large-scale,
            mid-level, and small.</p>
          <p>Large-scale elements, like the <gi>div</gi> in this example represent major document
            divisions. In the TEI, <gi>div</gi> provides us with basic structural chunks, and can
            nest recursively inside itself.</p>
          <p>The mid-level structural elements in this passage are <gi>head</gi>, <gi>p</gi>,
              <gi>list</gi> and <gi>item</gi>. These can go inside a major division, and they
            contain words and phrase-level elements.</p>
          <p>The small elements represent individual words and phrases. In this passage, they are
              <gi>name</gi>, <gi>date</gi> and <gi>emph</gi></p>
        </tutorial>
      </section>

      <section>
        <head>More detailed encoding</head>
        <slide>
          <p>
          <egMarkup scheme="TEI">
            <div type="chapter">
              <head>Chapter 1: The Manor House</head>
              <p><name type="person">Charles</name> hadn’t visited the manor
              house since <date when="1955-04-10">Easter, 1955</date>,
              and now he remembered why.</p>
              <p><said y:interest="start end">Hullo</said>, he called out as he walked up the drive, and
              then, as if to himself, <said y:interest="start end">To be or not to be?, to walk or 
              not to walk...oh, <emph>hang</emph> it all!</said> His meditation on Hamlet was
              interrupted as he collided with a peacock. <said y:interest="start end" xml:lang="fr">Sacré bleu!</said>
              he exclaimed with irritation, his <foreign y:interest="start end" xml:lang="fr">sang-froid</foreign>
              completely deserting him. It was going to be a long
              week. His catalog of irritations included:
              <list>
                <item><label>1.</label> The weather</item>
                <item><label>2.</label> The peacocks</item>
                <item><label>3.</label> His meagre grasp of French</item>
              </list>
              </p>
            </div>
          </egMarkup>
          </p>
        </slide>
        <tutorial>
          <p>This passage contains some more detailed encoding that the TEI provides in bold.</p>
          <p>There are a few things to note about this passage. First is that the <gi>said</gi>
            element has replaced the quotes in the previous passage. This encoder decided that the
            information <gi>said</gi> provides is enough to omit the quotations. <emph>This is not
              something you need to do.</emph> If you are interested both in the information that
            the <gi>said</gi> element provides and the typographical cues of quote marks in the
            original passage, you can encode both the <gi>said</gi> and the quotes. However, if you
            aren't interested in the different ways of marking spoken passages, you can proceed as
            the encoder of this passage did.</p>
          <p>The other thing to note is the double usage of the <att>xml:lang</att> attribute. In
            both cases, <att>xml:lang</att> is indicating that the content of the element is in
            French. Note that it is applied to the <gi>said</gi> (the spoken passage is in French),
            and a catch-all <gi>foreign</gi> element (which just says, <said>the content of this
              element is French</said>).</p>
        </tutorial>
      </section>

      <section>
        <head>More elements</head>
        <slide>
          <egMarkup scheme="TEI">
            <div type="chapter">
              <head>Chapter 1: The Manor House</head>
              <epigraph y:interest="start end"> 
                <quote y:interest="start end"><p y:interest="start end">Never a dull moment</p></quote>
                <bibl y:interest="start end">
                  <title y:interest="start end">The Falconer</title>, 
                  <author y:interest="start end">Edgar Swiddlebaum</author>
                </bibl>
              </epigraph>
              <p><name type="person">Charles</name> hadn’t visited the manor
              house since <date when="1955-04-10">Easter, 1955</date>,
              and now he remembered why.</p>
              <p><said>Hullo</said>, he called out as he walked up the drive, and
              then, as if to himself, <said><quote y:interest="start end">To be or not to be?</quote>, to walk or 
              not to walk…oh, <emph>hang</emph> it all!</said> His meditation on <title y:interest="start end">Hamlet</title> was
              interrupted as he collided with a peacock. <said xml:lang="fr">Sacré bleu!</said>
              he exclaimed with irritation, his <foreign xml:lang="fr">sang-froid</foreign>
              completely deserting him. It was going to be a long
              week. His catalog of irritations included:
              <list>
                <item n="1">The weather</item>
                <item n="2">The peacocks</item>
                <item n="3">His meagre grasp of French</item>
              </list>
              </p>
            </div>
          </egMarkup>
        </slide>
        <tutorial>
          <p>Here we have even more elements provided by the TEI, once again in bold. These are the
            most generic elements for capturing quotations and citations.</p>
          <p>We've added an <gi>epigraph</gi> which contains a <gi>quote</gi> as well as the
            bibliographic information about where the quote came from (in <gi>bibl</gi>,
              <gi>title</gi> and <gi>author</gi>).</p>
          <p>We can also record quotes and the names of works within the running text of the
            chapter. So, for example, we have the <gi>quote</gi> from Hamlet marked, as well as the
            reference to the title. Note also that we have <gi>quote</gi> nested inside
              <gi>said</gi>, since the quote was spoken. Both of these elements can be nested within
            each other.</p>
          <p>Note that all of the possible encodings we've recorded in the past three slides are
            valid. Depending on the aims of your project, you could have employed any of the above
            encodings—or even more complex ones, if your project is invested in recording other
            textual features.</p>
        </tutorial>
      </section>

      <!--  <section>
        <head>Some detailed phrase-level encoding</head>
        <slide>
        
        <p>Names and references to things:</p>
        <list><item>
        <gi>persName</gi>:<eg> <![CDATA[<persName>Baron Olivier of Brighton</persName> ]]></eg> </item>
        <item>
        <gi>placeName</gi>: <eg><![CDATA[<placeName>New York</placeName>, <placeName>New York</placeName> ]]></eg></item>
        <item><gi>orgName</gi>: <eg><![CDATA[<orgName>Podunk Sewing Club</orgName> ]]></eg></item>
        <item><gi>title</gi>:  <eg><![CDATA[<title>Hamlet</title>, <title>La Gioconda</title> ]]></eg></item>
        <item><gi>rs</gi>: <eg><![CDATA[<rs>our nation's capital</rs> ]]></eg></item>
        </list>
        <p>Analytic markup:</p>
        <list>
        <item><gi>measure</gi>: <eg><![CDATA[<measure commodity="clams" unit="kg" quantity="1.36">3 pounds littlenecks</measure>]]></eg></item>
        <item><gi>date</gi>: <eg><![CDATA[<date when="1612-01-05">The Feast of Epiphany, 1611/12</date>]]></eg></item>
        
        </list>
        <p>Linguistic features: 
        <gi>foreign</gi>,
        <gi>distinct</gi>,
        <gi>soCalled</gi>,
        <gi>mentioned</gi>,
        <gi>term</gi>, and
        <gi>emph</gi>:
        <eg><![CDATA[I <distinct>dinna ken</distinct> why that
        <foreign xml:lang="fr">soi-disant</foreign> <soCalled>expert</soCalled>
        must be <emph>so</emph> particular about pronouncing
        <mentioned xml:lang="cy">Llandaff</mentioned> using a
        <term>voiceless lateral fricative</term>.]]></eg></p>
        </slide>
        </section> -->


      <!--<section>
        <head>Generic markup structures (1)</head>
        <slide>
          <eg><![CDATA[ <div type="recipe">
   [ transcription of unstructured source ]
   <ab type="heading">Clam Chowder</ab>
   <ab type="instructions">
     <seg type="step">Take <measure unit="kg" quantity="1.3"
     commodity="clams" >3 lbs of littlenecks</measure> and shuck
     them, saving the juice.</seg> <seg type="step">In a large
     pot, melt <measure unit="g" quantity="28" commodity="butter"
     >1 knob butter</measure>, and sauté a large chopped onion
     until soft.</seg> <seg type="step">Add 3 potatoes, cubed;
     <measure unit="L" quantity="0.95" commodity="milk" >2 pts
     milk</measure>; and salt and pepper to taste.</seg> <seg
     type="step">Simmer until the potatoes are soft.</seg> <seg
     type="step">Add clams and juice and then simmer 5 minutes
     more.</seg> <seg type="step">Serve dusted with
     paprika.</seg>
   </ab>
 </div>]]></eg>
            </slide>
        </section>-->
      <!--<section>
        <head>Generic markup structures (2)</head>
        <slide>
          <eg><![CDATA[ <div type="recipe">
   [ highly structured ]
   <div type="ingredients">
     <list>
       <item><measure unit="kg"    quantity="1.3"  commodity="clams"   >3 lbs littlenecks</measure></item>
       <item><measure unit="g"     quantity="28"   commodity="butter"  >1 knob butter</measure></item>
       <item><measure unit="count" quantity="1"    commodity="onions"  >1 large chopped onion</measure></item>
       <item><measure unit="count" quantity="3"    commodity="potatoes">3 potatoes</measure></item>
       <item><measure unit="L"     quantity="0.95" commodity="milk"    >2 pts milk</measure></item>
       <item>salt</item>
       <item>pepper</item>
       <item>paprika</item>
     </list>
   </div>
   <div type="instructions">
     <ab type="step" n="1" subtype="ingredientPreparation"><seg type="activity">chop</seg> onion</ab>
     <ab type="step" n="1" subtype="heat"><seg type="activity">melt</seg> butter</ab>
     <ab type="step" n="2" subtype="combine"><seg type="activity">add</seg> onion to butter</ab>
     <ab type="step" n="3" subtype="heat"><seg type="activity">sauté</seg> onion until soft</ab>
     <ab type="step" n="1" subtype="ingredientPreparation"><seg type="activity">cube</seg> potatoes</ab>
     <ab type="step" n="4" subtype="combine"><seg type="activity">add</seg> potatoes to butter &amp; onions</ab>
     <ab type="step" n="1" subtype="ingredientPreparation"><seg type="activity">shuck</seg> clams, <seg type="activity">save</seg> juice</ab>
     <ab type="step" n="4" subtype="combine"><seg type="activity">pour</seg> milk into mix while stirring</ab>
     <ab type="step" n="4" subtype="combine"><seg type="activity">add</seg> salt to taste</ab>
     <ab type="step" n="4" subtype="combine"><seg type="activity">add</seg> pepper to taste</ab>
     <ab type="step" n="5" subtype="heat"><seg type="activity">simmer</seg> until potatoes are soft</ab>
     <ab type="step" n="6" subtype="combine"><seg type="activity">add</seg> clams &amp; juice</ab>
     <ab type="step" n="7" subtype="heat"><seg type="activity">simmer</seg> 5 more minutes</ab>
     <ab type="step" n="8" subtype="garnish"><seg type="activity">sprinkle</seg> with paprika</ab>
   </div>
 </div>]]></eg>
            </slide>
        </section>-->

      <section>
        <head>The bigger picture</head>
        <slide>
          <egMarkup scheme="TEI">
            <TEI xmlns="http://www.tei-c.org/ns/1.0" xml:lang="en">
              <teiHeader>
                <!-- stuff omitted here -->
              </teiHeader>
              <text>
                <body>
                  <div type="essay">
                    <head>An Essay on Summer</head>
                    <p>Summer school in <date when="1990">MCMXC</date> was never easy; 
                    it went by too quickly and left us wanting more.</p>
                    <p>But, as my friend <name type="person">Peter</name> said with his 
                    inimitable <foreign xml:lang="fr">je ne sais quoi</foreign>, 
                    <said>It never pays to think too hard</said>. Or, as I would rather 
                    put it, <quote xml:lang="es">Que sera, sera</quote>.</p>
                  </div>
                  <div type="essay">
                    <head>An Essay on Winter</head>
                    <p>School in winter was nearly insupportable...</p>
                  </div>
                </body>
              </text>
            </TEI>
          </egMarkup>
        </slide>
        <tutorial>
          <p>Let's take a step back now to see how a piece of text fits into a TEI document. This is
            a very basic example of a complete TEI document. We can see that the <gi>TEI</gi>
            element is the root element, and that we also have a required element,
              <gi>teiHeader</gi> (the content of <gi>teiHeader</gi> is omitted here, but it contains
            metadata about the text and encoding, among other things*). We also have the
              <gi>text</gi> element which contains our transcription and markup of the text. This is
            basic the structure of how complete TEI documents are represented.</p>
          <p>* For more information on the <gi>teiHeader</gi>, see the <ref
              target="../../../../resources/context.html">Contextual Encoding Primer</ref></p>
        </tutorial>
      </section>

      <section>
        <head>Basic document structures</head>
        <slide>
          <egMarkup scheme="TEI">
            <text>
              <front>
                <div type="preface"><!-- ... --></div>
                <div type="introduction"><!-- ... --></div>
              </front>
              <body><!-- Body of text here --></body>
              <back>
                <div type="appendix"><!-- ... --></div>
                <div type="index"><!-- ... --></div>
              </back>
            </text> 
          </egMarkup>
        </slide>
        <tutorial>
          <p>Here, we will take a minute to zoom in on the <gi>text</gi> element. As in the previous
            example, we have the required <gi>body</gi> element. But we've also added the optional
            elements <gi>front</gi> and <gi>back</gi>. These elements are where you encode the
            front- and back-matter (so introductions, notes to the reader, epilogues, indices,
            etc.)</p>
          <p>Next we'll look at document structures for some common types of texts in the
            humanities.</p>
        </tutorial>
      </section>



      <section>
        <head>Poetry</head>
        <slide>
          <egMarkup scheme="TEI">
            <lg type="sonnet">
              <head>On First Looking into Chapman's Homer</head>
              <lg type="quatrain">
                <l>Much have I travell’d in the realms of gold,</l>
                <l>And many goodly states and kingdoms seen;</l>
                <l>Round many western islands have I been</l>
                <l>Which bards in fealty to <persName>Apollo</persName> hold.</l>
              </lg>
              <lg type="quatrain">
                <l>Oft of one wide expanse had I been told</l>
                <l>That deep-brow’d <persName>Homer</persName> ruled as his demesne;</l>
                <l>Yet did I never breathe its pure serene</l>
                <l>Till I heard <persName>Chapman</persName> speak out loud and bold:</l>
              </lg>
              <lg type="sestet">
                <l>Then felt I like some watcher of the skies</l>
                <l>When a new planet swims into his ken;</l>
                <l>Or like stout <persName>Cortez</persName> when with eagle eyes</l>
                <l>He star’d at the <placeName>Pacific</placeName>—and all his men</l>
                <l>Look'd at each other with a wild surmise—</l>
                <l>Silent, upon a peak in <placeName>Darien</placeName>.</l>
              </lg>
            </lg>
          </egMarkup>
        </slide>
        <tutorial>
          <p>Poetry is encoded using the <gi>lg</gi> (or <q>line group</q>) element. Each
              <gi>lg</gi> must contain either <gi>l</gi> (the individual lines) or more, nested
              <gi>lg</gi> elements. Think of the <gi>lg</gi> element as being like a poetic
              <gi>div</gi>, and all of the <gi>l</gi> elements as poetic <gi>p</gi> elements. Like
              <gi>p</gi>, <gi>l</gi> contains text and smaller, phrase-level elements. <gi>lg</gi>
            can also contain <gi>head</gi> (just as <gi>div</gi> can). You can also use the
              <att>type</att> attribute to specify what type of line group you are encoding. In the
            example here, we have values on the <att>type</att> attribute that specify that the
            whole poem is a sonnet, and that the sonnet is divided into two quatrains and a
            sestet.</p>
          <p>One thing that this example does not show is that <gi>lg</gi> and <gi>l</gi> can be
            intermixed within outer, wrapper <gi>lg</gi> elements. So if, for example, your poem
            contained mostly couplets that you didn't want to mark as individual <gi>lg</gi>
            elements, but some tercets that you did want to mark, you could put <tag>lg
              type="tercet"</tag> in the middle of a sea of <gi>l</gi>s. This differentiates
              <gi>lg</gi> from <gi>div</gi>, since <gi>div</gi> cannot float in the middle of
            smaller-level elements, like <gi>p</gi>.</p>
        </tutorial>
      </section>

      <section>
        <head>Drama</head>
        <slide>
          <egXML valid="true" xmlns="http://www.tei-c.org/ns/Examples"><div type="scene">
  <head>Scene 1</head>
  <stage type="entrance">Enter Fay</stage> 
  <sp who="#spFay">
    <speaker>Fay</speaker>
    <p>I say, Dinah, has anyone seen my gloves?</p>
  </sp>
  <stage type="entrance">Enter Dinah</stage>
  <sp who="#spDin">
    <speaker>Dinah</speaker>
    <p>No, miss, perhaps the parakeet has got them again?</p>
  </sp>
  <stage type="exit">Exit Fay and Dinah</stage>
</div></egXML>
        </slide>
        <tutorial>
          <p>One of the benefits of the TEI is that it allows you to group elements together on the
            basis of semantics, rather than rendition. This comes in handy when you want to encode
            drama. Although there are no physical cues in the manuscript indicating that you should
            group a speaker tag and the speech together, you still will want to explicitly associate
            these two things. This is something that HTML does not allow us to do, as we saw
            previously.</p>
          <p>The TEI <gi>sp</gi> tag allows us to say, <said>all of the content of this element is a
              part of one dramatic speech.</said> The <gi>speaker</gi> tag contains the speaker
            label, and we use either <gi>p</gi> or <gi>lg</gi> to encode the content of the speech
            (depending upon whether the speech is in prose or verse).</p>
          <p>Additionally, the <att>who</att> attribute allows us to refer specifically to one
            character. As you have probably seen, speaker labels in manuscripts are sometimes
            misspelled, have variant spellings, or are just plain inaccurate. The <att>who</att>
            attribute points to one stable person in the castList, so that you have a regularized
            way of saying who is speaking, rather than relying on the sometimes-inaccurate speaker
            labels.</p>
          <p>So, for example, if <q>Dinah</q> in the example were sometimes spelled <q>Dina</q> or
            accidentally called <q>Donna,</q> you would still be able to refer to the static entry
            of <q>#spDin</q> in the cast list.</p>
        </tutorial>
      </section>

      <section>
        <head>Letters</head>
        <slide>
          <egXML valid="true" xmlns="http://www.tei-c.org/ns/Examples"><div type="letter">
  <opener>
    <dateline>
      <date when="1865-08-05">August the 5th</date>
      <name type="place">Cape Cod</name>
    </dateline>
    <salute>My dear <name type="person">Becky</name></salute>
  </opener>
  <p>How lovely the oysters are this evening!</p>
  <closer>
    <salute>Yours very truly</salute>
    <signed><name type="person">Maria</name></signed>
  </closer>
</div></egXML>
        </slide>
        <tutorial>
          <p>Letters have the <gi>opener</gi> and <gi>closer</gi> elements to encode features like
            salutations (<gi>salute</gi>), datelines (<gi>dateline</gi>), and signatures
              (<gi>signed</gi>). The TEI constrains where elements like <gi>opener</gi> and
              <gi>closer</gi> can go. <gi>opener</gi> must be the first (or almost the first) thing
            encoded in the letter, and the <gi>closer</gi> must be the last (or almost the last). If
            the letters you want to encode follow a different structure than is allowed by the TEI,
            you will need to customize the TEI* to allow for these variant structures.</p>
          <p>*See our <ref target="../../../../resources/customization.html.html">Customization
              Primer</ref>.</p>
        </tutorial>
      </section>

      <section>
        <head>Some detailed phrase-level encoding</head>
        <slide>

          <p>Names and references to things:</p>
          <list>
            <item>
              <gi>persName</gi>:
              <egXML valid="true" xmlns="http://www.tei-c.org/ns/Examples"><persName>Baron Olivier of Brighton</persName> </egXML>
            </item>
            <item>
              <gi>placeName</gi>:
              <egXML valid="true" xmlns="http://www.tei-c.org/ns/Examples"><placeName>New York</placeName>, <placeName>New York</placeName> </egXML>
            </item>
            <item>
              <gi>orgName</gi>:
              <egXML valid="true" xmlns="http://www.tei-c.org/ns/Examples"><orgName>Podunk Sewing Club</orgName> </egXML>
            </item>
            <item>
              <gi>title</gi>:
              <egXML valid="true" xmlns="http://www.tei-c.org/ns/Examples"><title>Hamlet</title>, <title>La Gioconda</title> </egXML>
            </item>
            <item>
              <gi>rs</gi>:
              <egXML valid="true" xmlns="http://www.tei-c.org/ns/Examples"><rs>our nation's capital</rs> </egXML>
            </item>
          </list>
          <p>Analytic markup:</p>
          <list>
            <item>
              <gi>measure</gi>:
              <egXML valid="true" xmlns="http://www.tei-c.org/ns/Examples"><measure commodity="seafood" unit="kg" quantity="1.36">3 pounds littlenecks</measure></egXML>
            </item>
            <item>
              <gi>date</gi>:
              <egXML valid="true" xmlns="http://www.tei-c.org/ns/Examples"><date when="1612-01-05">The Feast of Epiphany, 1611/12</date></egXML>
            </item>
          </list>
          <p>Linguistic features: <list>
              <item><gi>foreign</gi>: foreign-language words</item>
              <item><gi>distinct</gi>: dialect and distinctive usage</item>
              <item><gi>soCalled</gi>: ironic usage</item>
              <item><gi>mentioned</gi>: words referred to, not used</item>
              <item><gi>term</gi>: special terminology</item>
              <item><gi>emph</gi>: verbal emphasis</item>
            </list>
          </p>
          <p>Generic elements: <list>
              <item><gi>hi</gi>: words and phrases that are highlighted for reasons we don't care
                about</item>
              <item><gi>seg</gi>: words and phrases that we want to mark for some purpose...</item>
              <item><gi>anchor</gi>: an anchor point in the text (for instance, marking the location
                of a note)</item>
            </list>
          </p>
        </slide>
        <tutorial>
          <p>Now that we've seen some basic document structures, let's dig into some basic elements
            for phrase-level encoding. You can use phrase-level elements to encode names and
            references to things, such as <gi>persName</gi>, <gi>placeName</gi>, <gi>orgName</gi>,
              <gi>title</gi>, and <gi>rs</gi> (which stands for referencing string, and is used to
            encode references to places, persons, etc. that aren't explicitly named, e.g. <q>the
              states</q> as a reference to the US.).</p>
          <p>There are also elements, like <gi>date</gi> and <gi>measure</gi> that allow you to do
            more analytical markup. So, for example, use a regularized unit for <gi>measure</gi>
            that will allow you to compare items that use different, non-standard, or antiquated
            units.</p>
          <p><gi>date</gi> allows you to encode references to specific days (or months or years) on
            the calendar. Since the transcribed information is not always enough, the
              <att>when</att> attribute allows you to create a regularized yyyy-mm-dd version of the
            date. In this way are able to remain true to the text by transcribing content, but you
            can simultaneously regularize the dates so that you can perform analysis on it (e.g.
            creating timelines).</p>
          <p>You can also encode specific linguistic features using TEI's phrase level elements. As
            we saw earlier, you can use the <gi>foreign</gi> element, the <att>xml:lang</att>
            attribute (or both!) to state that a text is in a language that is not the text's main
            language. You can use <gi>soCalled</gi> and <gi>emph</gi> for different rhetorical
            features. </p>
          <p>Occasionally, you will encounter words or phrases that you want to mark, but have no
            specific element to use. In these cases, you can use <gi>hi</gi> (for elements that are
            highlighted for reasons we don't want to mark), <gi>seg</gi> (for words and phrases that
            we want to mark, but have no better vocabulary to use), and <gi>anchor</gi> (for anchor
            points in the text).</p>
        </tutorial>
      </section>


      <section>
        <head>Transcriptional Complexities: Choices</head>
        <slide>
          <figure>
            <graphic height="400px" url="../../../_utils/gfx/askew_sample_small.png"/>
          </figure>
          <eg><![CDATA[<p>...with them, bycause they woulde
  <lb/>not be 
    <choice>
       <abbr>boūde</abbr>
       <expan>bounde</expan>
    </choice> 
  also for an other wo]]><hi rend="css( font-style: italic; font-weight: normal; )">[see below]</hi><![CDATA[
  <lb/>mā at theyr pleasure, whom they
  <lb/>knewe not, nor yet what matter
  <lb/>was layed unto her charge. Not
  <lb/>wythstandynge at the laste, after
  <lb/>moche a do and reasonyng to and
  <lb/>fro, they toke a bonde of them of
  <lb/>recognisaunce for my fourth com
  <lb/>mynge. And thus I was at the
  <lb/>last, 
    <choice>
      <orig>delyuered</orig>
      <reg>delivered</reg>
    </choice>. 
  Written by me An
  <lb/>ne Askewe.
</p>]]></eg>
          <eg><![CDATA[<choice>
  <abbr>
    <choice>
      <sic>wo<lb/>mā</sic>
      <corr>wo-<lb/>mā</corr>
    </choice>
  </abbr>
  <expan>
    <choice>
      <sic>wo<lb/>man</sic>
      <corr>wo-<lb/>man</corr>
    </choice>
  </expan>
</choice>]]></eg>
        </slide>
        <lectureNote>
          <p>In these examples, we're still looking at parallelism, but instead of managing it
            through a linking mechanism, we're managing it in a different way: through an enclosing
            element.</p>
          <p>These examples don't actually violate the ideal document tree view, but they make it
            slightly more complex: almost as if a twig has split nd then rejoined</p>
          <p>This approach is useful for smaller and more local examples of parallel text. There are
            a number of kinds of local editorial changes that are often made in the process of
            transcription and editing: processes of regularization and correction that are often
            done silently and noted in an introduction: <list>
              <item>correction of typographical errors in the source</item>
              <item>regularization or modernization of spelling and typography</item>
              <item>expansion of abbreviations</item>
            </list>
          </p>
          <p> In print-based editing, these choices are exclusionary: whichever kind of reading you
            decide to show the reader, its complementary version has to be suppressed (it could be
            indicated in a note or an appendix but it can't typically be displayed as part of the
            regular reading surface) </p>
          <p>In an XML transcription, however, it's possible to represent both (or in principle
            multiple) readings in a data structure that shows their parallelism and treats them as
            alternatives, which can then be chosen (displayed, searched, etc.) when desired. </p>
          <p> In TEI, this mechanism is the <gi>choice</gi> element, which represents a moment of
            textual forking, where instead of a single reading the text offers a choice of readings
          </p>
        </lectureNote>
        <tutorial>
          <p>Let's move into some more complex encoding situations. Sometimes when we transcribe a
            text, we come across instances when we want to edit, correct, update or otherwise change
            the text. However, when we do this, we usually still want to maintain what the original
            says. In these cases, we use the <gi>choice</gi> element.</p>
          <p>The enclosing <gi>choice</gi> element allows us to create parallelism between the two
            elements that are enclosed. It doesn't actually violate the ideal document tree, but it
            does make it slightly more complex: almost as if a twig has split and then rejoined.</p>
          <p>The <gi>choice</gi> approach is useful for smaller and more local examples of parallel
            text. There are a number of local editorial changes that are often made in the process
            of transcription and editing. These are processes of regularization and correction that
            are often done silently and noted in an introduction, such as correction of
            typographical errors in the source, regularization or modernization of spelling and
            typography, and expansion of abbreviations.</p>
          <p>In print-based editing, these choices are exclusionary; whichever kind of reading you
            decide to show the reader, its complementary version has to be suppressed (it could be
            indicated in a note or an appendix but it can't typically be displayed as part of the
            regular reading surface).</p>
          <p>In an XML transcription, however, it's possible to represent both (or in principle
            multiple) readings in a data structure that shows their parallelism and treats them as
            alternatives, which can then be chosen (displayed, searched, etc.) when desired.</p>
          <p>In the example above, the word <q>boũde</q> is expanded to <q>bounde</q> and the
            original <q>delyuered</q> is regularized to the modern <q>delivered.</q> In both of
            these cases, the <gi>choice</gi> element is signifying that one of the nested elements
            should be taken into account when reading (i.e. the sentence doesn't read <q>not be
              boũde bounde also,</q> but rather either <q>not be boũde</q>
            <emph>or</emph>
            <q>not be bounde</q>). This type of encoding allows for many things. For example, you
            could display provide different options for display on your interface. A graduate
            student could read the original, and an undergraduate could read the more regularized
            and updated version.</p>
          <p>The example at the bottom is a bit more complex, but it shows the versatility of the
              <gi>choice</gi> element. In the example, the text has both a typo, and is in
            abbreviated form. The markup shows that you can nest <gi>choice</gi> inside of itself to
            account for the <gi>sic</gi> (error) and <gi>corr</gi> (correction), while still using
            the <gi>abbr</gi> (abbreviation) and <gi>expan</gi> (expansion) elements. The markup
            shows (in order): the incorrect abbreviated, correct abbreviated, incorrect expanded,
            correct expanded choice.</p>
        </tutorial>
      </section>

      <section>
        <head>Transcriptional complexities: revision</head>
        <slide>
          <figure rend="center">
            <graphic url="../../../_utils/gfx/ms_original.jpg"/>
          </figure>
          <egXML valid="true" xmlns="http://www.tei-c.org/ns/Examples"><lg>

  <head>After <subst><del>an</del><add>the</add></subst> 
    <del><add>unsolv'd</add></del> argument</head>

  <l><del>The</del><add><del>Coming in,</del> A group of</add> little children, and their
    <lb/>ways and chatter, flow in <del>upon me</del></l>

  <l>Like <add>welcome</add> rippling water o'er my
    <lb/>heated <add>nerves and</add> flesh.</l>
    
</lg></egXML>
        </slide>
        <lectureNote>
          <p>What's at stake here: because the transcription of manuscript materials (and often
            printed texts as well) involves significant efforts of decipherment and in many cases
            conjecture or interpretation, and also because primary sources are informationally
            complex (authorial revision, erasures, missing letters, illegible passages, etc.), a
            responsible transcription needs to capture not just the end product but also information
            about the process and the editorial decision-making: not just produce a clean-looking
            innocent butter-wouldn't-melt-in-its-mouth transcription but preserve information about
            what was difficult or unclear</p>
          <p>conventions for accomplishing this are familiar from print: carets and brackets for
            marking insertions and deletions, italics to indicate unclear text, footnotes to
            indicate hypothetical readings or to describe damaged sections</p>
          <p> In text markup, the goal is to formalize as much of this information as possible and
            represent it systematically <list>
              <item>to classify the reasons for illegibility (where possible), to formalize the
                rationales for determining whether a given letter is illegible or simply
                unclear</item>
              <item>with the goal of making it possible to control the display of the reading
                surface of the text: to show or hide the deleted words and hypothetical readings,
                perhaps even to let the reader control the threshold of conjecture at which readings
                are displayed or hidden ("only show me things you're really certain about")</item>
            </list>
          </p>
          <p>Next: show basic encoding features: unclear, supplied, gap, add, del</p>
        </lectureNote>
        <tutorial>
          <p>The TEI also provides us with mechanisms for showing how documents changed as they were
            revised. The <gi>add</gi> and <gi>del</gi> elements are methods for showing additions
            and deletions to the text over time.</p>
          <p>The <gi>subst</gi> (substitution) element is a way of showing that there are one or
            more deletions from the text accompanied by one or more additions that are meant to be
            understood together. So for example, the writer here crossed out <q>an</q> and wrote in
              <q>the</q> as a substitution; these two revisions are meant to be thought of as one
            editorial gesture, so they are grouped.</p>
          <p>If you have extensive handwritten portions of your documents, you may want to take a
            look at our <ref target="../../../../resources/ms_encoding.html">Manuscript Encoding
              Primer</ref>.</p>
        </tutorial>
      </section>
      <section>
        <head>Transcriptional complexities: difficult or impossible to read</head>
        <slide>
          <figure>
            <graphic url="../../../_utils/gfx/ms_receipt.jpg" height="200px"/>
          </figure>
          <egXML valid="true" xmlns="http://www.tei-c.org/ns/Examples"><p>Johnston etc 1764 Mr Nikl<unclear>e</unclear><supplied>s</supplied>
  <gap reason="folded" extent="unknown"/> Brown <unclear>&amp;Co</unclear> to me 

  <lb/>George <unclear>Beverly juner</unclear> to ten
  <gap reason="folded" extent="unknown"/> Barels at Four 

  <lb/>pound ⅌ Barel — — —  £40</p></egXML>
        </slide>
        <tutorial>
          <p>Because the transcription of manuscript materials (and often printed texts as well)
            involves significant efforts of decipherment and in many cases conjecture or
            interpretation, and also because primary sources are informationally complex (authorial
            revision, erasures, missing letters, illegible passages, etc.), a responsible
            transcription needs to capture not just the end product but also information about the
            process and the editorial decision-making. It must not just produce a clean, organized
            transcription, if that comes at the expense of preserving information that was difficult
            or unclear.</p>
          <p>There are already several methods for indicating editorial uncertainty or conjecturing
            in print: carets and brackets for marking insertions and deletions, italics to indicate
            unclear text, footnotes to indicate hypothetical readings or to describe damaged
            sections. In text markup, the goal is to formalize as much of this information as
            possible and represent it systematically and to classify the reasons for illegibility
            (where possible), to formalize the rationales for determining whether a given letter is
            illegible or simply unclear.</p>
          <p>In this example, we use <gi>unclear</gi>, <gi>supplied</gi>, <gi>gap</gi> (with
            attributes: <att>reason</att>, <att>extent</att>) to indicate as much about this
            manuscript as we can.</p>
          <p>We do this with the goal of making it possible to control the display of the reading
            surface of the text. For example we might show or hide the deleted words and
            hypothetical readings. If your project has the resources or time, perhaps you could even
            let the reader control the threshold of conjecture at which readings are displayed or
            hidden (e.g. "only show me things you're really certain about").</p>
        </tutorial>
      </section>
      <section>
        <head>Editorial Nuance</head>
        <slide>
          <list>
            <item>
              <label>Added or inserted text:</label>
              <egMarkup scheme="TEI" type="valid">
                This is <add y:interest="start" hand="#h0504">added</add> text!
              </egMarkup>
            </item>
            <item>
              <label>Deleted text:</label>
              <egMarkup scheme="TEI" type="valid">
                No, <del y:interest="start" hand="#h0518" rend="crossout">I say</del> it is not!
              </egMarkup>
            </item>
            <item>
              <label>Entirely unreadable text:</label>
              <egMarkup scheme="TEI" type="valid">
                <gap y:interest="start" reason="folded" extent="unknown" resp="#Julia_Flanders"/>
              </egMarkup>
            </item>
            <item>
              <label>Text transcribed from some other source:</label>
              <egMarkup scheme="TEI" type="valid">
                <supplied y:interest="start" reason="overbinding" evidence="internal" resp="#editor" source="#witC">not</supplied> readable in L margin
              </egMarkup>
            </item>
            <item>
              <label>Not entirely sure what it says:</label>
              <egMarkup scheme="TEI" type="valid">
                OMG! Disgusting! There is mil<unclear y:interest="start" reason="damage" agent="mildew" cert="high">dew</unclear> on this page!
              </egMarkup>
            </item>
          </list>
        </slide>
        <tutorial>
          <p>In addition to using the elements we've discussed to acknowledge transcriptional
            complexities, you can also use attributes to provide further nuance.</p>
          <p>So, for example, you can use the <att>hand</att> attribute to indicate who is making an
            addition or deletion to a text. You can use the <att>place</att> attribute to state where
            the addition or deletion was marked, or the <att>rend</att> attribute to say how the
            marking was made (e.g. cross-out, scribble, underlined text).</p>
          <p>You can also provide the <att>reason</att> attribute to state what caused the text to
            become illegible or unclear. The value for these could be anything from
            poorly-inked-type to coffee-stains. Additionally, you can state the extent to which the
            text is missing. So for example, if a page was ripped out of the book you're encoding,
            you could explicitly state that the extent of missing text was 1 page.</p>
          <p>The <att>resp</att>, <att>evidence</att>, <att>source</att>, and <att>cert</att>
            attributes all allow you to say something about the text in your
            transcription. The <att>resp</att> attribute allows you to state who is responsible for
            that specific reading of the text. The <att>evidence</att> attribute says something
            about the nature of the evidence that supports that reading (the TEI recommends
              <val>internal</val>, <val>external</val>, and <val>conjecture</val> as values). The
              <att>source</att> attribute allows you to say where the text was supplied from, if you
            used external evidence (e.g. a different edition of the book). Finally, <att>cert</att>
            allows you to state your certainty about whether the reading you've made was
            accurate.</p>
          <list>
            <head>This tutorial is complete, please see links below to continue:</head>
            <item><ref target="../advanced_encoding/advanced_encoding_tutorial_00.xhtml">Proceed to
                next tutorial in TEI Primer</ref></item>
            <item><ref target="../../../../resources/tei_prim.html">Return to TEI
              Primer</ref></item>
            <item><ref target="../../../../resources/tutorial_main.html">Return to main tutorial
                page</ref></item>
          </list>
        </tutorial>
      </section>


    </presentation>
  </text>
</TEI>
