voice assistant in python has the following problem - python

I am making a python voice assistant as I pass a command like search Wikipedia and read it, if I want it to stop it wont stop until it completes all the matter present in it can anyone help me with this. I don't know what to do

Related

Is a Spotify Connect Speaker able to be controlled by Spotipy?

Okay, so this is kind of a stupid question but I tried to understand it myself and I just got even more confused. I am using the Spotipy library to play music (controlled by my raspberry pi) on my computer using the specific device id. Now I want to implement the same thing but be able to play directly on my Raspberry Pi. I have found something called Raspotify, which allows me to use my rpi as a spotify connect speaker. I wasn't able to find it in the devices list though, and I'm now wondering if it is even possible to control a connect speaker?
If not, are there any other ways to play music using the spotipy api on my rpi? Help is greatly appreciated, I tried figuring it out by myself but I just got even more confused.
I now found the answer myself. You can control Spotify Connect speakers using Spotipy, but for me the Spotify API had some trouble finding the device. It then just started working even though I didn't change anything. So for anyone else wondering, a spotify connect speaker acts like a normal device with device id and everything :)

Check If A Command By A Specific User Is In Progress Discord.py Rewrite

So, I was making a discord bot command, basically a game of rock paper scissors (2 users).
I was stuck at a thing for a lot of time. The thing is .. if a user (first person) is already running a game with a mentioned user (second user) and the game is in progress, then a third person uses the command mentioning either the first or the second person, the commands shouldn't work. But I am unable to figure this thing out. I guess code chunk isn't really necessary in this situation, but if it is needed please just tell me. Also, I wasn't able to figure out how to use two wait_for() together. Any help is appreciated!
Also, Idk if this will affect the question but Inputs Are Taken In User DMs

Is there a way to imitate sound input with python?

I wanted to make a program that would pass some sound data to the system's microphone, imitating person's speech. Originally I wanted it to "talk" in a discord voice chat to other people, but I couldn't find any way to do so.
I tried libraries like SoundCard and PyAudio, but they seem to only have functions to either get the mic input from the user, or to output sound via speakers. However, I want it to simulate microphone input.
So, is there any way to do this with python (or any other language)?
Thanks in advance.

Automatically controlling an app on the PC using openCV Python

I am working on a project to control the PC exclusively by voice control and gestures(via webcam). So, with the voice control I open the app(for example, YouTube). Now, without typing anything on the search bar, I want to do it through voice typing (without even touching the keyboard), like if I say "search water videos" the cursor will automatically search the thing for me, and give me the result.
Basically, I want to find a text box on a screen of an app using image processing.
There shall be some predefined keywords like, search(for searching), delete(for deleting anything that is mistyped) Go Back(to go back to the previous window), Exit(for exiting the app).
Can it be done with the help of openCV Python?
Many thanks in advance!

Python to interact with Youtube

I have started learning how to code in python and so far I've been doing normal exercises and I have an idea using which I want to explore more on python. It goes something like this.
User is listening to music on his computer using some media player.
If he/she plays any video on YouTube, then the music on his computer must be paused. And when the video is completed, the music should resume.
I'm not asking for code, obviously. I just want to know what concepts should I look into for accomplishing this task.
And I am sure there will be someone who have already made this. I am just trying to make this so that I can learn some different concepts in Python.
Edit:: After looking at the comments, I am making some changes to my question and tags. I want to do this application with this particular setup - Chrome browser - Windows Media Player - Windows 8
Is this a good enough task for a beginner to use as an excuse to learn Python?
Thanks in advance!!

Categories

Resources