various improvements and useful gems