Fixes and implementation for batch runner (in progress)