refining xml