improvements and fine-tuning