more stable category processing