The voice dictation feature lets you speak your document content aloud and have it typed for you in real time. It uses the browser’s built-in Web Speech API — no third-party service or plugin is needed. Dictation is available on desktop and tablet only; on phones the floating action button (FAB) is hidden in favour of the device keyboard’s own microphone key.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/arverma/Bihar-Police-Notebook/llms.txt
Use this file to discover all available pages before exploring further.
Starting Dictation
- Click the FAB
- Keyboard shortcut
A microphone floating action button (FAB) appears in the lower corner of the screen on desktop and tablet. Click it to start a dictation session. The FAB is draggable — move it out of the way if it overlaps your text.
On screens 768 px wide or narrower, the FAB is hidden and
syncFabVisibility() stops the engine automatically if the window is resized into the mobile breakpoint. Use your phone keyboard’s microphone button instead.Session States
The dictation engine moves through these states:| State | What it means |
|---|---|
idle | No session active. Microphone is not in use. |
listening | Recognition is running. Spoken words are transcribed in real time. |
paused | Session is open but recognition is temporarily stopped. Click the FAB or press the shortcut to resume. |
needs-consent | No on-device language pack was found. The app is waiting for your permission to use online (cloud) recognition. |
error | A microphone or recognition error occurred (e.g. permission denied, service unavailable). |
On-Device vs. Cloud Recognition
Check for an on-device pack
When you start dictation the engine calls
probePackAvailability('hi-IN') using the SpeechRecognition.available() API. If Chrome has the Hindi (hi-IN) language pack installed locally, recognition runs entirely on your device — no audio is sent over the network.Ask for consent if the pack is missing
If no local pack is found, the app enters the
needs-consent state and shows a consent sheet explaining that audio will be sent to Google’s cloud recognition service. No audio is stored by the app.Proceed with cloud after consent
If you allow cloud recognition,
setCloudConsent('hi-IN', true) stores your preference and continueWithCloud() restarts the session with processLocally: false. Your preference is remembered for future sessions.Spoken Punctuation
You can insert punctuation and line breaks by speaking their names aloud. TheapplyVoiceEdits() function replaces recognised phrases with the correct glyphs after each final result:
| Spoken phrase | Inserted text |
|---|---|
| ”पूर्ण विराम” | । |
| “अल्पविराम” | , |
| “प्रश्न चिह्न” | ? |
| ”नया पैराग्राफ” or “new paragraph” | (blank line) |
| “नई लाइन” or “new line” | (line break) |
| “full stop” | । |
| “comma” | , |
| “question mark” | ? |
Audio Level Metering
While the session is in thelistening state, an AnalyserNode reads the RMS amplitude of the microphone stream 60 times per second and emits a normalised level value (0–1) via the onLevel callback. The FAB uses this value to display a real-time audio level indicator so you can see when your voice is being picked up.
Idle Timeout
A session that receives no speech automatically stops after 2 minutes of silence. This prevents the microphone from remaining open indefinitely. You can resume at any time by clicking the FAB or pressing Ctrl + Shift + D again.Ending a Session
- Press Esc to end an active dictation session immediately.
- Click the FAB while
listeningorpausedto toggle pause / resume. - The session also ends automatically on idle timeout or if a fatal error occurs.
Supported Languages
| Language code | Description |
|---|---|
hi-IN | Hindi (default) |
en-IN | English (India) |