An API for biologically inspired algorithms in JavaScript