Introduce config, extract model, add algorithm behaviour