\chapter{Introduction}

The {\agfl} system is a parser generator for research and applications
in Natural Language Processing, based on the {\agfl} formalism
\cite{KOS91a} and available under the GNU General Public
License.  The system was developed by the \informatica\
at the \KUN\ with support from the national Dutch Research Organization
NWO and the Stichting NLnet.

The {\agfl} formalism for the syntactical description of natural languages
belongs to the family of two-level
grammars: a context free grammar is augmented with set-valued features
for expressing agreement between syntactic categories. The formalism is
suited for describing morphological structure and syntactic
structure, case distinction and agreement and finite semantics.
Grammar rules may
be extended with transduction parts, which specify the output.
Grammars and lexica may be combined in a modular fashion.
Penalties may be used to express syntactical preferences.
Frequencies given in the lexicon and the syntax form the basis for
hybrid parsing. Mechanisms
are provided to handle open classes of words, which enables the
construction of robust parsers.

This document describes the {\agfl} system.  It serves as a user
manual to the {\agfl} formalism, the compiler and the generated parsers.
Other publications concerning \agfl\ are available at the \agfl\ website
at {\AGFLweb}.

\section{The AGFL system}

The {\agfl} system consists of the following components:
\begin{itemize}
\item the \agfl\ parser-generator
\item the \lexgen\ lexicon system
%\item {[}the Grammar Workbench \gwb]
\end{itemize}

The \agfl\ parser-generator compiles grammars written in the \agfl\
formalism into compact and efficient parsers. These parsers are
stand-alone executables, reading sentences from a file, or prompting
the user for input. Output consists either of decorated parse-trees
in one of several formats, or of strings as specified by the transduction.

The \lexgen\ lexicon system makes it possible to connect large lexical
databases to your grammars in an efficient way. The lexicon system is
fully integrated with the parser-generator. 
When necessary, \agfl\ automatically invokes the lexicon system.

It is our intention to embed the AGFL system into a Grammar Workbench,
or \gwb\ for short, an environment for the comfortable development of
grammars in the {\agfl} formalism. Its intended purposes are:
\begin{itemize}
\item to serve as a graphical user interface to the parser generator
and the parsers generated;
\item {[} to provide an incremental syntax check in reading a grammar ];
\item {[} to allow the user to navigate, inspect and modify a grammar, using
      a dedicated editor ];
\item to perform consistency checks on the grammar;
\item to compute grammar properties;
\item {[} to perform profiling of a parser ];
\item {[} to allow incremental tracing of a parser's execution ];
\item to generate example sentences;
\item {[} to assist in performing grammar transformations ].
\end{itemize}
Although most of these features have been present in earlier versions
of the AGFL system, due to lack of implementation manpower the features
between square brackets are currently not available. Any volunteers?

\subsection{About version 2.5}
Version 2 of the {\agfl} system was developed with support from
Stichting NLnet in the AGFL/GNU project, and brought under the GNU
Public License in January 2002. The present version 2.5 of \agfl\
differs in some points from the previous versions:
\begin{enumerate}
\item small syntactic differences were needed to make the handling of
lexica simpler
\item several small changes in the syntax of AGFL
\item optimization of positive memoization by tree folding and the
best-only heuristic
\item different options and system behaviour
\item addition of an example generator for testing grammars.
\item implementation of left-recursive grammars
\end{enumerate}
The most striking improvement is the speed of determining an optimal
analysis, allowing probabilistic parsing and
making the system more paractical for applications.

\subsection{Copyright and License Information}
The copyright on the {\agfl} system has been transferred from
\informatica\ at the \KUN\ to the Free Software Foundation. All
components of the {\agfl} system are licensed under the GPL or the LGPL
license. The runtime system ({\tt lib*rts.a}, {\tt lib*rts.so.*} and
associated header files) is licensed under LGPL and the executables
are licensed under the GPL. All source files also contain a reference
to the appropriate license. The licenses can be found in the files
{\tt COPYING} and {\tt COPYING.LIB} in the source package, and on\\
{\tt http://www.gnu.org/licenses/licenses.html}.

\subsection{Availability and Support}\label{available}
The {\agfl} system is presently available for the following architectures:
\begin{itemize}
\item Sun-4 (Sparc/Solaris)
\item PC (i386 and higher; WIN2K/NT/XP)
\item PC (i386 and higher; Linux, FreeBSD)
\item Alpha (NetBSD)
\end{itemize}
You can obtain the {\agfl} system from the \agfl\ WWW-site at
\begin{quote}
\verb+http://www.cs.kun.nl/agfl/+
\end{quote}
or by anonymous FTP from
\begin{quote}
\verb+ftp://ftp.cs.kun.nl/pub/agfl+
\end{quote}

At the \agfl\ WWW-site, you can register yourself as a user.
If you do so, you will be informed about new releases of
the system and other relevant information. If you experience
problems or have any questions, you can send e-mail to \AGFLmail.
Bug reports should be sent to the same address.

\section{Outline of this Manual}
Chapter \ref{ch:intro} provides a short overview of \agfl. Chapter
\ref{ch:grammar} provides the complete syntax of \agfl, annotated with
informal semantics and pragmatic remarks. The CF formalism used to
describe the {\agfl} formalism is itself described in chapter
\ref{ch:formalism}. Chapter \ref{ch:inout} goes into details about the
input (lexicalization process, input styles) and output (parse tree
representations, transduction).
Chapter \ref{ch:system} describes the installation and use of the
\agfl\ system, as well as the use of the generated parsers.
