The wpm command is used for setting the words per minute (morse speed) of the test.
The script below shows two tests - one at 12 words per minute, one at 18 words per minute.
require "cw"
cw do
wpm 12
word_count 4
end
cw do
wpm 18
word_count 4
end