small bug fixes, build function to kimitems