Jarvis listens for your voice through the microphone, converts speech to text using Google’s Speech Recognition API, matches the transcribed text against known command phrases, and executes the corresponding action. Every command follows the same loop: speak a phrase → Jarvis recognizes it → the action runs → Jarvis prompts “Next Command Sir!” so you can issue another.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/Harsha200105/DesktopAssistant/llms.txt
Use this file to discover all available pages before exploring further.
How the assistant listens
When you speak, Jarvis uses thespeech_recognition library to capture audio and send it to Google’s Speech API. The recognizer is tuned with a short pause threshold to feel responsive:
| Parameter | Value | Notes |
|---|---|---|
pause_threshold | 0.5 seconds | Silence needed before Jarvis stops recording |
energy_threshold | 300 (default) | Microphone sensitivity — raise if Jarvis misses commands; lower if it never triggers |
language | en-in | English (India) locale passed to r.recognize_google() |
energy_threshold value is read from config.ini so you can tune it without editing source code.
If Jarvis frequently says “Sorry, could you please try again?” without you even speaking, your microphone’s background noise level exceeds
energy_threshold. Increase the value in config.ini under [DEFAULT] → energy_threshold.Command categories
Web Navigation
Open websites by name and search the web with configurable search engines including Google, Bing, DuckDuckGo, and YouTube.
Information
Get Wikipedia summaries, ask for the current date or time, and receive friendly conversational responses.
Music
Play, pause, resume, and stop local MP3 music using pygame mixer — all by voice.
Dictate and send emails via SMTP by speaking the recipient address and message body.
System Commands
Greet Jarvis, change voice gender, speech rate, volume, and exit the assistant gracefully.
Quick reference
The table below lists every recognized phrase and what it does. Phrases are matched case-insensitively on the lowercased transcript.| Phrase | Action |
|---|---|
hello | Greet the user — Jarvis replies “Hello Sir” |
what's up | Random friendly response from a preset list |
open [website] | Open a built-in website (Google, YouTube, Wikipedia, Amazon, GitHub) or offer to search for an unknown site |
search for [query] | Run a web search using the configured search engine |
wikipedia [topic] | Fetch and speak a 2-sentence Wikipedia summary of the topic |
time | Speak the current time in 12-hour format — Ubuntu (Jarvis2.py) only |
date | Speak the current date — Ubuntu (Jarvis2.py) only |
mail | Start the email flow — Jarvis asks for recipient and message body |
play music | Load and play a random MP3 from your configured music folder |
pause music | Pause the currently playing track |
unpause | Resume a paused track |
stop music | Stop music playback entirely |
change voice to male | Switch TTS voice to the first system voice (male) |
change voice to female | Switch TTS voice to the second system voice (female) |
change rate to [number] | Set the TTS speech rate (e.g. “change rate to 150”) |
change volume to [number] | Set the TTS volume 0–100 (e.g. “change volume to 80”) |
nothing / abort / stop | Say goodbye and exit the program |
bye | Say goodbye and exit the program |
The “Next Command Sir” prompt
After every command executes, Jarvis always speaks “Next Command! Sir!” — this is the signal that the assistant is ready and listening again. The prompt is unconditional: it fires at the end ofexecute_the_command_said_by_user() regardless of which branch ran.