callum-oakley / gotta-go-fast

A command line utility for practicing typing and measuring your WPM and accuracy.
BSD 3-Clause "New" or "Revised" License
277 stars 16 forks source link

Easily viewable platform info, please? #18

Open DreymaR opened 1 year ago

DreymaR commented 1 year ago

Hiya! I got this typing training tool recommended over at the Colemak layout Discord, and it looks interesting enough that I'd like to link to it from my BigBag Training page:

DreymaR's Big Bag of Keyboard Trix – Training page

However, I couldn't easily see which OSs/platforms it works on from your main page. I saw Mac mentioned, which is nice! And I assume it works for Linux – most distros, or what? Any good/easy solutions for Windows users you can recommend – has anyone tested it for WSL?

For my own BigBag platform implementations, I've tried to provide implementation info easily visible from the main GitHub README. Maybe you could do that too, to aid newcomers like myself? It'd also make it even more tempting to link to your code.

EDIT: Okay, I followed the Stack link and found this: Stack installl info

Stack can be installed on most Unix-like operating systems (including macOS) and Windows.

So, that's nice. But maybe you could still write something like that sentence on your "front porch", for the benefit of us who aren't all that into Haskell and suchlike?

And ideally, I'd love to see something pre-compiled for Windows users, as they/we like that sort of thing. But I can fully understand it if you don't feel you have the energy to provide such a favor. Or at least, a dumbed-down guide to getting Stack up-and-running just enough to use your tool, on WSL and maybe other platforms too? The whole Stack README is, after all, pretty massive for someone who justs want to test something.

callum-oakley commented 1 year ago

Hi! Happy to hear this is still seeing some use. In theory I think it'll compile anywhere you can run Stack (so yes macOS, linux, windows via WSL) but I've only tested it on macOS, and haven't used it for a few years at that so YMMV. I'd rather not duplicate the Stack installation instructions in the README because there's a good chance they'll go out of date if Stack changes.

Personally I use https://callumoakley.net/nonsense/ instead these days, which is just my favourite mode from this program but in a web app. Much easier to install. ;)

DreymaR commented 1 year ago

I linked to your works: https://dreymar.colemak.org/training.html

Fun fact: I recently got a Zipf's Law funbox added to MonkeyType. I didn't know at the time that you had used that trick years ago. Good job with that! Did you too use the Harmonic Numbers approximation formula with the natural logarithm?

callum-oakley commented 1 year ago

Nice! Thanks for the excellent collection of resources. Great stuff.

I hadn't seen MonkeyType had a Zipf's Law mode now, good to know! I think it generates much nicer practice text. I didn't use natural logarithms, though it probably works out about the same... I assign each word a weight based on how many times it appears in the corpus, and then take a weighted selection.

DreymaR commented 1 year ago

Oh, actual corpus-based frequency. Cool. However, that may be why I'm seeing some unexpected words in your app: More personal names than I'd expect, for instance.

Technically, Zipf's Law is the approximation that a sorted word list will have frequency weights approximating the harmonic sequence {1, 1/3, 1/5, ...}, for the sum of which I used the Harmonic number approximation. Right?

So both methods work by Zipf's principle, but my approximation method would be the one actually using the law. Technically. Well, blah blah sorry lol.

callum-oakley commented 1 year ago

Hah yes the frequency list is based on TV and film scripts, so there are some weird words in there.

And yes that makes sense. In the past I'd only referenced Zipf's Law to explain why typing a uniform selection of say the top 10k English words feels so unnatural, and why using a weighted selection feels better. Actually using Zipf's Law as an approximation when you only have a list of words ordered by frequency is a nice idea. I tried the funbox out on Monkeytype and it works well! (I think it should be the default mode 😉)

DreymaR commented 1 year ago

I presented a mathematical solution to Miodec, and he kindly added it. It's become somewhat popular, at least judging from the Colemak Discord. Unfortunately, its technical implementation precludes keeping track of personal bests, which is a downer to many.

Miodec didn't want to add "10k English (Zipf)" as a word list alternative as I wanted, since he was afraid that'd lead to users of other languages wanting their own and then he'd have too much work on his hands. The Zipf Funbox works on all frequency-sorted word lists, and lists that are known to be sorted in this way are marked so MonkeyType knows about it; you get a warning if you try to use the funbox on incompatible lists. So all in all, it's a flexible and useful implementation but unfortunately not an "official" one for tracking speed records.