{"id":17254537,"url":"https://github.com/shervinemami/practice_speechrec_mappings","last_synced_at":"2025-04-14T05:40:41.834Z","repository":{"id":58051154,"uuid":"163739039","full_name":"shervinemami/practice_speechrec_mappings","owner":"shervinemami","description":"A game to help design a better character mapping and to learn the mapping for speech recognition voice coding","archived":false,"fork":false,"pushed_at":"2023-02-11T22:59:41.000Z","size":60,"stargazers_count":11,"open_issues_count":3,"forks_count":4,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-27T19:23:14.992Z","etag":null,"topics":["aenea","dragonfly","speech-recognition","voice-coding"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/shervinemami.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-01-01T13:33:35.000Z","updated_at":"2025-01-03T15:36:16.000Z","dependencies_parsed_at":"2023-02-16T07:31:08.050Z","dependency_job_id":null,"html_url":"https://github.com/shervinemami/practice_speechrec_mappings","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shervinemami%2Fpractice_speechrec_mappings","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shervinemami%2Fpractice_speechrec_mappings/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shervinemami%2Fpractice_speechrec_mappings/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shervinemami%2Fpractice_speechrec_mappings/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shervinemami","download_url":"https://codeload.github.com/shervinemami/practice_speechrec_mappings/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248830416,"owners_count":21168271,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aenea","dragonfly","speech-recognition","voice-coding"],"created_at":"2024-10-15T07:09:08.463Z","updated_at":"2025-04-14T05:40:41.811Z","avatar_url":"https://github.com/shervinemami.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"=================\nPractice Speechrec Mappings\n=================\nA very mininal game that helps practice key mappings for Talon or Dragonfly speech recognition grammars.\nCan be very useful for quickly finding clashes between combinations of letters and symbols and numbers.\nHas only been tested on Linux. It might work on Windows or OS X but it hasn't been tested.\nBy Shervin Emami 2019-2023, shervin.emami@gmail.com.\n\nBackground:\n----------------\nWhen using speech recognition for voice coding / programming / computer control, it's quite important to have high accuracy of each\nletter of the alphabet, and the various symbols that will be used. Rather than speak each character or variable name directly, it's \nfar more accurate to use a mapping of words to characters, such as by saying the word \"alpha\" instead of just the letter \"a\". I created \nthis game / tool to help me find a good mapping of alphabet words, and to train myself to use the mapping. I have tested Dragonfly mode with\nboth Dragonfly on Kaldi-Active-Grammar, and Dragonfly / aenea on Nuance Dragon, but only with my custom phonetic mapping (files are included), \nbased on DWK's simple grammar at \"https://github.com/dwks/aenea-grammar-simple/blob/master/keyboard.py\"\n\nThis program prints random characters with their word mapping, and checks the accuracy \u0026 speed of what I type. To start with, I run\n\"practice_mappings 3\" and then \"practice_mappings 5\" for a while, and I simply say the words shown on the left, until I'm quite happy with the\naccuracy. ie: without trying to memorize the mappings I just read out the mappings, and I try to talk fairly fast but not ultra fast, until\nI'm rarely making a mistake. Whenever I make a mistake, I look at it to see if I need to change my mapping (both in Dragonfly and in this\ngame).\nEventually when I'm quite happy with the accuracy, meaning that my character mapping is ambiguous enough that I can use it quite\nreliably, then I run the game again but I concentrate on the individual character shown on the right, by trying to memorize the word mapping.\nAfter some time I start getting better at memorizing the mapping, so I add some capital letters by running \"practice_mappings 5 30\",\nand I keep practising to get faster \u0026 faster. I occasionally also play the game sometimes using an actual keyboard, to compare my\nspeed when using speech vs keyboard.\n\nNote that there's also a separate \"measure_typing_rate.py\" program that is intended for rare use-cases such as measuring the keypress latency.\n\n\nUsage:\n----------------\n\n.. code::\n\n   usage: practice_mappings.py [options] [combo_length]\n\n    Practice keyboard mappings, such as to practice voice coding. By Shervin Emami (http://shervinemami.com), 2023\n\n    positional arguments:\n      combo_length          How many characters you will try to say at the same time. Default is 3.\n\n    options:\n      -h, --help            show this help message and exit\n      -d, --dragonfly       Use Dragonfly mode (\"lettermap.py\" + \"punctuationmap.py\"). Default is Talon mode.\n      -a, --alphabetical    Sort the characters alphabetically. Default is random (ie: unsorted).\n      -s, --symbols         Include some symbols in the mix. Default is just alphabet letters, not symbols.\n      -n, --no_numbers      Skip numerals, only use letters (and possibly symbols). Default is to include numbers.\n      -c, --no_crucial      Skip crucial symbols (commas and spaces). Default is to include crucial symbols.\n      -p CAPITALS_PERCENTAGE, --capitals_percentage CAPITALS_PERCENTAGE\n                            Percentage of characters that will be a capital letter. Default is 0.\n      -r RANDOM_SEED, --random_seed RANDOM_SEED\n                            Allows following a determinstic sequence of random values. Default is the system timer.\n\neg:\n\n.. code:: shell\n\n    python practice_mappings.py\n    python practice_mappings.py 5 --symbols --capitals_percentage 20\n    python practice_mappings.py 5 --dragonfly --symbols --capitals_percentage 20 --random_seed 12345\n\n\nSample output:\n----------------\n\nTalon mode:\n\n.. code:: shell\n\n    $ python ./practice_mappings.py 3 --symbols --capitals_percentage 10\n    By default, it will run as Talon knausj mode. Or to use Dragonfly mode, add '-dragonfly'.\n    See 'https://github.com/shervinemami/practice_speechrec_mappings' for more details\n\n    Press the 3 shown keys as fast as you can, using either a speech recognition engine or a physical keyboard!\n    zlk                                        zap  look crunch  \n    zlk\n    Correct.                                  Tally: 1 correct = 0.0% WER. Speed: 0.58 s/key\n\n    1b                                         one  bat space  \n    1b \n    Correct.                                  Tally: 2 correct = 0.0% WER. Speed: 0.68 s/key\n\n    y(4                                        yank  L paren  four  \n    y[4\n    ### WRONG! ######  y(4 y[4 ############ Tally: 2 correct, 1 wrong. ###################################\n\n    vis                                        vest  sit  salty    \n    ...\n\nDragonfly mode:\n\n.. code:: shell\n\n    $ python ./practice_mappings.py 3 --dragonfly --symbols -p 10\n    zlk                                        zircon  lazy  krife  \n    zlk\n    Correct.                                  Tally: 1 correct = 0.0% WER. Speed: 0.58 s/key\n\n    1b                                         one  bony  space  \n    1b \n    Correct.                                  Tally: 2 correct = 0.0% WER. Speed: 0.68 s/key\n\n    ...\n    \n    \nTo use your own Talon grammar, make sure you installed knausj into \"~/.talon/user/knausj_talon\".\nIn Talon mode it will use these 2 files on your computer:\n\n.. code:: shell\n\n    ~/.talon/user/knausj_talon/settings/alphabet.csv\n    ~/.talon/user/knausj_talon/core/keys/keys.py\n\nIf you've installed them in different locations on your computer, you'll need to modify these 2 file locations in 'practice_mappings.py'.\n\nOr for Dragonfly mode, to use your own Dragonfly grammar and not myne, you'll need to put your alphabet character mapping into file \"letterMap.py\", such as:\n\n.. code:: shell\n\n    letterMap = { \n        \"acid\": \"a\",\n        \"bony\": \"b\",\n        \"char\": \"c\",\n        ...\n    }\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshervinemami%2Fpractice_speechrec_mappings","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshervinemami%2Fpractice_speechrec_mappings","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshervinemami%2Fpractice_speechrec_mappings/lists"}