Archive

Archive for the ‘Keyboard Release’ Category

Introducing the First Fully-Optimized Shifted Layout

February 19, 2012 21 comments

The typing program now fully supports shifted keys. The updated version is on GitHub.

Optimized shifted layout for Kinesis:

Hands: 51% 48%
Fingers: 9% 9% 18% 14% 14% 14% 11% 8%

 [  ]  +  {  #   @  |  $  }  %  Q
 Y  P  O  U  :   B  D  L  C  K  J
 I  N  E  A  ;   M  H  T  S  R  V
 &  ?  *  =  <   >  F  W  G  X  
 ~  `               Z  ^  

 1  2  3  4  5   6  7  8  9  0  q
 y  p  o  u  -   b  d  l  c  k  j
 i  n  e  a  ,   m  h  t  s  r  v
 (  "  '  .  _   )  f  w  g  x  
 \  !               z  /

Fitness: 18449175
Distance: 89177
Finger work: 326100
Inward rolls: 10.08%
Outward rolls: 2.53%
Same hand: 34.47%
Same finger: 1.69%
Row change: 12.64%
Home jump: 0.89%
Ring jump: 2.89%
To center: 2.47%
To outside: 0.19%

Shifted layout for a standard (asymmetric) keyboard:

Hands: 50% 49%
Fingers: 8% 9% 19% 14% 17% 11% 12% 8%

^  @  (  )  +  &   ~  [  ]  %  #  Q  Z   
   <  P  O  U  *   V  F  L  G  >  $  J  `
   I  N  E  A  =   D  S  H  T  R  X     
   {  }  ?  Y  |   B  C  M  W  K       

\  1  2  3  4  5   6  7  8  9  0  q  z   
   .  p  o  u  _   v  f  l  g  "  ;  j  /
   i  n  e  a  ,   d  s  h  t  r  x     
   !  -  '  y  :   b  c  m  w  k

Fitness: 18019920
Distance: 27161
Finger work: 87915
Inward rolls: 8.63%
Outward rolls: 2.77%
Same hand: 34.45%
Same finger: 1.93%
Row change: 13.34%
Home jump: 1.35%
Ring jump: 2.02%
To center: 2.63%
To outside: 0.43%

Compare this to Colemak for a standard keyboard:

Hands: 46% 53%
Fingers: 8% 7% 11% 18% 18% 15% 10% 9%

~  !  @  #  $  %   ^  &  *  (  )  _  +   
   Q  W  F  P  G   J  L  U  Y  :  {  }  |
   A  R  S  T  D   H  N  E  I  O  "     
   Z  X  C  V  B   K  M  <  >  ?       

`  1  2  3  4  5   6  7  8  9  0  -  =   
   q  w  f  p  g   j  l  u  y  ;  [  ]  \
   a  r  s  t  d   h  n  e  i  o  '     
   z  x  c  v  b   k  m  ,  .  /

Fitness: 22955565
Distance: 25239
Finger work: 347475
Inward rolls: 4.51%
Outward rolls: 2.50%
Same hand: 42.63%
Same finger: 1.89%
Row change: 18.63%
Home jump: 1.33%
Ring jump: 3.86%
To center: 7.71%
To outside: 1.18%

Advertisements

Fully Optimized Standard Keyboard

January 16, 2011 34 comments

I recently proposed a fully optimized layout built for the Kinesis physical keyboard. By popular request, I have now created a fully optimized layout for the standard keyboard.


= 1 2 3 4 5 6 7 8 9 0 q z
y p o u - k d l c w x / j
i n e a , m h t s r "
( ) ; . _ v f g b '

Fitness: 184428299
Distance: 364416
Inward rolls: 10.16%
Outward rolls: 2.36%
Same hand: 34.93%
Same finger: 1.60%
Row change: 13.17%
Home jump: 0.27%
To center: 2.38%
To outside: 0.52%

It looks strikingly similar to the latest version of the Kinesis layout:


1 2 3 4 5 6 7 8 9 0 q
y p o u - v d l c w x
i n e a , m h t s r "
( ) ; . _ k f g b '
/ =             z j

Fitness: 186751864
Distance: 959128
Inward rolls: 10.16%
Outward rolls: 2.36%
Same hand: 34.94%
Same finger: 1.60%
Row change: 13.40%
Home jump: 0.30%
To center: 2.38%
To outside: 0.39%

Most of what I have to say about fully optimized keyboard layouts has been said. I do find it interesting that the standard and Kinesis layouts look so similar; it looks like the rare keys around the edges have barely any effect at all.

Starting to Fully Optimize the Keyboard

January 4, 2011 24 comments

(Edit: I found a bug in the way rolls were being calculated. MTGAP 0.1 (shown below) is no longer the best layout.)

It’s been a while since I’ve done anything with the New Keyboard Layout Project, but I read a comment on one of my posts and I got to thinking about punctuation. Every keyboard I’ve designed has just been based on the main 30 keys and used .,’; as the four punctuation marks, because those are the ones that Dvorak used. But why use those four punctuation marks? Why not use a different set?

In fact, why not simply try to optimize the entire keyboard instead of just the main 30 keys?

Previously, the answer to that question was that it would be too slow. But now, thanks to a much-improved algorithm, I no longer have that excuse. That means I can evaluate the entire keyboard.

The Physical Keyboard

Changing the size of the keyboard requires rewriting large portions of the program. For this reason I didn’t want to rewrite it for a standard physical keyboard — why design such a highly optimized layout for a suboptimal physical keyboard? Instead, I rewrote the program to optimize on the Kinesis Advantage Pro keyboard. (You can see a good picture of the full keyboard here.) I ignored the thumb pads, tab, shift and caps lock for aesthetic reasons, and the arrow keys and function keys because it is nearly impossible to determine the frequency of those keys. This leaves four rows and 47 keys. The QWERTY keyboard looks like this:

1 2 3 4 5 6 7 8 9 0 -
Q W E R T Y U I O P \
A S D F G H J K L ; '
Z X C V B N M , . /
` =             [ ]

Shifted Keys

My program doesn’t deal with shifted keys, and modifying it to do so would be a much greater task than what I am currently doing. Rather than try to get the program to deal with shifted keys, I decided to simply choose the most common punctuation and put those on the unshifted slots.

There are 26 letters and 10 numbers. Out of 47 spots this leaves 11 spots for punctuation. The 11 most common punctuation marks are:

, . ) ( _ \ " ; - ' = /

So I pulled off the standard punctuation and stuck those on.

Results

After some (not insignificant) modifications, the program was able to optimize a full-sized keyboard. You can download my earliest functional version of the program here. It hasn’t been extensively tested and it’s messy, but it’s functional.

The first layout it came up with was this one:

Hands: 53% 46%
Fingers: 10% 10% 10% 21% 13% 14% 10% 8%


x 3 6 5 q / " 9 2 8 0
u l c o ; v m d p ) j
a r s e , f h t n i -
( ' w . = k y g b _
4 1             z 7

Fitness: 20014435648
Distance: 97925496
Inward rolls: 16.44%
Outward rolls: 5.40%
Same hand: 48.05%
Same finger: 2.02%
Row change: 21.05%
Home jump: 0.80%
To center: 3.03%
To outside: 0.40%

(I’ve added a new cost: “to outside.” It’s similar to “to center”: it penalizes a layout every time the user has to reach to the outside of the keyboard with the pinky before or after typing a letter on that same hand.)

Highly optimized and aesthetically horrible. The number keys, instead of being in a nice straight line, are all over the place. The parentheses aren’t even next to each other. This isn’t much of an issue when you’re dealing with the main 30 characters because there are no real aesthetics to speak of, but once you expand it becomes a serious problem.

The solution is to require that the program put certain keys in certain places: the number keys on the top row and the parentheses next to each other. There are two fundamental ways to do this: force it to, or give a penalty for not doing so. I found that the best way to keep the number keys in place was simply to tell the computer that it wasn’t allowed to move them. That doesn’t quite work with parentheses though, because they should still be able to move around; they just should stay next to each other. If one moves, the other moves. Forcing them to be next to each other but still be able to move around as a chunk would require adding an extra layer of complexity to the program. The simpler solution is to heavily penalize a keyboard layout every time the parentheses aren’t next to each other.

After adding these restrictions and tweaking the costs a bit, I came up with this layout:

MTGAP Full 0.1

Hands: 52% 47%
Fingers: 9% 10% 18% 13% 13% 14% 10% 9%


1 2 3 4 5 6 7 8 9 0 q
y c o u ( ) l d p w x
i s e a , m h t n r k
_ v " . ; ' f g b -
/ =             z j

Fitness:       193491944
Distance:      956628
Inward rolls:  8.42%
Outward rolls: 2.20%
Same hand: 36.00%
Same finger: 1.48%
Row change: 17.14%
Home jump: 0.26%
To center: 2.29%
To outside: 0.50%

Some of its numbers are quite impressive. For comparison, here’s Colemak (with punctuation modified a bit to fit on the keyboard):

Hands: 46% 53%
Fingers: 8% 8% 11% 18% 18% 15% 10% 9%


1 2 3 4 5 6 7 8 9 0 -
q w f p g j l u y ; =
a r s t d h n e i o '
z x c v b k m , . /
_ "             ( )

Fitness:       230028740
Distance:      1006256
Inward rolls:  4.53%
Outward rolls: 2.62%
Same hand: 42.86%
Same finger: 2.01%
Row change: 18.93%
Home jump: 0.74%
To center: 7.54%
To outside: 0.48%

My layout beats Colemak on every single metric except “to outside” (and possibly outward rolls, depending on whether you like those or not). Notice that, even though my layout puts ‘o’ (the fourth most common letter) off the home row, it still has lower travel distance than Colemak.

(In case you’re new here, the reason I compare my layout to Colemak is because Colemak is my favorite keyboard layout that I didn’t design.)

Also, if you’re interested, here’s Dvorak:

Hands: 44% 55%
Fingers: 8% 8% 12% 14% 16% 13% 13% 11%


7 5 3 1 9 0 2 4 6 8 =
' , . p y f g c r l /
a o e u i d h t n s -
; q j k x b m w v z
_ "             ( )

Fitness:       247807385
Distance:      1020108
Inward rolls:  4.14%
Outward rolls: 1.25%
Same hand: 31.14%
Same finger: 3.16%
Row change: 14.36%
Home jump: 0.50%
To center: 7.39%
To outside: 0.39%

Improved Keyboard Layout Program

I made some modifications to my keyboard layout program, and it now runs about twice as fast. On my laptop, it can score 12,000 layouts per second — this is six times as fast as Michael Capewell’s program.

You can download it here.

New Keyboard Layout Project: Program Release

September 12, 2009 6 comments

You can find my source code at http://mtgap.bilfo.com/Typing.zip. The new and faster algorithm was written by Chris Johnson, a.k.a. Phynnboi.

The algorithm repeatedly returns this result.

y p u c b  x l d , .
i n e s f  h r t a o
j v ' w z  k m g ; q

Fitness:       2263451098
Distance:      9003112
Inward rolls:  7.04%
Outward rolls: 4.48%
Same hand:     22.80%
Same finger:   0.68%
Row change:    9.01%
Home jump:     0.34%
To center:     4.17%

This is a very good layout. Strangely enough, though, if you run the algorithm for longer it comes up with this layout, even though it has a lower score:

y c o u ;  k m d p w
i s e a .  l h t n r
j z ' , x  v f g b q

Fitness:       2263597180
Distance:      9599916
Inward rolls:  7.20%
Outward rolls: 2.20%
Same hand:     16.85%
Same finger:   0.64%
Row change:    7.64%
Home jump:     0.28%
To center:     1.74%

Which is better and why? How can improvements be made?

New Keyboard Layout Project: Keyboard Version 3.11

September 7, 2009 18 comments

This layout performs significantly better than any other I’ve found. But how good is it really?

Hands: 50% 49%
Fingers: 7% 15% 11% 15% 18% 13% 9% 9%

. l u c b  q h g y ,
o r e s d  p n t i a
' x ; w z  v f k j w

Fitness:       2084759
Distance:      7386.58
Inward rolls:  6.91%
Outward rolls: 6.88%
Same hand:     26.28%
Same finger:   0.58%
Row change:    12.34%
Home jump:     0.14%
To center:     3.50%

Distance and same finger are phenomenally low. Same hand and row changing could be better. But by all measures here, it’s very good. But is it really?

One thing that jumps out at me here is the “ing” trigraph. It is just weird. I practiced with it, though, and it’s actually not too hard. There are some strange words that loop back on themselves like “thingy” or “resurrect”, but I don’t find that to be too hard either, just strange. In fact, MTGAP 2.0 (which I am using right now) has a pretty major loop in the word “themselves”, and that’s not too hard to type.

EDIT: This layout was getting a huge performance boost. Due to a small bug, there were two ‘w’s, only one of which was getting scored. So the layout was essentially 1/30th better than any other layout without the bug. In truth, this is the best layout given the criteria:

y p u c b  x l d , .
i n e s f  h r t a o
j v ' w z  k m g ; q

New Keyboard Layout Project: The Hand Roll Keyboard

September 5, 2009 Leave a comment

I greatly increased the cost for inward rolls, and got this beautiful layout:

p m d . ,  x c u l k
i n t o h  f s e r a
j z g b q  ; w y v '

Fitness:       2108634
Distance:      7859.45
Inward rolls:  10.38%
Outward rolls: 4.83%
Same hand:     25.62%
Same finger:   1.21%
Row change:    10.93%
Home jump:     0.46%
To center:     3.45%

It sacrifices on pretty much everything but inward rolls, but still. Those rolls are awesome!