Refactor and document node embedding.