agentscope.service.web.arxiv module
Search papers in arXiv API. This implementation refers to the repository https://github.com/lukasschwab/arxiv.py, which is MIT licensed.
- agentscope.service.web.arxiv.arxiv_search(search_query: str, id_list: List[str] | None = None, start: int = 0, max_results: int | None = None) ServiceResponse [source]
Search arXiv paper by a given query string.
- Parameters:
search_query (str) – The query string, supporting prefixes “all:”, “ti:”, “au:”, “abs:”, “co:”, “jr:”, “cat:”, and “rn:”, boolean operators “AND”, “OR” and “ANDNOT”. For example, searching for papers with title “Deep Learning” and author “LeCun” by a search_query ti:”Deep Learning” AND au:”LeCun”
id_list (List[str], defaults to None) – A list of arXiv IDs to search.
start (int, defaults to 0) – The index of the first search result to return.
max_results (Optional[int], defaults to None) – The maximum number of search results to return.
- Returns:
A dictionary with two variables: status and content. The status variable is from the ServiceExecStatus enum, and content is a list of search results or error information, which depends on the status variable.
- Return type:
ServiceResponse