You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Constrained decoding works by ensuring that LM state tuples match against the specified target side. This fails when using KenLM, since it maintains its own private state and doesn't expose the n-gram boundary words to the decoder (instead using the generic DP state mechanism). This could be fixed by always creating a dummy LM feature whenever constrained decoding is requested, which will do the state maintenance that is needed. This could maybe be done at the sentence level or could be done via a decoder switch (meaning that constrained decoding would only work when you've explicitly requested it, which might be a good thing).
Another approach that might be easier would be to check edges against the input and block there, instead of checking states. However the state constraint itself already has holes (there are cases where it can permit a hypothesis that doesn't exactly match the output), and I think this would be worse.
The text was updated successfully, but these errors were encountered:
Constrained decoding works by ensuring that LM state tuples match against the specified target side. This fails when using KenLM, since it maintains its own private state and doesn't expose the n-gram boundary words to the decoder (instead using the generic DP state mechanism). This could be fixed by always creating a dummy LM feature whenever constrained decoding is requested, which will do the state maintenance that is needed. This could maybe be done at the sentence level or could be done via a decoder switch (meaning that constrained decoding would only work when you've explicitly requested it, which might be a good thing).
Another approach that might be easier would be to check edges against the input and block there, instead of checking states. However the state constraint itself already has holes (there are cases where it can permit a hypothesis that doesn't exactly match the output), and I think this would be worse.
The text was updated successfully, but these errors were encountered: