mosesdecoder/scripts/training/phrase-extract/score.h
2010-07-28 21:28:14 +00:00

19 lines
351 B
C++

#pragma once
/*
* score.h
* extract
*
* Created by Hieu Hoang on 28/07/2010.
* Copyright 2010 __MyCompanyName__. All rights reserved.
*
*/
#include <string>
inline bool isNonTerminal( std::string &word )
{
return (word.length()>=3 &&
word.substr(0,1).compare("[") == 0 &&
word.substr(word.length()-1,1).compare("]") == 0);
}