Added automatic language detection
Fixes #55

Merge branch 'detect'