LINK-GENERATOR(1)
π LINK-GENERATOR π β general commands manual, section 1, bestie π
okay so. you found the link-generator page. this is the general commands manual, section 1, and honestly? it's giving sentence factory. let's go. π¦
β¨ NAME β¨
link-generator β generate natural language sentences using Link Grammar πΈ
β¨ SYNOPSIS β¨
link-generator --help
link-generator --version
that's it, that's the whole vibe. short, sweet, iconic. π
β¨ DESCRIPTION β¨
so link-generator is a command-line tool that makes random sentences, and the syntax of those sentences is decided by whichever link-grammar dictionary you point it at. no cap. π
β¨ EXAMPLE β¨
link-generator
just run it. that's the whole example. periodt. β¨
π BACKGROUND π
the theory of Link Grammar is explained in so many academic papers, bestie. in the very first one β Daniel Sleator and Davy Temperley, "Parsing English with a Link Grammar" (1991) β the authors defined a whole new formal grammatical system called a "link grammar".
here's the tea: a sequence of words is in the language of a link grammar if there's a way to draw "links" between the words such 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. (yes, eight. they ate. π )
πΈ OVERVIEW πΈ
link-generator generates sentences.
that's the whole overview. it said what it said. π
β¨ OPTIONS β¨
--helpβ print usage and dip out. π--versionβ print the program version and the configuration details, then exit. the full receipts. π§Ύ--usageβ print a short synopsis of the option flags. the lil sneak peek. π- *
-l*language|dict_location,--language=language|dict_location β tell it which language to use, or give it the directory file-path to the dictionary you want. your call, main character. π«Ά - *
-s*length,--length=length β okay this one has two moods:- if length is
0, it reads a sentence template. that template can have fully spelled-out words and wild-cards. the wild-card\*represents any dictionary word. wild-card specifications likeprefix\*and\*.nare also recognized. β - otherwise, it specifies the length of the sentences to generate, and all generated sentences will have exactly this length. exact. no rounding, no vibes-based estimation. π―
- if length is
- *
-c*count,--count=count β specify how many sentences to generate. and here's where it gets detailed, so stay with me bestie:- 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 that representative sentence are randomly chosen from the set of words associated with each disjunct in that linkage.
- if count is greater than the number of possible linkages, then one representative sentence for each linkage will be printed.
- if the
-xoption is set, and 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! π like, genuinely. it goes boom.
-x,--explodeβ if set, and if 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. yes, the flag is literally called explode. π₯-d,--disjunctsβ display linkage disjuncts. show me the disjuncts. π--no-wallsβ don't attach to walls in wildcard words. no walls, no problem. π§±β-r,--randomβ use unrepeatable random numbers. chaotic on purpose. π²-u,--unusedβ display unused disjuncts. the forgotten ones get their moment. π₯Ή
π SEE ALSO π
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 Link Grammar website. π
peer-reviewed papers explaining Link Grammar can be found at the original CMU site. π
the source code of link-generator and the link-grammar library is located at GitHub. π»
the mailing list for Link Grammar discussion is at the link-grammar Google group. π¬
π AUTHOR π
the link-grammar library was 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 by Linas Vepstas <linasvepstas@gmail.com>. absolute legends, all of them. π
okay that's the whole page!! this is Version 5.9.0, dated 2021-03-30, and it lives in LINK-GENERATOR(1). go generate some sentences bestie, you got this πβ¨ππ¦
π¦ where this page comes from
- arch rolling: link-grammar 5.13.0-2 Β· LGPL-2.1-or-later
- debian trixie: link-grammar 5.12.5~dfsg-1+b3 Β· LGPL-2.1-only
- fedora 43: link-grammar 5.12.7-1.fc43 Β· LGPL-2.1-or-later
- fedora 43: link-grammar 5.12.7-1.fc43 Β· LGPL-2.1-or-later
- fedora 44: link-grammar 5.12.7-3.fc44 Β· LGPL-2.1-or-later
- fedora 44: link-grammar 5.12.7-3.fc44 Β· LGPL-2.1-or-later
- nixpkgs unstable: link-grammar 5.13.0
- opensuse-leap 16.0: link-grammar 5.12.5-bp160.1.9 Β· LGPL-2.1-only
- opensuse-leap 16.0: link-grammar 5.12.5-bp160.1.9 Β· LGPL-2.1-only
- opensuse-leap 16.0: link-grammar 5.12.5-bp160.1.9 Β· LGPL-2.1-only
- opensuse-leap 16.0: link-grammar 5.12.5-bp160.1.9 Β· LGPL-2.1-only
- ubuntu questing: link-grammar 5.12.5~dfsg-1build1
- ubuntu resolute: link-grammar 5.13.0+dfsg-1build1 Β· LGPL-2.1-only
- ubuntu stonking: link-grammar 5.13.0+dfsg-2 Β· LGPL-2.1-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms