General bases for string input