I would think the ammonia is from the filter being too small as well as small amount of surface areas in the tank and filter. not enough area to colonize enough bacteria to absorb what the food and fish are putting out. that's why you have ammonia and nitrate at the same time.