add patch index