Files
gf-core/doc/gf-quickstart.html
2010-12-22 14:08:42 +00:00

72 lines
1.9 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html><head><title>GF Quickstart</title></head>
<body bgcolor="#ffffff" text="#000000">
<center>
<img src="Logos/gf0.png">
<p>
Aarne Ranta
<p>
22 December 2010 (3 September, 2007)
<p>
<h1>Grammatical Framework Quick Start</h1>
</center>
This Quick Start shows two examples of how GF can be used.
We assume that you have downloaded and installed GF, so that
the command <tt>gf</tt> works for you. See download and install
instructions <a href="../download/index.html">here</a>.
<h2>Translation and generation</h2>
When you have downloaded and installed GF:
<ol>
<li> Copy the files
<a href="../examples/tutorial/food/Food.gf"><tt>Food.gf</tt></a>,
<a href="../examples/tutorial/food/FoodEng.gf"><tt>FoodEng.gf</tt></a>, and
<a href="../examples/tutorial/food/FoodIta.gf"><tt>FoodIta.gf</tt></a>.
Or go to <tt>GF/examples/tutorial/food/</tt>, if you have downloaded the
GF sources.
<li> Start GF with the command
<pre>
gf FoodIta.gf FoodEng.gf
</pre>
<li> <b>Translation</b>. Try your first translation by giving the GF command
<pre>
parse "this cheese is very very Italian" | tree_bank
</pre>
<li> <b>Generation</b>. Random-generate sentences in two languages:
<pre>
generate_random | l -multi
</pre>
<li> <b>Grammar development</b>. Add words to the <tt>Food</tt>
grammars and try the above commands again. For instance, add the following lines:
<pre>
Bread : Kind ; -- in Food.gf
Black = {s = "bread"} ; -- in FoodEng.gf
Black = {s = "pane"} ; -- in FoodIta.gf
</pre>
and start GF again with the same command. Now you can even translate
<i>this bread is very Italian</i>.
</ol>
To lear more on GF commands and
grammar development, go to the one of the tutorials:
<ul>
<li> <a href="tutorial/gf-tutorial.html">GF Tutorial</a>: older, more programmer-oriented
<li> <a href="gf-lrec-2010.pdf">GF Resource Tutorial</a>: newer, more linguist-oriented
</ul>
</body></html>