refactored bid_spec