From 93333a18dd2dff0b5a9b7e0fc85e21d2f67f239b Mon Sep 17 00:00:00 2001 From: Chris Dyer Date: Fri, 20 Jul 2012 00:46:10 -0400 Subject: enable programmatic setting of grammar objects, cleanup of grammar handling --- python/src/_cdec.pyx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'python') diff --git a/python/src/_cdec.pyx b/python/src/_cdec.pyx index 879e8b72..164d6570 100644 --- a/python/src/_cdec.pyx +++ b/python/src/_cdec.pyx @@ -98,7 +98,7 @@ cdef class Decoder: else: raise TypeError('Cannot translate input type %s' % type(sentence)) if grammar: - self.dec.SetSentenceGrammarFromString(string( grammar)) + self.dec.AddSupplementalGrammarFromString(string( grammar)) cdef decoder.BasicObserver observer = decoder.BasicObserver() self.dec.Decode(string(inp), &observer) if observer.hypergraph == NULL: -- cgit v1.2.3