hacks added for bson and style-specification support