Text this: Formal principles of language acquisition