Fixed arxiv link issue

This commit is contained in:
Steve White 2025-01-24 11:03:21 -06:00
parent 0748ca884c
commit a326553027
1 changed files with 6 additions and 2 deletions

View File

@ -105,8 +105,12 @@ func writePaperSection(file *os.File, paper PaperDecision, decisionType string)
title := strings.ReplaceAll(paper.Paper.Title, "[", "\\[")
title = strings.ReplaceAll(title, "]", "\\]")
fmt.Fprintf(file, "## [%s](https://arxiv.org/abs/%s)\n", title, paper.Paper.ArxivID)
fmt.Fprintf(file, "**arXiv ID:** %s\n\n", paper.Paper.ArxivID)
// Extract just the arXiv ID portion (remove any URL prefix)
arxivID := strings.TrimPrefix(paper.Paper.ArxivID, "http://arxiv.org/abs/")
arxivID = strings.TrimPrefix(arxivID, "https://arxiv.org/abs/")
fmt.Fprintf(file, "## [%s](https://arxiv.org/abs/%s)\n", title, arxivID)
fmt.Fprintf(file, "**arXiv ID:** %s\n\n", arxivID)
fmt.Fprintln(file, "**Abstract:**")
// Format abstract as blockquote, handling multiple paragraphs