how do you deal with ambiguous terms? just statistically, or based on sentence position (dependency parsing)? for example what is lock
here:
lock the chest
open the lock
I wrote up some alternatives here, trying to get to grips with the options here