diff options
author | Patrick Simianer <simianer@cl.uni-heidelberg.de> | 2012-08-01 17:32:37 +0200 |
---|---|---|
committer | Patrick Simianer <simianer@cl.uni-heidelberg.de> | 2012-08-01 17:32:37 +0200 |
commit | 3f8e33cfe481a09c121a410e66a6074b5d05683e (patch) | |
tree | a41ecaf0bbb69fa91a581623abe89d41219c04f8 /decoder/translator.h | |
parent | c139ce495861bb341e1b86a85ad4559f9ad53c14 (diff) | |
parent | 9fe0219562e5db25171cce8776381600ff9a5649 (diff) |
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'decoder/translator.h')
-rw-r--r-- | decoder/translator.h | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/decoder/translator.h b/decoder/translator.h index cfd3b08a..c0800e84 100644 --- a/decoder/translator.h +++ b/decoder/translator.h @@ -58,8 +58,8 @@ class SCFGTranslatorImpl; class SCFGTranslator : public Translator { public: SCFGTranslator(const boost::program_options::variables_map& conf); - void SetSupplementalGrammar(const std::string& grammar); - void SetSentenceGrammarFromString(const std::string& grammar); + void AddSupplementalGrammar(GrammarPtr gp); + void AddSupplementalGrammarFromString(const std::string& grammar); virtual std::string GetDecoderType() const; protected: bool TranslateImpl(const std::string& src, @@ -85,4 +85,17 @@ class FSTTranslator : public Translator { boost::shared_ptr<FSTTranslatorImpl> pimpl_; }; +class RescoreTranslatorImpl; +class RescoreTranslator : public Translator { + public: + RescoreTranslator(const boost::program_options::variables_map& conf); + private: + bool TranslateImpl(const std::string& src, + SentenceMetadata* smeta, + const std::vector<double>& weights, + Hypergraph* minus_lm_forest); + private: + boost::shared_ptr<RescoreTranslatorImpl> pimpl_; +}; + #endif |