"How consciousness evolved and how consciousness has come to affect evolutionary processes are related issues. This is because biological consciousness–the only form of consciousness of which we are aware–is entailed by a particular, fairly sophisticated form of animal cognition, an open-ended ability to learn by association or, as we call it, 'unlimited associative learning' (UAL). Animals with UAL can assign value to novel, composite stimuli and action-sequences, remember them, and use what has been learned for subsequent (future), second-order, learning. In our work we argue that UAL is the evolutionary marker of minimal consciousness (of subjective experiencing) because if we reverse-engineer from this learning ability to the underlying system enabling it, this enabling system has all the properties and capacities that characterize consciousness. These include..."
See the link for more.