Deep Learning in Haskell
Grenade is a recurrent neural network library for the Haskell programming language that enables composable, type-safe specification of deep learning models. Built on Haskell's dependent type system, it allows complex networks—including convolutional, fully connected, and recurrent layers—to be defined concisely at the type level, with compile-time guarantees that layer shapes align correctly. The library is backed by hmatrix, BLAS, and LAPACK for performance and supports training tasks like image classification and generative adversarial networks, as demonstrated by examples achieving around 1.5% error on MNIST.