AI XML reader/writer cleanup