How to detect when a person is talking?

Sound-cancelling mic near to the speaker?