Some refactoring and cleanup. Fixes #21 naming convention pipeline.