LINK-GENERATOR(1)

NAME
link-generator - generate natural language sentences using Link Grammar

SYNOPSIS
link-generator --help
link-generator --version

DESCRIPTION

link-generator is a command-line tool for generating random sentences whose syntax is determined by the specified link-grammar dictionary.

EXAMPLE
    link-generator

BACKGROUND
The theory of Link Grammar is explained in many academic papers. In the first of these, Daniel Sleator and Davy Temperley, "Parsing English with a Link Grammar" (1991), the authors defined a new formal grammatical system called a "link grammar". A sequence of words is in the language of a link grammar if there is a way to draw "links" between words in such a way that the local requirements of each word are satisfied, the links do not cross, and the words form a consistent connected graph. The authors encoded English grammar into such a system, and wrote the link-parser command-line tool to parse English using this grammar.

The engine that performs the parsing is separate from the dictionaries describing a language. Currently, the most fully developed, complete dictionaries are for the English and Russian languages, although experimental, incomplete dictionaries exist for German and eight other languages.

OVERVIEW

link-generator generates sentences.

OPTIONS

--help
    Print usage and exit.

--version
    Print program version and configuration details, and exit.

--usage
    Print a short synopsis of the option flags.

-l language|dict_location, --language=language|dict_location
    Specify the language to use, or the directory file-path to the dictionary to use.

-s length, --length=length
    If length is 0, read a sentence template. It may consist of fully spelled-out words as well as wild-cards. The wild-card \* represents any dictionary word. Wild-card specifications like prefix\* and \*.n are also recognized. Otherwise, it specifies the length of the sentences to generate. All generated sentences will have exactly this length.

-c count, --count=count
    Specify the number of sentences to generate. If this number is less than the number of possible linkages, then a random subset of possible linkages will be generated, and one representative sentence for each linkage will be printed. The words in the representative sentence are randomly chosen from the set of words associated with each disjunct in that linkage. If the count is greater than the number of possible linkages, then one representative sentence for each linkage will be printed. If the -x option is set, and if the count is greater than the number of possible linkages, then more than one representative sentence will be printed for each linkage. Each sentence will consist of word choices drawn randomly from the set of words associated with each disjunct. An approximately equal number of sentences will be printed for each linkage; if the count is high enough, then all possible word-choices will be printed. Note that this typically results in a combinatorial explosion!

-x, --explode
    If set, and is the count is greater than the number of possible linkages, then more than one sentence will be printed for each linkage. Each sentence will have a distinct random word-choice for that linkage.

-d, --disjuncts
    Display linkage disjuncts.

--no-walls
    Don't attach to walls in wildcard words.

-r, --random
    Use unrepeatable random numbers.

-u, --unused
    Display unused disjuncts.

SEE ALSO
The link-parser is a command-line tool for parsing sentences. It provides some additional information about the link-grammar implementation.

Information on the link-grammar shared-library API and the link types used in the parse is available at the AbiWord website (http://www.abisource.com/projects/link-grammar/).

Peer-reviewed papers explaining Link Grammar can be found at original CMU site (http://www.link.cs.cmu.edu/link/papers).

The source code of link-generator and the link-grammar library is located at GitHub (https://github.com/opencog/link-grammar).

The mailing list for Link Grammar discussion is at link-grammar Google group (http://groups.google.com/group/link-grammar?hl=en).

AUTHOR
The link-grammar library were written by Daniel Sleator <sleator@cs.cmu.edu>, Davy Temperley <dtemp@theory.esm.rochester.edu>, and John Lafferty <lafferty@cs.cmu.edu>. The link-generator tool was created by Amir Plivatsky <amirpli_at_gmail.com>.

This manual page was written by Ken Bloom <kbloom@gmail.com>, for the Debian project, and updated Linas Vepstas <linasvepstas@gmail.com>.