sukeesh / Jarvis

Personal Assistant for Linux and macOS
MIT License
2.93k stars 1.02k forks source link

Voice control #395

Closed hazzus closed 5 years ago

hazzus commented 5 years ago

Hello, is it planned to add voice managment to Jarvis? Can I help with it somehow?

pnhofmann commented 5 years ago

is it planned to add voice managment to Jarvis?

Actually, not really. But we are open for all kind of suggestions and improvements!

Can I help with it somehow?

Of course! Any help is welcome! Do you have any suggestions / ideas how to implement Voice control? Because I'm not quite the expert with speech recognition.

Noticed mozilla DeepSpech a while ago. That's Open Source, runs locally and has python binding. Would guess, if we could use something like that, it could actually work. But as I said: I have no experience with this one so any ideas are welcome!

Voice control would actually be pretty, pretty sweat ;).

hazzus commented 5 years ago

I'm not quite ther expert with speech recognition

Neither do I. But I believe it would be quite an interesting task.

I don't have any exact idea about realisation at the moment, but I will spend some time in order to collect information and try to implement it, maybe as plugin with command 'listen' as first attempt?

Thanks for a link to DeepSpech, it will take a while to look on it. Probably we should put some labels on this issue too)

pnhofmann commented 5 years ago

maybe as plugin with command 'listen' as first attempt?

Excellent idea!

And if there are any questions about Jarvis or problems, just ask - I am happy to help. This is an issue I'm certainly interested, too!

mmkumr commented 5 years ago

is it planned to add voice managment to Jarvis?

Actually, not really. But we are open for all kind of suggestions and improvements!

Can I help with it somehow?

Of course! Any help is welcome! Do you have any suggestions / ideas how to implement Voice control? Because I'm not quite the expert with speech recognition.

Noticed mozilla DeepSpech a while ago. That's Open Source, runs locally and has python binding. Would guess, if we could use something like that, it could actually work. But as I said: I have no experience with this one so any ideas are welcome!

Voice control would actually be pretty, pretty sweat ;).

I am also interested to contribute to your project. Deep speech is a very large repo. I think we should try something else.

pnhofmann commented 5 years ago

Deep speech is a very large repo.

You probably mean the size of prebuild models (since we wouldn't need the complete repo anyway). That would be a download size of 1,8GB - which really is quite heavy.

I think we should try something else.

As I already noted, I'm completely open for everything! Should just work with python - and platform Independence would be pretty sweat. Furthermore personally I prefer offline over online services - but online service would also be fine.

Do you have any library or web service in mind?

@StefanosChaliasos @appi147 What's your opinion on this topic?

mmkumr commented 5 years ago

What do you mean my we wouldn't need the complete repo? Explain it.

mmkumr commented 5 years ago

@StefanosChaliasos @appi147 What's your opinion on this topic?

Nice idea.:) I can help in implement it in Unix types and mac systems but can't implementing this for windows type systems because I don't much about windows.

pnhofmann commented 5 years ago

What do you mean my we wouldn't need the complete repo? Explain it.

Deepspeech offers prebuild binaries for mac, linux and windows (~10 MB); was just a bit confused why you are talking about "a very large repo" when we don't actually have to "clone it" if there are packed and easy installed binaries. But nevertheless; the prebuild models one would have to download, too are big.

mmkumr commented 5 years ago

Sorry for that actually I thought that we have to use the full package.

mmkumr commented 5 years ago

How can I pass arguments to Jarvis object inside the python code.

pnhofmann commented 5 years ago

Sorry, can you show some code because I don't really understand what you are trying to do?

Generally speaking, there is CmdInterpreter.py:JarvisAPI. This is passes as first parameter to any called plugin. Everything plugins need to call should be implemented there.

I know, this isn't documented well - yet. Working on it.

mmkumr commented 5 years ago

Actually I want to pass text converted from voice to Jarvis. So, how can I do that.

mmkumr commented 5 years ago

In the file jarviscli/jarvis.py a variable is used line as parameter. In which file line variable is declared? Checkout the screenshot below. screenshot from 2019-01-31 23-31-58

pnhofmann commented 5 years ago

Actually I want to pass text converted from voice to Jarvis. So, how can I do that.

Oh, there is no 'official' way to do that. At last none I'm aware of. Basically Jarvis "input loop" is just the cmd module documented https://docs.python.org/3/library/cmd.html.

To simulate input, we'll have to be somehow "creative". If I look at the source code this CmdLoop basically does (simplified):

while True:
    line = input(self.prompt)
    line = self.precmd(line)
    stop = self.onecmd(line)
    stop = self.postcmd(stop, line)

So calling the last 3 lines should work - at last for some early testing.

pnhofmann commented 5 years ago

@hazzus @appi147 @StefanosChaliasos Any opinions on #408?

pnhofmann commented 5 years ago

408