fixes for tokenizer