Removing dependency on Template Haskell code: http://izbicki.me/blog/markov-networks-monoids-and-futurama#comment-2579