Skip to main content

LEAF-Writer Basics Step-by-Step Tutorial

Getting started and markup fundamentals

By Diane Jakacki

These exercises will walk you through the steps to perform basic structural, semantic, entity, and note markup using LEAF-Writer. There are five sections:

1. Set Up
2. Exercise 1: Structural Markup
3. Exercise 2: Other Semantic Markup
4. Exercise 3: Entity Markup
5. Exercise 4: Note Markup

The exercises are from a workshop given at TEI 2022.

To learn more about marking up documents using LEAF-Writer, watch LEAF-Writer Tutorial 1 and LEAF-Writer Tutorial 2.

Set Up

If you are not already set up in LEAF-Writer, you will need a GitHub account to sign into LEAF-Writer so you can access and work with the exercise files.

  1. If you don't have a GitHub account, create one at http://github.com/.
  2. Go to the GitHub repository https://github.com/LEAF-VRE/training.
  3. Fork the repository (create a copy of it in your personal GitHub account) by selecting Fork on the upper right.
  4. Sign in to https://leaf-writer.leaf-vre.org.

Exercise 1: Structural Markup

Structural markup provides information about the structure of a document. In this exercise, you will mark up a poem to provide information about its lines and emphasis.

Tag Lines

  1. Select From the Cloud and navigate into the training repository, the getting started folder, and then the exercises folder to open exercise1_macavity.
  2. Select Don't Show Again in the Editor Mode pop-up.
  3. Select the Image Viewer tab on the right to see an image of the print version of the poem.
  4. Highlight "Macavity, Macavity, there's no one like Macavity," below line 4.
  5. Select Tags on the far left of the ribbon at the top of the screen.
  6. Find the l (verse line) tag by typing it into the search box or scrolling down the list of tags.
  7. Select the l tag from the list and then select OK.
  8. Try another way of tagging a line — highlight the line text, right click, and then select Add Tag, l, and OK.
  9. Add l tags to the remaining lines in the poem using both methods.
  10. Edit the tags around the first line of the poem, which has been mistakenly tagged as a salutation, by clicking on the line, right clicking on salute in the Markup panel on the left, and selecting Change Tag from the dropdown menu, l, and OK.

Tag Emphasis

  1. Highlight "Macavity's not there!" on line 5.
  2. Select Tags on the far left of the ribbon at the top of the screen.
  3. Find the emph (emphasized) tag by typing it into the search box or scrolling down the list of tags.
  4. Select the emph tag from the list and then select OK.
  5. Add emph tags to all the words italicized in the print version.

As you add tags, you will see them appear in the Markup panel on the left. You can also see raw code in the Selection tab on the right. Using the Markup panel and the Selection tab, see if you can find the tags you added.

Exercise 2: Other Semantic Markup

Structural markup is a kind of semantic markup, or markup about what data means rather than its presentation and style. In this exercise, you will mark up a salutation, signatures, and a dateline in a letter.

Tag a salutation

  1. Select From the Cloud to open exercise2_letter-congress in training\gettingstarted\exercises.
  2. Right click on the first p in the Markup pane.
  3. Select Change Tag from the dropdown menu.
  4. Select opener and OK.
  5. Right click on opener in the Markup pane.
  6. Select Add Tag Inside from the dropdown menu.
  7. Select salute and OK.

Tag signatures and a dateline

  1. Right click the last p in the Markup pane.
  2. Select Change Tag from the dropdown menu.
  3. Select closer and OK.
  4. Highlight "Elizabeth Cady Stanton."
  5. Select Tags on the far left of the ribbon at the top of the screen.
  6. Select the signed tag from the list and then select OK.
  7. Add signed tags around the other names in the closer.
  8. Highlight "Dec. 1871" and add a dateline tag around it.

Exercise 3: Entity Markup

Entity markup allows you to give data, like data about people and places, semantic meaning through the use of standard identifiers (IDs). These IDs can link the same things across your own documents or create interoperability with external data when the same IDs are used by many people. In this exercise, you will tag people, place, organization, and date entities in a letter.

Tag a Person

  1. Select From the Cloud to open exercise3_letter-congress in training\gettingstarted\exercises.
  2. Highlight "Elizabeth Cady Stanton."
  3. Select Tag Person alt="Tag Person" in the ribbon (to the right of Tags).
  4. Under Wikidata, select American writer, suffragist, and women's rights activist and then Select.
  5. Add a certainty value of high and then select OK.

Tag a Place

  1. Highlight "Hartford."
  2. Select Tag Place alt="Tag Place" in the ribbon (to the right of Tag Person).
  3. Under Wikidata, select the city in Connecticut, United States, and then Select.
  4. Add a certainty value of high and then select OK.

Tag an Organization and Date — Try It for Yourself

  1. Experiment with tagging the United States "Congress" by using Tag Organization alt="Tag Organization" (to the right of Tag Place).
  2. Experiment with tagging the date of "1871" by using Tag Date alt="Tag Date" (a few icons to the right of Tag Organization).

Exercise 4: Note Markup

LEAF-Writer allows you to add notes to a document, as one way of creating a scholarly apparatus for it. In this exercise, you will add a research note and scholarly notes to a poem.

Tag a Research Note

  1. Select From the Cloud to open exercise4_ebb in training\gettingstarted\exercises.
  2. Place the cursor at the end of line 5 to add a Research Note there.
  3. Select Tag Note alt="Tag Note" (to the left of Tag Date) in the ribbon and add a note with the Type of Research Note.
  4. Add the Note Text, "I need to doublecheck punctuation of transcription."
  5. Select OK.

Tag a Scholarly Note

  1. Copy the text of the first Scholarly Note at the bottom of the file.
  2. Place the cursor at the end of line 1 to add a Scholarly Note there.
  3. Select Tag Note in the ribbon and add a note with the Type of Scholarly Note.
  4. Paste the text of first copied scholarly note into the Note Text.
  5. Select OK.
  6. Add the other two Scholarly Notes at the bottom of the file to the correct lines.