still need to refactor some stuff -- lots of code duplication here that we can get rid of
wean ourselves off translate.h