improvements for ruby search