improvements and added mapping