MCPcopy Create free account
hub / github.com/OpenRaiser/PaperFlow / _extract_arxiv_id

Function _extract_arxiv_id

deployments/desktop/shared/agents.py:229–234  ·  view source on GitHub ↗
(value: Any)

Source from the content-addressed store, hash-verified

227 return _doi_value(_first_text(paper, metadata, "doi", "doi_url"))
228
229
230def _extract_arxiv_id(value: Any) -> str:
231 text = str(value or "").strip()
232 if not text:
233 return ""
234 match = re.search(r"(?:arxiv\.org/(?:abs|pdf)/)?(\d{4}\.\d{4,6}(?:v\d+)?)", text, flags=re.IGNORECASE)
235 return match.group(1) if match else ""
236
237

Callers 2

_paper_arxiv_idFunction · 0.85
_report_abs_urlFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected