Moses uses features to discriminate between alternative translations of individual sentences, so if the value is constant for all possible translations (for example, because it is a function of the input), the model won't be able to take advantage of it. It sounds like you might be proposing something like this. What are you trying to do?
-Chris On Thu, Mar 25, 2010 at 8:14 PM, Suzy Howlett <[email protected]> wrote: > Hi, > > I am just starting my foray into the world of adding features to Moses > and haven't quite got my head around it yet. Could someone please > check I'm on the right track, or tell me if I've overlooked an easier > alternative? > > The feature that I want to add is essentially a sentence-level flag to > say whether a given input sentence has undergone a particular kind of > preprocessing before being passed to Moses. My best guess is that I > need to create a file containing a look-up table to indicate which > sentences have been preprocessed, e.g. > > <Sentence 1> ||| 0 > <Sentence 2> ||| 0 > <Sentence 3> ||| 1 > <Sentence 4> ||| 0 > ... > > where 1 and 0 indicate that the sentence has and has not been > preprocessed, respectively. Is this the best way to do it? Does anyone > know of anyone doing something similar before? > > I imagine I will need a StatelessFeatureFunction that will open the > file and read off the value for the input sentence, and two parameters > added with AddParam (one for the weight and one to specify the file > containing the table above). Does that sound right so far? If anyone > has any pointers for getting started implementing this feature, I'd > appreciate them. > > Thanks, > Suzy > > _______________________________________________ > Moses-support mailing list > [email protected] > http://mailman.mit.edu/mailman/listinfo/moses-support > _______________________________________________ Moses-support mailing list [email protected] http://mailman.mit.edu/mailman/listinfo/moses-support
