Query binary compiling and fixes to remove vocabids.