semanticscholar-skill
Use when searching academic papers, looking up citations, finding authors, or getting paper recommendations using the Semantic Scholar API. Triggers on queries about research papers, academic search, citation analysis, or literature discovery.
Security Assessment
About semanticscholar-skill
Semantic Scholar Search provides a structured, four-phase workflow for discovering and analyzing academic literature through the Semantic Scholar API. It requires python3 and the requests package; an S2_API_KEY is optional but recommended for higher rate limits, and the underlying s2.py automatically falls back to unauthenticated mode, widening the request gap to five seconds, when no key is present. A critical operating rule is to never issue multiple sequential Bash calls for API requests; instead, every search is written into a single Python script that begins with a standard prelude locating s2.py, then executed once, because rate limiting, retries, and backoff are handled internally.
Phase 1 parses user intent against a decision tree that maps needs to functions. The default is search_bulk() combined with build_bool_query(), since bulk search is preferred as less resource-intensive, while search_relevance() is reserved for cases needing TLDR fields or inline author and citation details. Other paths include search_snippets() for specific passages, match_title() and get_paper() for known works, get_citations() for citation traversal, find_similar() and recommend() for single- and multi-seed recommendations, and search_authors(), get_author(), and get_author_papers() for researcher workflows. Query-construction guidance covers disambiguating terms with exact phrases and exclusions, planning separate searches for multi-context queries, and applying filters for year, publication date, fields of study, minimum citations, publication type (such as Review or ClinicalTrial), and open access.
Phase 2 executes the script and checkpoints for successful runs and non-empty results, broadening the query if nothing returns. Worked examples demonstrate an author workflow, a citation chain that preserves contextsWithIntent labels, and multi-seed recommendations with BibTeX export via batch_papers() and export_bibtex(). Phase 3 summarizes and presents results using format_results() for a consistent summary table plus top-ten details, notes the total count and strategy used, and can render summaries in Chinese when the user's language is Chinese. Utility helpers such as deduplicate() keep result sets clean across combined searches.
FAQ
Do I need an API key to use it?
No. It works unauthenticated with strict rate limits. Setting S2_API_KEY grants higher limits; without a key, s2.py drops the x-api-key header and widens the request gap to five seconds to protect against heavy-use throttling.
Which search function should I use by default?
search_bulk() combined with build_bool_query(). Per Semantic Scholar's own docs, bulk search is preferred over relevance search because relevance search is more resource-intensive; use search_relevance() only when you need TLDR or inline author and citation details.
Why write one script instead of several Bash calls?
The skill's critical rule is to never make multiple sequential Bash calls for API requests. You write one Python script that runs all searches and execute it once, because rate limiting, retries, and backoff are handled automatically inside s2.py.
How do I find papers that cite a known work?
Use get_citations() with the paper's ID. The citation envelopes carry contextsWithIntent, which you should keep rather than flatten so intent labels and context snippets render in the output.
Can it export citations as BibTeX?
Yes. Call batch_papers() with fields including title and citationStyles for the paper IDs you want, then pass the result to export_bibtex().
Install semanticscholar-skill
Quick Setup:
- Copy the skill folder to
.claude/skills/ - Claude will automatically detect and use the skill
Repository
agents365-ai/365-skills