Fix link generation, add source field