Refine implementation