Python: How to use libraries like pyaudio or sounddevice for automatic recording? I wanna make a project, It needs to fulfill the following recording requirements: