amaurycrickx / recognito

Java Speaker Recognition Framework
Apache License 2.0
191 stars 102 forks source link

automatically stop recording when the user stops talking #15

Open ugochirico opened 7 years ago

ugochirico commented 7 years ago

Hi, I'm looking for "automatic handling of microphone input : automatically stop when the user stops talking or after a predefined delay".

It seems that your library has almost anything needed to do that and I see that you already added that in your TODO list. I may also contribute to your project. Can you suggest me how to proceeds?

activey commented 7 years ago

Create pull request?

ugochirico commented 7 years ago

Hi activey, I mean do you have some suggestions on how to add this new feature to your library. Some directions. After I implemented such features I'll do a pull request of course

activey commented 7 years ago

First of all it's not mine. Second - yes I do.

amaurycrickx commented 7 years ago

Hi Ugo

I'm the author of this small lib :-) First, little disclaimer: I'm not actively working on this lib, so please consider that your efforts might not reach a wide audience

Now if you want to crack this nut, be my guest! It shouldn't take you weeks that achieve this and I'll help where I can :-)

Since the lib is quite susceptible to noisy environments anyways, I wouldn't try to make this "mic input" feature resistant to very noisy environments where the surrounding noise is almost as loud as the voice itself.

Based on that, I'd only look at averaged audio levels (not trying to detect if that's actual speech or not)

Here is where to start for handling mic input: https://docs.oracle.com/javase/tutorial/sound/sampled-overview.html

activey commented 7 years ago

@ugochirico take a look here: https://github.com/activey/VoiceRecognition I've done something similar with a little help from google.

ugochirico commented 7 years ago

@activey excellent. Let me try your code

activey commented 7 years ago

@amaurycrickx sry we're chatting here hehehe ;D @ugochirico please keep it mind this code is quite old already and uses some dirty hacks to tell google you're a web browser ;) So, yeah, use it carefuly ;>

ugochirico commented 7 years ago

@amaurycrickx I know... I already did something similar... I know the issues ;) Many thanks!