// #ifndef moses_SyntacticLanguageModel_h #define moses_SyntacticLanguageModel_h #include "FeatureFunction.h" class YModel; // hidden model class XModel; // observed model namespace Moses { template class SyntacticLanguageModelFiles; class SyntacticLanguageModel : public StatefulFeatureFunction { public: SyntacticLanguageModel(const std::vector& filePaths, const std::vector& weights, const FactorType factorType, const size_t beamWidth); ~SyntacticLanguageModel(); size_t GetNumScoreComponents() const; std::string GetScoreProducerDescription(unsigned) const; std::string GetScoreProducerWeightShortName(unsigned) const; const FFState* EmptyHypothesisState(const InputType &input) const; FFState* Evaluate(const Hypothesis& cur_hypo, const FFState* prev_state, ScoreComponentCollection* accumulator) const; // double perplexity(); private: const size_t m_NumScoreComponents; SyntacticLanguageModelFiles* m_files; const FactorType m_factorType; const size_t m_beamWidth; }; } #endif