Scroll to navigation

HFST-LOOKUP(1) User Commands HFST-LOOKUP(1)

NAME

hfst-lookup - =perform transducer lookup (apply)

SYNOPSIS

hfst-lookup [OPTIONS...] [INFILE]

DESCRIPTION

perform transducer lookup (apply) NOTE: hfst-lookup does lookup from left to right as opposed to xfst and foma

lookup which is carried out from right to left. In order to do lookup in a similar way as xfst and foma, use 'hfst-flookup' instead.

Common options:

Print help message
Print version info
Print verbosely while processing
Only print fatal erros and requested output
Alias of --quiet

Input/Output options:

Read input transducer from INFILE
Write output to OUTFILE

-p, --pipe-mode[=STREAM] Control input and output streams

Lookup options:

Read lookup strings from SFILE
Use OFORMAT printing results sets
Print epsilon as EPS
Use IFORMAT parsing input
Print statistics
Toggle xfst VARIABLE
How many times to follow input epsilon cycles (only for non-lookup-optimized transducers)
Maximum number of results printed for each input (only for lookup-optimized transducers)
Output only analyses whose weight is within B from the best analysis
Limit search after having used S seconds per input (only for lookup-optimized transducers)
How multiple transducers in input are handled
Show neat progress bar if possible

If OUTFILE or INFILE is missing or -, standard streams will be used. Format of result depends on format of INFILE OFORMAT is one of {xerox,cg,apertium}, xerox being default IFORMAT is one of {text,spaced,apertium}, default being text, unless OFORMAT is apertium VARIABLEs relevant to lookup are {print-pairs,print-space, quote-special,show-flags,obey-flags} Input epsilon cycles are followed by default INT=5 times. Epsilon is printed by default as an empty string. B must be a non-negative float. S must be a non-negative float. The default, 0.0, indicates no cutoff. If the input contains several transducers, a set containing results from all transducers is printed for each input string.

CASCADE must be one of { union, priority-union, composition }. If not specified, defaults to {union}.

STREAM can be { input, output, both }. If not given, defaults to {both}. If input file is not specified with -I, input is read interactively line by line from the user. If you redirect input from a file, use --pipe-mode=input. --pipe-mode=output is ignored on non-windows platforms.

Todo:

Support --xfst=obey-flags for optimized lookup format. Support --cycles for optimized lookup format.

Known bugs:

'quote-special' quotes spaces that come from 'print-space'

REPORTING BUGS

Report bugs to <hfst-bugs@helsinki.fi> or directly to our bug tracker at: <https://github.com/hfst/hfst/issues>

hfst-lookup home page: <https://github.com/hfst/hfst/wiki/HfstLookup>
General help using HFST software: <https://github.com/hfst/hfst/wiki>

COPYRIGHT

Copyright © 2017 University of Helsinki, License GPLv3: GNU GPL version 3 <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.

August 2018 HFST