Autocomplete cleanup

Fixes #192.