To help processing of files using the schema described above, we provide a Python module that reads and writes XML. To use this module, you must have these files in the current directory:
birdnotes.py: The principal Python
module.
rnc.py: A module containing
symbolic names for all the element and attribute names
from the schema.
All the program and data files required for the
taxonomy package, A
system for representing bird taxonomy: txny.py, rnc_txny.py, and one of the AOU Check-List
files, named aou.xml.
Once these files are installed, your Python script must import it with a line like this:
from birdnotes import *
Here is the general flow of a program that reads notes using this module:
Instantiate a Txny object representing
the aou.xml file defining the
desired taxonomic arrangement of birds.
Instantiate a BirdNoteSet object,
passing it the Txny instance.
For each XML file you want to read, call the .readFile() method on the BirdNoteSet object.
The interfaces to the BirdNoteSet class and
the various other classes are defined in separate sections
below. Here is a diagram showing the classes and their
relationships, except for Txny which is
external to this module.

In addition to the classes shown above, two classes are used throughout the structure to represent mixed content as defined in Section 5.15, “The narrative elements”.