We usually spin the gearbox at 4000 RPM, but it gets as high as 10000 on small-load production runs.
Is that the speed that the plastic gear is rotating?
You should be able to create an axial interface between the gear slot and the shaft of a high speed encoder. You want to find something rated for the 10000 rpm. The pulse per revolution is not really relevant, as you will likely use the index pulse, for one pulse per revolution. Be sure you get an encoder with an index pulse.
There are many options, and one possibilty would be the Bourns EMS22D or EMS22Q series. They look to be less than $50 US at Mouser.
If you can get a marker on the gear face you could pick it up with a non contact reflective optical sensor(possibly commercially available integrated with a tachometer) for a lower cost, but it would be more affected by dirt in an industrial environment.