Module 5: Drama

3. Basic Structure

3.1. Structural divisions of the actual text

As with any other TEI text, the actual contents of drama texts are encoded in <body>, possibly be preceded by front matter in <front> and succeeded by back matter in <back>. Inside <body>, the actual text often has specific structures: acts and scenes. Like parts and chapters in prose works, these can be encoded using the generic TEI element <div> (division). In order to identify the nature of the text divisions, they can be characterised in a @type attribute. For text divisions in drama texts, the values act and scene can be used, although you can use your own typology if so desired. For our example text, the major structural divisions can be encoded as follows:
<body>
<div type="act">
<head>ACT I</head>
<div type="scene"> <head>SCENE 1: HELLO WORLD</head>
user, computer

In a clean room without windows, a table stands in the middle, carrying a computer screen.
The screen blinks, the computer emits random beeps.

[A big screen on the left hand side of the stage displays the word HELLO, and will be used to project the contents of the computer screen. A big screen on the right hand stage of the stage displays the word WORD, until the action starts. Then, the user's face is filmed in close up and projected onto this screen.]

(user enters room, walks towards the table, takes a seat, and reads what's on the screen)
[spotlight follows user]
COMP: Hello.
(user looks around and starts typing)
USER: What is on the table?

COMP: The table does not exist.
(user frowns)
USER: There is a table in the room.

COMP: Ok.
USER: What is on the table?

COMP: Nothing.
USER: There is a black box on the table.

COMP: Ok.
USER: What is on the table?

COMP: A black box.
USER: There is a black box on the table.

(computer beeps frantically)
COMP: I know.
USER: There is a red ball in the black box.

COMP: Ok.
USER: Where is the black box?

COMP: The black box is on the table.
USER: What is in the black box?

COMP: A red ball.
USER: Where is the black ball?

COMP: I don't know what black ball you are talking about.
USER: Where is the red ball?

COMP: In the black box.
USER: There is a black ball in the box.

COMP: Ok.
USER: The red ball is on the table.

COMP: In fact the red ball is in the box.
USER: The ball in the box is small.

COMP: I cannot understand such a sentence at the present time.
USER: The black ball is small.

COMP: I see.
USER: What is in the box?

COMP: A small black ball and a red ball.

(user smiles, stands up, takes a small green ball out of his pocket, walks away throwing and catching the ball)
[Kraftwerk's "Computer Love" accompanies the exit]</div>
</div>
</body>
Of course, this markup is far from complete, and even invalid TEI, as the TEI Guidelines stipulate that <div> text divisions cannot contain unstructured text. We'll fill in the blanks in the next sections of this tutorial.

Summary

Commonly distinguished large structures in drama texts are acts and scenes. They can be encoded in TEI using the generic <div> element for text divisions. The nature of the text division can be characterised in a @type attribute.

3.2. The basic building block: speeches

One of the most distinctive organisational principles in drama texts is the grouping of text lines in utterances, spoken by the respective characters. Each line of speech can be encoded in a <sp> (speech) element. When present in the text source, the indications of the speaking character can be encoded in a <speaker> element. The actual text of a speech line should be further encoded as a paragraph (<p>) or verse line (<l>, possibly grouped in <lg>). If the encoder is undecided about the prose or verse qualities of the text lines, <seg> may also be used.

Note:

A dramatic speech line (<sp>) cannot contain unstructured text: it should be encoded further as paragraph (<p>), verse line (<l>, possibly grouped in <lg>), or genre-unspecified segment (<seg>).
For example, the last three speech lines in the example can be encoded as follows:
<sp>
<speaker>COMP</speaker>
<p>I see.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>What is in the box?</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>A small black ball and a red ball.</p>
</sp>
Note how in this example, the colons after the name labels have been left out of the transcription. This is an editorial choice that can be motivated by the fact that the colons themselves are purely typographical separators between the labels and the text, that can systematically be reproduced when this transcription is rendered. Likewise, the blank line between both groups of speeches has been omitted as a purely typographic feature. It could of course be encoded with a <lb/> element before the last speech.
The <sp> element provides an alternative mechanism for indicating the speaking character, by means of a @who attribute. Its value points to a definition of this character elsewhere in the transcription. The value of this definition's @xml:id attribute is used in the @who attribute, preceded with a hash character, in order to indicate it as the identifier part of a formal URI reference. For example:
<sp who="#comp">
<speaker>COMP</speaker>
<p>I see.</p>
</sp>
<sp who="#user">
<speaker>USER</speaker>
<p>What is in the box?</p>
</sp>
<sp who="#comp">
<speaker>COMP</speaker>
<p>A small black ball and a red ball.</p>
</sp>
Note how this example assumes that both characters are identified elsewhere in the transcription, with comp and user as respective @xml:id attribute values. A common place for such definitions in drama texts is in a 'cast list', introducing all characters of the play. For the encoding of cast lists, see 4.1. Cast List in this tutorial module. When text is spoken by more than one character, the identification codes for all of them can be listed in the @who attribute, separated by whitespace.
Of course, the encoder is free to choose which identification mechanism will be used for the speakers in the transcription. When the markers are present in the text source, their bare transcription in <speaker> (see the first example in this section) may suffice. It may make equal sense to use both systems (transcription in <speaker> and formal identification in the @who attribute), as in the second example in this section. If the text source has no explicit markers of the speaking characters, or if these markers are present but not deemed relevant to the transcription (and could be reconstructed systematically when rendering the transcription), only the formal identification in the @who may be used:
<sp who="#comp">
<p>I see.</p>
</sp>
<sp who="#user">
<p>What is in the box?</p>
</sp>
<sp who="#comp">
<p>A small black ball and a red ball.</p>
</sp>

Note:

It is important to distinguish the different nature of both identification mechanisms for speakers: <speaker> can only contain a literal transcription of a speaker label in the text source; @who can only contain an abstract identification code provided by the encoder.

Summary

The speeches of a drama text can be encoded in the <sp> element. In order to identify the speaking character, either the @who attribute may be used on the <sp> element, or the speaker label may be transcribed from the source text in a <speaker> element (or both mechanisms may be used together). Apart from the <speaker> label, speeches must contain structured text, either in <p>, <l> (possibly grouped in <lg>), or genre-neutral <seg> elements.

3.3. Stage directions

The encoding of all speeches in our example text would still leave some text structures uncovered: all fragments enclosed in parentheses or square brackets. These text fragments are not meant to be spoken in the performance, but rather convey directions on aspects of the performance. Such 'stage directions' can be transcribed with the <stage> element. Stage directions can address aspects of the acting, technical circumstances, locations, music, and so on. In order to distinguish between these different types of stage directions, the @type attribute can be used on the <stage> element. The encoder is free to develop an own typology for the kinds of stage directions.
Stage directions can occur in the transcription wherever they appear in the text source. In our example, the stage directions (between parentheses or square brackets) can be encoded as follows:
<div type="act">
<head>ACT I</head>
<div type="scene">
<head>SCENE 1: HELLO WORLD</head>
<stage>user, computer</stage>
<stage type="setting">In a clean room without windows, a table stands in the middle, carrying a computer screen. The screen blinks, the computer emits random beeps.</stage>
<stage type="technical">[A big screen on the left hand side of the stage displays the word HELLO, and will be used to project the contents of the computer screen. A big screen on the right hand stage of the stage displays the word WORD, until the action starts. Then, the user's face is filmed in close up and projected onto this screen.]</stage>
<stage type="entrance">(user enters room, walks towards the table, takes a seat, and reads what's on the screen)</stage>
<stage type="technical">[spotlight follows user]</stage>
<sp>
<speaker>COMP</speaker>
<p>Hello.</p>
</sp>
<stage type="gesture">(user looks around and starts typing)</stage>
<sp>
<speaker>USER</speaker>
<p>What is on the table?</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>The table does not exist.</p>
</sp>
<stage type="gesture">(user frowns)</stage>
<sp>
<speaker>USER</speaker>
<p>There is a table in the room.</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>Ok.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>What is on the table?</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>Nothing.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>There is a black box on the table.</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>Ok.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>What is on the table?</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>A black box.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>There is a black box on the table.</p>
</sp>
<stage type="technical">(computer beeps frantically)</stage>
<sp>
<speaker>COMP</speaker>
<p>I know.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>There is a red ball in the black box.</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>Ok.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>Where is the black box?</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>The black box is on the table.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>What is in the black box?</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>A red ball.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>Where is the black ball?</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>I don't know what black ball you are talking about.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>Where is the red ball?</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>In the black box.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>There is a black ball in the box.</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>Ok.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>The red ball is on the table.</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>In fact the red ball is in the box.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>The ball in the box is small.</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>I cannot understand such a sentence at the present time.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>The black ball is small.</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>I see.</p>
</sp>
<sp>
<speaker>USER</speaker>
<p>What is in the box?</p>
</sp>
<sp>
<speaker>COMP</speaker>
<p>A small black ball and a red ball.</p>
</sp>
<stage type="exit">(user smiles, stands up, takes a small green ball out of his pocket, walks away throwing and catching the ball)</stage>
<stage type="technical">[<name type="music.group">Kraftwerk</name>'s "<name type="music.song">Computer Love</name>" accompanies the exit]</stage>
</div>
</div>
The TEI Guidelines provide a specialised element for indicating movements of characters: the <move/> element. It may be used either to complement implicit movement descriptions in stage directions, or to formally document movement of characters when it is absent from the stage directions. Being an empty element, all information is conveyed in specific attributes. The @type attribute can be used to categorise the movement (for example: entrance and exit for stage entrance and exit, respectively; or onStage for movement on stage). The moving character(s) can be indicated in the @who attribute, as a whitespace-separated list of formal codes with which they are identified elsewhere in the transcription (see 4.1. Cast List). The @where attribute may be used to specify the direction of the movement. Any system of location information may be used (for example, C for "centre", L for "stage left", R for "stage right"), as long as it is identified in the header of the transcription.
In our example, the encoding of the entrance and exit of the user character could be formally enriched with the <move/> element:
<stage type="entrance"> <move who="#user" type="entrance" where="C"/> (user enters room, walks towards the table, takes a seat, and reads what's on the screen)</stage>
<!-- ... -->
<stage type="exit"> <move who="#user" type="exit" where="L"/> (user smiles, stands up, takes a small green ball out of his pocket, walks away throwing and catching the ball)</stage>
It is equally possible to distinguish technical stage directions from general stage directions, using specialised elements. Directions regarding sounds can be encoded using the <sound> element. The @type element can indicate what kind of sound is meant, while the @discrete attribute can specify whether the sound overlaps the surrounding speeches (false), or not (true). For example:
<stage type="setting">In a clean room without windows, a table stands in the middle, carrying a computer screen. The screen blinks, <sound type="soundEffect">the computer emits random beeps</sound>.</stage>
<!-- ... -->
<sound type="soundEffect" discrete="true">(computer beeps frantically)</sound>
<!-- ... -->
<sound type="music">[<name type="music.group">Kraftwerk</name>'s "<name type="music.song">Computer Love</name>" accompanies the exit]</sound>
Descriptions of the contents of a screen (usual in transcriptions of screen plays) can be encoded in a <view> element. In our example, this could apply to the description of both screens on the stage:
<stage type="technical">[<view>A big screen on the left hand side of the stage displays the word HELLO, and will be used to project the contents of the computer screen.</view> <view>A big screen on the right hand stage of the stage displays the word WORD, until the action starts. Then, the user's face is filmed in close up and projected onto this screen.</view>]</stage>
Specific camera directions can be encoded using the <camera> element, whose @type attribute can specify the direction:
<stage type="technical">[<view>A big screen on the left hand side of the stage displays the word HELLO, and will be used to project the contents of the computer screen.</view> <view>A big screen on the right hand stage of the stage displays the word WORD, until the action starts. Then, the user's face is filmed in <camera type="angle">close up</camera> and projected onto this screen.</view>]</stage>
Directions about text to be displayed on screen (usual in transcriptions of screen plays) can be encoded in a <caption> element. This could be applied to the directions on both screens on the stage:
<stage type="technical">[<view>A big screen on the left hand side of the stage displays the word <caption>HELLO</caption>, and will be used to project the contents of the computer screen.</view> <view>A big screen on the right hand stage of the stage displays the word <caption>WORD</caption>, until the action starts. Then, the user's face is filmed in <camera type="angle">close up</camera> and projected onto this screen.</view>]</stage>
Other technical stage directions, not meant for the actors can be encoded with the <tech> element, with a @type attribute for classifying the stage direction. The @type attribute must have one of following values: light, sound, prop, or block, indicating that the technical direction consist of a lighting, sound, prop, or blocking (i.e. related to position and movement on stage) cue, respectively.
<tech type="light">[spotlight follows user]</tech>

Summary

Stage directions, providing more information about the circumstances of the performance, may be transcribed using the <stage> element. The @type attribute can be used to further specify the kind of stage direction. Movement of characters can be formally encoded using the empty <move/> element. The type of movement can be specified in a @type attribute, a pointer to the moving character can be provided in the @who attribute, and the location of the movement can be specified in the @where attribute. More technical stage directions can be distinguished from more general ones by means of specific elements. Sound directions can be encoded with the <sound> element, whose @type attribute can specify the kind of sound described, while the @discrete attribute can specify whether the sound overlaps (false) with the dialogue or not (true). Descriptions of screen contents can be encoded with the <view> element. Specific camera instructions can be encoded with <camera>, whose @type attribute specifies the kind of camera instruction. Directions for screen captions can be encoded using the <caption> element. Other technical stage directions can be encoded in the <tech> element, whose @type attribute can be used to specify whether the stage direction concerns lighting cues (light), sound cues (sound), prop cues (prop), or blocking cues (block).