Experimental modifications to TEI dtd
Note:angle brackets represented in this document
by HTML entities
Changes made in local copy only.
Altered copies all have notes to that effect as
comment on first line of file.
The following steps appear to be necessary to
transform an existing standalone cb1.dtd file
into a base tag set for TEI, plus make the
necessary accompanying changes.
- The new base tag set is known by the
parameter entity %TEI.codebook.
- Its file name is
- It will be modelled on one or more of the other
TEI base tag sets, initially on that for dictionaries.
- It will at this stage declare no new parameter
entities in order to define content models or classes,
but will exclusively use standard TEI class and content-model
entities from the core set.
- It will at this stage neither modify standard
declarations for TEI parameter entities (like
"a.global" and such like), nor extend them,
using the "%x.----" files provided for local
- It use the other customization files
provided by TEI at this stage only to modify the
- Add following line to
teikey2.ent as line 25:
<!ENTITY % TEI.codebook 'INCLUDE' >
and change lines 36 and 38 to read:
<!ENTITY % TEI.names.dates 'INCLUDE' >
<!ENTITY % TEI.figures 'INCLUDE' >
- Add following lines to tei2.dtd
as lines 114-117:
<![ %TEI.codebook [
<!ENTITY % TEI.codebook.dtd system 'teicb1.dtd' >
- Rename file teigis2.ent as
- Change 'teigis2.ent' to 'teigiscb.ent' on line 31 of file
- Add additional entity declarations to
in each case declaring an entity of the form
%n.xxx to consist of the contents 'xxx'
<!ENTITY % n.results "results" >
and doing this for each of the element names used
in codebook.dtd. Thus "lbl" and "sumStat" and "dataMsng,"
which are referred to in the TEI-ready version of the
dtd as "%n.lbl" "%n.sumStat" and "%n.dataMsng" are in
this file translated into their ordinary tag names.
- Rewrite original standalone
cb1.dtd as teicb1.dtd
on model of teidict2.dtd and
teidict2.ent or similar TEI
base tag set dtd/ent combination.
- run "preparse" program using modified files with switches set
preparse -d tei2.dtd -o tei-codebook.dtd
This should generate a dtd including all the components of TEI
specified with INCLUDE values in teikey2.dtd, including the
new codebook.dtd in the form of teicb1.dtd.
Modifying the TEI Header
A fuller discussion of particular issues involved in making the
TEI header into a CodeBook header is available in a
separate file. But
the basic technical steps are noted here:
- Create two new files, cbheader.dtd and cbheader.ent.
- The latter file should contain all redefinitions of TEI parameter
entities, including the outright deletion of any element the content
model of which will be changed.
- The former file should contain all new element declarations.
- Both files are invoked by the document itself, in the dtd subset,
in the form:
<!ENTITY % TEI.extensions.ent system 'cbheader.ent' >
<!ENTITY % TEI.extensions.dtd system 'cbheader.dtd' >
This ensures that they will be processed before the dtd proper, and
will thus preempt any entity declarations made there.
Paul Schaffner :: Last revised 12 July 1996