summaryrefslogtreecommitdiff
path: root/decoder
diff options
context:
space:
mode:
Diffstat (limited to 'decoder')
-rw-r--r--decoder/cdec.cc1
-rw-r--r--decoder/lexcrf.cc2
2 files changed, 2 insertions, 1 deletions
diff --git a/decoder/cdec.cc b/decoder/cdec.cc
index c6a0057f..d517e451 100644
--- a/decoder/cdec.cc
+++ b/decoder/cdec.cc
@@ -71,6 +71,7 @@ void InitCommandLine(int argc, char** argv, po::variables_map* conf) {
("show_expected_length", "Show the expected translation length under the model")
("show_partition,z", "Compute and show the partition (inside score)")
("beam_prune", po::value<double>(), "Prune paths from +LM forest")
+ ("lexcrf_use_null", "Support source-side null words in lexical translation")
("tagger_tagset,t", po::value<string>(), "(Tagger) file containing tag set")
("csplit_output_plf", "(Compound splitter) Output lattice in PLF format")
("csplit_preserve_full_word", "(Compound splitter) Always include the unsegmented form in the output lattice")
diff --git a/decoder/lexcrf.cc b/decoder/lexcrf.cc
index 816506e4..9f96de9f 100644
--- a/decoder/lexcrf.cc
+++ b/decoder/lexcrf.cc
@@ -12,7 +12,7 @@ using namespace std;
struct LexicalCRFImpl {
LexicalCRFImpl(const boost::program_options::variables_map& conf) :
- use_null(false),
+ use_null(conf.count("lexcrf_use_null") > 0),
kXCAT(TD::Convert("X")*-1),
kNULL(TD::Convert("<eps>")),
kBINARY(new TRule("[X] ||| [X,1] [X,2] ||| [1] [2]")),