update the example to use category