Augmented Syntax Diagrams - Software available for free download
Copyright 2003-2010 James A. Mason
last update 2010 Aug 25
You are free to download and use the tools and examples at this
with appropriate acknowledgment of their origin, and for those licensed
under the Apache
2.0 license, in compliance with the terms of that license.
The tools and
are provided with no warranty expressed or implied.
This site now
the latest versions of
- ASDEditor (1.10) - a
graphical editor for ASD grammars
- ASDParser (1.08) - a
left-corner, bottom-up parser that uses ASD grammars
- ASDDecider (1.01) - a
modification of ASDParser to permit ASD grammar networks to be used as
decision networks, and to search them with unordered sets of decision
parameter value tokens, instead of the ordered lists of lexical tokens
which make up the phrases that ASDParser parses.
as the utility programs
- ASDCheck (1.01) - checks
an ASD grammar for well-formedness and also counts words and phrase
types, nodes and edges in the grammar
- ASDCount(1.01) - counts
words and phrase types, nodes, and total lines of text in an ASD
- ASDDeciderTester(1.01) -
allows testing of ASD grammars used as decision networks with
ASDDecider; it is a modification of ASDTester.
- ASDParseTest (1.02) -
allows testing of ASD grammars and parsing; has a command-line user
- ASDTester (1.06) - allows
testing of ASD grammars and parsing, including stepwise parsing and
display of phrase structure at each step; has a graphical user interface
- DefinedUsed (1.02) -
cross references ASD grammar files and the phrase types defined and
used in them
- MergeGrammars (1.01) -
merges ASD grammars from separate files into a single file
ASDEditor,ASDParser, ASDDecider, ASDCheck, and MergeGrammars are in each of the
ASDTester, ASDDeciderTester, and DefinedUsed are in the files asdx.jar,
. ASDCount and ASDParseTest are classes
defined in the Java default package; but ASDParseTest uses classes in the
To run the software you will need the Java Run-time
(JRE), which can be downloaded from Oracle's
site . If you want to develop additional
in Java that use the ASDParser, you will of course need the full Java
environment (Software Development Kit, or SDK), which can be downloaded
from the same site. You may also want to explore Oracle's
main Java site .
Downloadable files containing
See also the Examples link here or
above for downloadable files that implement various examples of the use
of Augmented Syntax Diagrams.
- asddigraphs.jar - a Java
file that contains the latest versions of the ASDEditor, the ASDParser,
as well as utility programs ASDCheck and MergeGrammars,
in Java SE 6.
specifically, it contains classes belonging to two packages: asd
See the release notes and javadoc
documentation for details of their use.
- asddigraphs.zip - a zip
the asddigraphs.jar file
- asddigraphs.tar.gz -
version of the asddigraphs.jar file suitable for downloading
- asdx.jar - a Java Archive file that
code for the latest versions of the utility programs ASDTester
whose source code is available via links below.
- asdx.zip - a zip file containing the asdx.jar
- asdx.tar.gz - a compressed version of
file suitable for downloading to Unix systems.
- open source code licensed under the Apache 2.0 license.
Notes: (1) The source code
ASDParser.java involves intricate data structures and algorithms.
Additional documentation of these will be provided subsequently at this
site. Users are advised not to attempt modifications of ASDParser.
the author was learning the intricacies of Java awt and Swing
components. It could well be improved. Suggestions for its
improvement will be welcomed.
- ASDTester.java - the Java
code for a program to test ASD grammars with the ASDParser. This
program is a major improvement over ASDParseTest (see
It runs in its own window and sends its output to a scrollable pane in
that window, rather than to System.out. The program is included
the package asdx, which is in each of the downloadable binary files
asdx.zip, and asdx.tar.gz .
ASDTester can be run with one of the following commands:
From an MS-Windows command window: java -cp
From a Unix command window: java -cp
Alternatively, if you add the asddigraphs.jar and asdx.jar
files to your system's CLASSPATH, then you can simply use
See the release notes for more details
about the latest version.
- ASDDeciderTester.java - the
Java source code for a program to test ASD grammars which are used to
represent decision networks with ASDDecider. It is a modification
of, and can be run in a similar manner to, ASDTester.java.
code for a tool for indexing and cross-referencing a collection of ASD
grammar files, as specified in a "build" list of the kind that is used
by the MergeGrammars utility (which is in the asd
in archive asddigraphs.jar above). The compiled DefinedUsed
utility is in the asdx package (which is in the archive asdx.jar
above.) It produces an index that relates phrase types to the
in which they are defined and the files in which they are used.
lists all undefined phrase types and unused phrase types in the given
of grammar files. Finally, it cross references the grammar files
themselves according to which other grammar files they depend on and
they support. It can be used as follows, where buildListFileName
is the name of the file that contains the "build" list of grammar
and outputFileName is the name for a file to which DefinedUsed
is to write its output.
From an MS-Windows command window:
java -cp asddigraphs.jar;asdx.jar;.
< buildListFileName > outputFileNameFrom a Unix
java -cp asddigraphs.jar:asdx.jar:.
< buildListFileName > outputFileName Alternatively, if
add the asddigraphs.jar and asdx.jar files to your
CLASSPATH, then you can simply use
java asdx/DefinedUsed < buildListFileName >
class file ASDCount.class - a
tool for counting words, instances, and lines in an ASD grammar file. Usage:
ASDCount < grammarFileName
- ASDParseTest - a first
of a program to test grammars with instances of ASDParser. It is