Documentation
Overview / Initial Usage
You are using Speech to Command either because you have some temporary or permanent hand disability (likely RSI), or wish to improve your
typing efficiency by building voice-activated typing macros to replace tedious and repetitive phrases. This program also performs perfectly as
a normal dictation software, and is the only free one, so perhaps you are using this program for general dictation as well.
If you are just using this for general dictation, perhaps only the Dictation Modes section is relevant.
Otherwise, the following documentation is primarily useful for dictation coding.
The first hurdle you will encounter with dictation programming is navigating the document without the mouse or arrow-keys. To become skilled at navigating the document by voice, you need to use an editor or environment that supports vim or another key-based navigation. Most editors support vim; for example: Sublime supports it (it has a mode called "Vintage Mode" that supports vim navigation), Eclipse has a plugin to support vim nav., and etc. I recommend you learn to navigate a page with vim before beginning, as this will expedite your transition to voice programming and benefit you greatly in becoming a more effective programmer, whether typing by voice or hands.
The next dilemma you'll encounter is that code is not written in English, but rather an unnatural mix of syntax and punctuations that is natural to the programmer, but unsuitable with normal dictation softwares. This is where Speech to Command is vital. Using dictation vocabularies, you can customize and define macros where unique phrases will trigger defined key sequences. Check out the front page for two quick examples. You'll need to use the vim library to navigate your document, and build more libraries based on the programming language your using, specific to your required syntax. For example, I've included a java library with some basic java commands I use to improve my programming efficiency.
Dictation Modes
The program has five dictation modes that control the formatting of the words typed to give you greater access to your "voice keyboard" as modifier keys:
-
full-caps
: every letter of the word is typed in caps
example: "hello world" -> "HELLO WORLD"
speak the phrase "caps" to toggle this mode (hover over the mode in the GUI for the hint).
usefulness: when you need to type in all caps -
semi-caps
: every first letter of the word is typed in caps
example: "hello world" -> "Hello World"
speak the phrase "semi" to toggle this mode.
usefulness: camel casing -
spacing
: appends a after every word
example: "hello world" -> "hello world"
example with spacing toggled off: "hello world" -> "helloworld"
speak the phrase "spacing" to toggle this mode.
usefulness: normal dictation or when you want to control whether to append spaces after every word -
typing
: types the first letter of every word
example: "hello world" -> "hw"
speak the phrase "typing" to toggle this mode.
this mode is useful when you need to type a single letter -
pure-dictation
: types the word literally, ignoring any dictation library commands
example: "hello world" -> "hw"
speak the phrase "scribe" to toggle this mode.
this mode is useful when you need to type a single letter
Dictation Vocabulary
To view your grammars or create a grammars, scroll down on the dictation bar interface.
The basic format is a unique phrase to trigger the corresponding key sequence.
For example, click the new command button at the bottom right of your grammar, enter the phrase "hello"
and the command "salutations good friend". When the dictation recognizes your phrase "hello", it will instead
type the corresponding "salutations good friend".
note: Stick to phrases that are distinct and won't be recognized as other homophones. ex: "main" could be recognized as "maine" or "two" as "too" or "to". You can also avoid this by padding your words with their similar recognized words, as I include "cup" with the same definition as "up" so they map to the same key sequence.
a good example of a distinct word is "reject" as not many words sound the same.
For including non-Ascii key presses, such as pressing the arrow or enter keys, see the section Non-Ascii Key Simulations.
Using the Dictation Interface (GUI)
The dictation interface has four sections:
the microphone toggle
(upper left) :
click this button to toggle listening on and off (whether you want speech recognition or not)dictation console
(upper right) :
this console gives you feedback on recognized words and whether they are processed as dictation commands or just plain words.dictation modes
(below dictation console) :
these are the graphical representation of the dictation modes. click to toggle any mode.
a mode is on if it is blue and off if red. for further instructions on dictation modes, see the Dictation Modes section.grammars
(scroll down) :
these are your current dictation grammars or vocabularies. hover over for their dropdown options to toggle, edit, or delete any.
a grammar is blue if on and red if toggled off (not going to be checked for commands).
use the new grammar button to create a new grammar.
for any confusion on grammars, view the Dictation Vocabulary section.
Navigating your document
In order to navigate your document with speed by voice, you should learn to use vim first.
Learn the vim library or make your own. At first, your experience will be frustrating as producing the correct voice phrase to match your desired
action will take time. It will probably cost you a frustrating week to be able to navigate the document fluently, but once you get over
the learning curve and combine multiple commands, you'll be zoomin.
Don't want to use vim since you're scared of your terminal? Most editors today, recognizing that vim is the fastest way to zoom around the document,
support vim navigation. For example, Sublime has 'vintage mode', Atom has a vim package, and Eclipse has a vim plugin,
to name a few popular editors you might use.
Non-Ascii Key Simulations
To automate non-Ascii key presses in your grammar vocabularies, such as pressing the arrow keys or enter key, you need to follow the format of the keyPress argument.
- begin: start the non-Ascii request with 'keyPress()'.
- inside the '()': inside the parenthesis, enter the name to the corresponding keycode, found in the table below.
- for example, to press the left arrow key two times: keyPress(KEY_LEFT,KEY_LEFT)
- note: you cannot include spaces in between the keys, as they will be registered as
individual words to type. - if you want to enter a custom keycode instead of the presets, you can subsitute the keycode in place of the keycode preset. this program uses java's robot keycodes to simulate typing, so use those as your best source for keycodes.
Disclaimer: I haven't tested each of these keys because I don't care that much about random keys.
If there are any keys not working, send me a message (find my contact on the about page) and I'll fix it.
Key Name | Key Code |
---|