David Williams (1765–1810), Minister and Man of Letters