template gen (markdown link fix)