Add more parsing to scala