Refactor to improve completion support & snippets

Major rework in progress, placeholder PR to help track.