Recognition now works correctly

- Some bugs may still be present