TEI by ExampleModule 4: PoetryEdward VanhoutteRon Van den BrandenMelissa TerrasAssociation for Literary and Linguistic Computing (ALLC)Centre for Data, Culture and Society, University of Edinburgh, UKCentre for Digital Humanities (CDH), University College London, UKCentre for Computing in the Humanities (CCH), King’s College London, UKCentre for Scholarly Editing and Document Studies (CTB) , Royal Academy of Dutch Language and Literature, BelgiumCentre for Scholarly Editing and Document Studies (CTB)Royal Academy of Dutch Language and LiteratureKoningstraat 189000 GentBelgiumctb@kantl.beEdward VanhoutteMelissa TerrasCentre for Scholarly Editing and Document Studies (CTB) , Royal Academy of Dutch Language and Literature, BelgiumCentre for Scholarly Editing and Document Studies (CTB) , Royal Academy of Dutch Language and Literature, BelgiumGentCentre for Scholarly Editing and Document Studies (CTB)Royal Academy of Dutch Language and LiteratureKoningstraat 189000 GentBelgium
Licensed under a Creative Commons Attribution ShareAlike 3.0 License
9 July 2010TEI by Example.Edward VanhoutteeditorRon Van den BrandeneditorMelissa Terraseditor
TEI by Example offers a series of freely available online tutorials walking individuals through the different stages in marking up a document in TEI (Text Encoding Initiative). Besides a general introduction to text encoding, step-by-step tutorial modules provide example-based introductions to eight different aspects of electronic text markup for the humanities. Each tutorial module is accompanied with a dedicated examples section, illustrating actual TEI encoding practise with real-life examples. The theory of the tutorial modules can be tested in interactive tests and exercises.
en-GBtechnical revisionreleaserevision and added 2.3. grouping structures and 6.2. dedicationsadded 6.2 Acrostics-added new prose with internal rhyme under 3.1inserted enjambements under 4.4 and rewrote that sectionedited summary of 4added summary to 5removed suggestions divcorrection of textrevisionrevisionrevision
Module 4: Poetry
According to the Oxford English Dictionary, poetry is:
Composition in verse or some comparable patterned arrangement of language in which the expression of feelings and ideas is given intensity by the use of distinctive style and rhythm; the art of such a composition.Oxford English Dictionary, poetry, 2a or
The product of this art as a form of literature; the writings of a poet or poets; poems collectively or generally.Oxford English Dictionary, poetry, 2b
A poem then can have different manifestations:
A piece of writing or an oral composition, often characterised by a metrical structure, in which the expression of feelings, ideas, etc., is typically given intensity or flavour by distinctive diction, rhythm, imageryOxford English Dictionary, poem, 1A composition in prose having elements in common with a poem.Oxford English Dictionary, poem, 2aAn artwork or piece of music having elements in common with a poem.Oxford English Dictionary, poem, 2b
The length of a poem can vary from a couple of words to a multi-volume book.
If length is not a decisive feature of the poetry genre, verse or some comparable patterned arrangement of language, metrical structure, and metaphorical language certainly are.
The use of metaphorical language is for some critics an argument in favour of the treatment of prose poetry as a form of poetry, while for other critics the absence of a patterned arrangement of language and metrical structure is an argument in favour of the treatment of prose poetry as a form of prose. Likewise, Elizabethan and Jacobean drama, which was often written in verse by authors such as William Shakespeare, Christopher Marlowe, Thomas Middleton, and Ben Jonson, can be considered drama or poetry just as the chorus in a Greek play that was originally composed to be sung.
The TEI Guidelines don’t interfere with this poetry/prose debate by treating texts by their document types rather than by their genres. That’s why the TEI Guidelines present a chapter on verse, not on poetry. The document type is—contrary to what it may seem—not an innate property of the document, but a formalised analysis of a document by a subjective agent such as a scholar, editor, or encoder who identifies a text as prose, verse, or drama through their own subjective reasoning. For the detailed documentation of the possible encodings of the thus identified text, the encoder or scholar may then turn to the appropriate sections of the TEI Guidelines.
In this module on poetry, we take a step back and consider poetry by example. We will analyse different instances of poetry structurally and encode them for their defining features such as:
patterned arrangement of language
Patterned Arrangement of Language
A shopping list is commonly not considered a form of literature, not even when it features in a literary work, or when it shows some incidental metrical structure or rhyme, unless someone identifies the text as such. The following text can thus be considered as non-literary prose:
What we see here is a functional block of fourteen lines of prose, typographically separated from each other by line breaks. The fundamental organisational unit for prose is the paragraph which is encoded in TEI as p. The start of a new typographical line is encoded with the milestone tag lb, which appears as lb because it is a self-closing empty element. Applied to the shopping list, this produces the following encoding:
But our shopping list is a specific type of prose: it is a list, for which we could use list containing twelve items for which we use item. This could result in the following encoding:
On the most basic structural level, this shopping list is thus a named grouping of lines of text. When we use the element lg for line group, and the element l for line, we arrive at the following encoding:
Up to now we have looked at three different possible encodings for the same document which we identified as a shopping list. The first encoding considers the document as a block of prose in which different lines of text are separated by line breaks. The second one structures the shopping list with the appropriate labels (list and item). The third one makes abstraction of the meaning of these typical labels and considers the shopping list as a group of lines of text. The latter is less specific than the second, but more structurally descriptive than the first.
But is this shopping list just a block of prose, organised as a group of lines? The metrical composition, form, and structure of this shopping list, together with the use of rhyme may suggest that this is rather a piece of poetry which can be encoded as such. The rhyme present in the poem gives away a possible structure which consists not of one but of four line groups or stanzas. We use lg to encode them:
There is nothing in this encoding, however, which documents whether these four line groups belong together or not. Therefore we can wrap another lg element around them inside which they nest comfortably.Like other text-division elements, lg elements can nest hierarchically.
In order to distinguish among the nesting line groups and the parental one, we can add some semantic information in a type attribute which specifies a name conventionally used for this level of division and label the line groups respectively as stanza and poem as in the following example:
Notice that, while the type attribute can have any value defined by the encoder (as long as it does not contain white space), it is intended solely for conventional names of different classes of text blocks. When lg is used to encode paragraphs in prose poetry, the type attribute value could be para or anything else. If the lg represents an arbitrary organisation of lines, the type attribute value could be free or anything else. If, for instance, this poem would have been organised differently, say in two quatrains and one sestet, we could have the following encoding:
Next, we can number the stanzas and lines in our poem inside an n attribute and document that this poem has four stanzas and fourteen lines of verse:For large corpora of verse texts these numberings are commonly added automatically by some sort of programmed routine.
Poems often carry a title which can be encoded using head:
Preceding quotations introducing the poem as a motto can be encoded using epigraph:
Poems are often signed, which can be encoded using signed outside the lg type="poem" element:
Different document types such as prose, verse, or drama can be considered poetry. Poetry of the document type verse consists typically of minimally one group of one or more lines, which may be encoded using lg and l, respectively. Line groups can nest inside each other. To all instances of line groups and lines, semantic and analytical information can be added in attributes. The title of a poem can be encoded using head, motto’s can be encoded using epigraph, the signature of the poet can be encoded using signed.
Single poems may appear isolated as independent texts, as part of some other document types such as prose and drama, or in combination with other poems as part of composite texts. Typical examples of such composite texts are anthologies, cycles of poems, and composite poems, i.e., poems consisting of other poems. The line between cycles of poems and composite poems, however, is thin and assigning either interpretation to the texts is the encoder’s decision, who can usually depend on how the author or publisher represented the texts in the original publication.
Many encoding strategies can be used to encode either of the composite text types mentioned. In the following paragraphs we suggest only a couple of them.
Since lg elements can nest, it is possible to encode nesting poems using lg with a value poem for the type attribute. If we consider the stanza’s of the example poem as poems in their own right, which were numbered by the author, this can result in the following encoding:
Cycles of Poems
Cycles of poems are structurally akin to composite poems but the top level element is not a lg type="poem" but a div with a suggested value cycle for the type attribute. If we reconsider the example poem, this generates the next encoding:
An anthology can as well be represented using a div type="anthology" element but it is good practice to use the more powerful group element. The group element groups together a sequence of distinct texts (or groups of such texts) which are regarded as a unit for some purpose. The group element consists of text elements which may have optional front and back elements and mandatory body elements. If we reconsider the example poem that way, the following encoding may apply:Each text element can have its own front and back elements so that it becomes possible, for instance, to encode complete works of poets, maintaining the original front and back materials of the separately published poetry volumes. See .
Composite poems, cycles of poems, and anthologies are composite texts which can be encoded using different encoding strategies. Composite poems may be encoded using nesting lg elements. Cycles of poems may be encoded using sibling lg type="poem" elements. Anthologies may be encoded using the group element which may have multiple text elements.
So far, all of the elements and attributes for structuring verse texts were members of the common elements and attributes defined in the core TEI module. Yet, TEI provides a specific verse module as well, which defines a number of elements and attributes specific for the encoding of verse texts. Some of these will be discussed in the following sections. In order to use them, a TEI schema must include all (or just the required) components of that verse module; see for a tutorial on how to customise TEI.
The rhyming words of a line of verse can be encoded using the appropriate rhyme element:
rhyme can appear anywhere in the line. This way, not only end-of-line rhymes can be tagged but also internal rhyme, even inside prose(-like) paragraphs like in the following fragment:
Rhyme patterns can be documented with a rhyme attribute which has a default notation in which distinct letters stand for rhyming lines. This attribute can be added to lg and/or to l, and also to any div element that is used for the encoding of poetry. Of course, the
The rhyme scheme in the shopping list poem is ababcdcdefgefg. This can be documented inside the rhyme attribute of lg type="poem". The rhyme scheme of the separate stanzas can be encoded inside the rhyme attribute of lg type="stanza", and even the rhyme scheme of the separate lines can technically be encoded inside the rhyme attribute of the l element. The complexity of the use of all these options depends on the encoder. A maximally complex encoding could be the following:
Rhyming Words and Patterns
The correspondence between the rhyming pattern documented in the rhyme attribute and the rhyming words encoded with the rhyme element can be specified in a label attribute on the rhyme element. The value of this attribute is usually one of the letters of the rhyme pattern. Applied to the shopping list poem, this results in the following encoding:
All rhyme elements with the same value for their label attribute are assumed to rhyme with each other within a given scope. That scope is defined by the nearest ancestor element for which the rhyme attribute has been supplied.
In the following encoding of the same poem, the scope is defined by the nearest ancestor element with a rhyme attribute, i.e., the lg type="stanza" element. This means that the rhyming words labelled a, b, or c are only assumed to rhyme inside that stanza and not across stanzas:
The occurrence of rhyming words and rhyming patterns and their correspondence can be encoded by a combination of tags and attribute values. Depending on the encoder’s preferences, they can be applied to different structural levels of the text.
There is a difference between the conventional metrical structure of a poem and the actual realisation of that conventional metrical structure. Both can be documented with the use of attributes.
Conventional Metrical Structure
The conventional metrical structure in which a poet is working can be documented with the met attribute, whose value specifies the metrical form of a single verse line. This attribute can be added to any text-division element in use in the encoding of poetry: div, lg, and l. The metre documented inside the met attribute is inherited by any metrical unit contained within the element for which the met attribute has been supplied. This means that the met value of a div or an lg, for instance, is inherited by nesting divs or lgs. The metrical structure of that lg is understood to contain as many repetitions of the pattern as there are lines in the line group. The same attribute value, when inherited in turn by the l element, must be understood not to repeat. Consider the third stanza of our shopping list poem, which exists of three lines of alternating long and short syllables:
Private Metrical Notation Scheme
The encoder is free to design their own metrical notation scheme. In the example above use has been made of the classical scansion system which marks quantitative metre originally by a macron (here a dash -) for long syllables and a breve (here a u) for short syllables. A bar | is used to mark the foot boundary and a slash / marks the line boundary. Other systems like the ictus (/) and x (x) system could be used to denote metrically stressed and unstressed syllables. The use of this latter system results in the following met attribute value for the stanza above: /+/+/+/.
The metrical notation scheme used may be documented in the metDecl element within the encodingDecl element inside the TEI header. For the above example this could be documented as follows:
This may also be expressed less formally, for instance:
See section 6.5 Metrical Notation Declaration of the TEI Guidelines for more examples and complex cases.
Realisation of Metrical Structure
When we consider the third and the fourth stanzas of the shopping list poem, we see that some lines of the fourth stanza divert from the metrical scheme documented in the met attribute. This deviation, or otherwise put, the realisation, may be documented inside a real attribute:
Caesura and Enjambements
Whereas a caesura expresses a metrical pause inside one line of verse, an enjambement marks the breaking of a syntactic unit between two lines of verse.
The third line of the last stanza of the shopping list poem consists of two equal metrical parts (-u-) with a rest in between. This rest is called a caesura, and is here represented with an apostrophe. We can encode this information also in the verse line, with the caesura element which marks the point at which a metrical line may be divided:
The presence, absence, or degrees of discrepancy between lines of verse and syntactic units running over them can be documented as values of an optional enjamb attribute on the l element. When used, this attribute can, for instance, have the value yes or no to signal its occurrence, or weak or strong to express some sort of evaluation. In the following stanza of Edgar Allen Poe’s
The Raven the presence or absence of enjambement is encoded:
The expressions of conventional metrical structures in met attributes are inherited by the children of the attributed elements, except where deviations are expressed in a real attribute. Each encoder is free to design their own encoding scheme and document it inside metDecl. It is also possible to encode the occurrence and location of a caesura (with caesura) or an enjambement (with enjamb).
Just like any other aspect of the transcription and encoding process, analysing metaphorical language involves interpretation. Unlike the expression of this interpretation in structural markup, the analysis of metaphorical language addresses logical structures that probably will cross structural boundaries. Due to the primary focus of the TEI encoding scheme on representing structural characteristics of texts, and the syntactic requirement that all XML structures should nest properly, this kind of logical analysis will need a kind of workaround. One such workaround defines different analytic categories separately and links them to the relevant passages in the poems. A first requirement is that the smallest addressable structures be identified with an xml:id attribute:xml:id provides a unique identifier for the element bearing the attribute. Its value must start with a letter, or _ and may be followed by one or more Named Characters (letter, digit, ., -, _, Unicode Combining Character, or Extender). See the XML Specification for more guidance on the use of xml:id.
These xml:id values can later be used to identify spans of interpretive categories. Such interpretive spans are encoded as span, identifying the structural scope of this interpretation with the from attribute marking its beginning and the to attribute marking its end. Their values are values for an xml:id attribute elsewhere in the document, prefixed with a hash character (#), in order to indicate it as the identifier part of a formal URI reference. Preferably, the resp attribute is used to identify who is responsible for the interpretation.The value of the resp attribute must be a pointer to an element in the document header that is associated with a person asserted as responsible for some aspect of the text’s creation, transcription, editing, or encoding. See chapter 14 Certainty and Responsibility of the TEI Guidelines. Related span elements can be grouped in a spanGrp element. A type attribute can characterise the kind of analysis. In our poem, one way of identifying all images concerned with food and non-food could be:
Notice that the from attribute is mandatory on span. The to attribute is optional; when it is missing, the entire structure identified by the from attribute will be taken as the context for the interpretation.
As will be clear from this example, this system of linking analyses to textual structures is not very economic when discontinuous structures share the same analysis. Another approach for logical analysis works from the opposite angle, by hooking text structures to specific interpretations. In order to do so, interpretive categories should be formally defined somewhere else, either in the same document or externally. This is done inside the interp element, bearing a unique xml:id attribute. Related interpretive categories can be grouped inside an interpGrp element. Following example could identify the same semantic categories from the previous example:
Inside the transcription of the poem, reference can be made to these interpretations with an ana attribute. Its value should always point to an identifier, either locally or externally. Suppose these interpretive categories are stored in a separate document named analysis.xml. Then the poem could be analysed as follows: Of course, analyses can be much more complex. The TEI provides a generic mechanism for expressing complex hierarchies of interpretive relationships, called Feature Structures. See chapter 12 Feature Structures of the TEI Guidelines for a detailed treatment.
For the study of metaphorical language in poetry, logical structures should be identified and grouped into interpretive categories which can be related to other such categories. These interpretive categories with their logical relationships can be stored inside or outside the XML document containing the analysed text. In the poem, reference can be made to these internally or externally documented analyses.
Components of the Verse Line
It is often convenient for various kinds of analysis to encode further subdivisions of verse lines. This can be done using the seg element which contains any arbitrary phrase-level unit of text (including other seg elements).
The third and the fourth stanzas of our poem, for instance, contain lines which include two items each, except for line 13. The appropriate encoding could be the following:
If the poem is encoded as an lg, the TEI doesn’t have an out of the box solution to deal with dedications which appear under the title of the poem. In the case a dedication needs to be encoded, there are two viable options. The first one is to consider the dedication as a head and use its type attribute for specifying its function as a dedication:
The second option is to encode the poem as a div type="poem" instead of an lg type="poem", and consider the title as an anonymous block ab with a value of dedication for its type attribute.
One example of the use of the seg element for further advanced analysis is the following proposal to signal the presence of an acrostic in a poem. In this poem by Edgar Allan Poe, entitled
An Acrostic, the first letters of each line of verse together form the first word of the first line: Elizabeth.
You have reached the end of this tutorial module covering poetry markup with TEI. You can now either proceed with other TEI by Example moduleshave a look at the examples section for the poetry module.take an interactive test. This comes in the form of a set of multiple choice questions, each providing a number of possible answers. Throughout the quiz, your score is recorded and feedback is offered about right and wrong choices. Can you score 100%? Test it here!