HTMLDiff.diff(‘a word is here’, ‘a nother word is there’) # => ‘a<ins class="diffins"> nother</ins> word is <del class="diffmod">here</del><ins class="diffmod">there</ins>’

HTMLDiff.textdiff(‘a word is here’, ‘a nother word is there’) # => a[++ nother++] word is [–here–][there]

Checkout the crappy specs for good examples.