Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

This software classifies mistakes in the output of parsers. For a full description of the method, and discussion of results when applied to a range of well known parsers, see:

Parser Showdown at the Wall Street Corral: An Empirical Investigation of Error Types in Parser Output, Jonathan K. Kummerfeld, David Hall, James R. Curran, and Dan Klein, EMNLP 2012

An Empirical Examination of Challenges in Chinese Parsing, Jonathan K. Kummerfeld, Daniel Tse, James R. Curran, and Dan Klein, ACL (short) 2013

To use the system, download it one of these ways, and run as shown below:

If you use my code in your own work, please cite the following papers (for English and Chinese respectively):

  author    = {Jonathan K. Kummerfeld  and  David Hall  and  James R. Curran  and  Dan Klein},
  title     = {Parser Showdown at the Wall Street Corral: An Empirical Investigation of Error Types in Parser Output},
  booktitle = {Proceedings of the 2012 Joint Conference on Empirical Methods in Natural Language Processing and Computational Natural Language Learning},
  address   = {Jeju Island, South Korea},
  month     = {July},
  year      = {2012},
  pages     = {1048--1059},
  software  = {},
  url       = {},

  author    = {Jonathan K. Kummerfeld  and  Daniel Tse  and  James R. Curran  and  Dan Klein},
  title     = {An Empirical Examination of Challenges in Chinese Parsing},
  booktitle = {Proceedings of the 51st Annual Meeting of the Association for Computational Linguistics (Volume 2: Short Papers)},
  address   = {Sofia, Bulgaria},
  month     = {August},
  year      = {2013},
  pages     = {98--103},
  software  = {},
  url       = {},

Here is an example of system output (red brackets are extra, blue are missing and yellow are crossing):

Image of system terminal output

If you find a bug please submit an issue, and if you have a question please contact me. I am not actively working on this project anymore, but will try to respond to feedback when possible.

Running the System

There are four main programs:

  •, Classify errors in English output
  •, Classify errors in Chinese output
  •, Print errors using colour in a plain text format (red for extra brackets, blue for missing brackets, yellow for crossing brackets, and white for correct brackets)
  •, Reprint a set of trees in a different format (e.g. single line or multiline, plain text or latex), edits such as removing traces can also be applied

Running each with no arguments will provide help information. Here are some example commands using the provided sample data:

English errors:
./berkeley_parse_analyser/ sample_data/wsj01.mrg sample_data/berkeley.mrg classified.english.berkeley

Coloured errors:
./berkeley_parse_analyser/ sample_data/wsj01.mrg sample_data/berkeley.mrg coloured_errors.english.berkeley

For the error analysis runs the files produced are:

  • classified.berkeley.error_counts - The errors, their occurence, and the number of brackets attributed to them (frequency first, then number of brackets attributed)
  • classified.berkeley.init_errors - A pretty-print presentation of the initial errors (red indicates extra spans, blue indicates missing spans, and yellow are missing spans that cross current spans)
  • classified.berkeley.out - The complete output of the classification, including each step in each path
  • classified.berkeley.log - A log of system notes
  • classified.berkeley.test_trees - The test trees
  • classified.berkeley.gold_trees - The gold trees

For the coloured output it can help to view the files as follows (with -x3 to avoid the trees getting too wide):

less -x3 <filename>


Q: How can I view the output files?

All of the output files are plain text. View their contents with tools like less, nano, or vim:

less <filename>

Q: How can I make a bar figure like in the papers?

In LaTeX, define these two lengths:


Then write this for each box, (it makes a thick horizontal rule, inside a frame box):


Defining new commands can make it easier to create a whole lot of boxes:


And then write:


Q: What do I need to do to see the colours in the output files?

If you are not seeing colours when you look at the output files (e.g. by running less <filename>) it may be because your terminal is not interpreting raw ANSI escape codes. For less this can be changed by passing the -R flag (or -r).

Q: Other questions?

Either open an issue or contact me! See for my contact info.