Fixed retention, config; added argument parsing