HFST - Helsinki Finite-State Transducer Technology API
version 3.7.1
|
You can download the source code packet hfst-3.x.x.tar.gz from sourceforge download page. Extract all files with the command
tar -xzvf hfst-3.x.x.tar.gz
move to directory hfst-3.x.x and run the commands
autoreconf -i && ./configure && make && make install
To successfully use the HFST library, you should have at least one of the backend libraries installed on your computer: <a href="http://www.ims.uni-stuttgart.de/projekte/gramotron/SOFTWARE/SFST.html">SFST</a> (version 1.4.6g), <a href="http://www.openfst.org">OpenFst</a> (version 1.3.1) or <a href="http://code.google.com/p/foma/">foma</a> (version 0.9.16alpha). The in-built HfstTransitionGraph format is very limited in its operations and used mainly for conversion between different binary and text formats. The HFST optimized lookup transducer format also comes with the source code, but it has also a very limited selection of operations as its main purpose is fast lookup of strings. By default, the configure script will make HFST compile the interface with OpenFst as the only backend implementation. If you do or do not want an implementation, you can specify it with configure options. For example
./configure --with-sfst=true --with-openfst=false
will exclude the OpenFst and include the SFST implementation. If an implementation that was not included when compiling the interface is requested, e.g in the case above,
HfstTransducer tr("a", "b", FOMA_TYPE);
an ImplementationTypeNotAvailableException is thrown. The command 'make' will compile all the API and command line tools and 'install' will install them to /usr/local. If you would rather install in eg. your home directory, you can tell ./configure:
./configure --prefix=${HOME}