Finding Open Access Papers logo

Finding Open Access Papers

CommunityPopular
brycewang-stanford
Finding Open Access Papers

Use Unpaywall API to find free full-text versions of paywalled papers

Overview

Publisherbrycewang-stanford
RepositoryAuto-Empirical-Research-Skills
Skill nameFinding Open Access Papers
Stars
3.8K
Forks
479
Bundled files
Instructions only
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by brycewang-stanford on GitHub. Read the source before you install it.

Installation

Install the Finding Open Access Papers AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/brycewang-stanford/Auto-Empirical-Research-Skills.git /tmp/Auto-Empirical-Research-Skills
mkdir -p .claude/skills
cp -r /tmp/Auto-Empirical-Research-Skills/skills/05-kthorn-research-superpower/research/finding-open-access-papers .claude/skills/brycewang-stanford-finding-open-access-papers
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Finding Open Access Papers in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Finding Open Access Papers on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Finding Open Access Papers is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Finding Open Access Papers

Overview

Use Unpaywall to find legally available open access versions of papers that appear to be behind paywalls.

Core principle: Many paywalled papers have free versions (preprints, author manuscripts, institutional repositories). Unpaywall finds them.

When to Use

Use this skill when:

  • DOI resolution hits a paywall
  • Paper not available in PubMed Central
  • Publisher site requires subscription
  • Need full text for highly relevant paper (score ≥7)

Use BEFORE giving up on full text access

Unpaywall API

Simple REST API - no authentication required for reasonable usage

Basic Request

bash
curl "https://api.unpaywall.org/v2/DOI?email=YOUR_EMAIL"

Parameters:

  • DOI - The paper's DOI (URL-encoded if needed)
  • email - User's email (required, for courtesy/contact)

IMPORTANT: Ask user for their email at the start of research session. Do NOT use placeholder emails like claude@anthropic.com or researcher@example.com.

Example:

bash
curl "https://api.unpaywall.org/v2/10.1038/nature12373?email=user@example.com"

Response Format

json
{
  "doi": "10.1038/nature12373",
  "title": "Paper Title",
  "is_oa": true,
  "best_oa_location": {
    "url": "https://europepmc.org/articles/pmc3858213",
    "url_for_pdf": "https://europepmc.org/articles/pmc3858213?pdf=render",
    "version": "publishedVersion",
    "license": "cc-by",
    "host_type": "repository"
  },
  "oa_locations": [
    {
      "url": "https://europepmc.org/articles/pmc3858213",
      "version": "publishedVersion"
    },
    {
      "url": "https://arxiv.org/abs/1234.5678",
      "version": "submittedVersion"
    }
  ]
}

Key Response Fields

is_oa (boolean)

  • true - Open access version available
  • false - No free version found

best_oa_location (object or null)

  • Unpaywall's recommended best open access source
  • Prioritizes published versions over preprints
  • Includes PDF URL when available

oa_locations (array)

  • All known open access locations
  • Includes repositories, preprint servers, institutional sites
  • Ordered by quality/version

version types:

  • publishedVersion - Final published version (best)
  • acceptedVersion - Author's accepted manuscript (good)
  • submittedVersion - Preprint before peer review (useful)

Implementation Pattern

1. Check Unpaywall After Paywall Hit

bash
# Try DOI first
curl -L "https://doi.org/10.1234/example.2023"

# If paywall detected (403, subscription required, etc):
curl "https://api.unpaywall.org/v2/10.1234/example.2023?email=your@email.com"

2. Extract Best URL

bash
# Parse JSON response
response=$(curl -s "https://api.unpaywall.org/v2/DOI?email=EMAIL")

# Check if OA available
is_oa=$(echo $response | jq -r '.is_oa')

if [ "$is_oa" = "true" ]; then
  # Get best PDF URL
  pdf_url=$(echo $response | jq -r '.best_oa_location.url_for_pdf // .best_oa_location.url')

  # Download
  curl -L -o "papers/paper.pdf" "$pdf_url"
fi

3. Report to User

When OA found:

⚠️ Paper behind paywall at publisher
✓ Found open access version via Unpaywall!
   Source: Europe PMC (published version)
   PDF: https://europepmc.org/articles/pmc3858213?pdf=render
   → Downloading...

When no OA found:

⚠️ Paper behind paywall at publisher
✗ No open access version found via Unpaywall
   Options:
   - Request via institutional access
   - Contact authors for preprint
   - Continue with abstract only

4. Prioritize by Version

If multiple locations available:

Priority order:

  1. publishedVersion from publisher or PMC
  2. acceptedVersion from institutional repository
  3. submittedVersion from preprint server (arXiv, bioRxiv)

Integration with evaluating-paper-relevance

Add to full text fetching workflow:

Stage 2: Fetch Full Text

Try in order:
A. PubMed Central (free full text)
B. DOI resolution → If paywall, try Unpaywall
C. Unpaywall direct lookup
D. Preprints (bioRxiv, arXiv)

Updated workflow:

bash
# 1. Try PMC
pmc_result=$(curl "https://eutils.ncbi.nlm.nih.gov/...")
if has_pmc_fulltext; then
  fetch_pmc
  exit 0
fi

# 2. Try DOI
doi_result=$(curl -L "https://doi.org/$doi")
if is_paywall; then
  # 3. Try Unpaywall
  unpaywall_result=$(curl "https://api.unpaywall.org/v2/$doi?email=$EMAIL")
  if has_oa; then
    fetch_unpaywall_pdf
    exit 0
  fi
fi

# 4. No full text available
report_no_fulltext

Rate Limiting

Free tier (with email):

  • 100,000 requests per day
  • No hard rate limit, but be respectful
  • Include email in requests (required)

Best practices:

  • Add 100ms delay between requests
  • Cache responses (don't re-check same DOI)
  • Only check for papers you actually need

Python Helper Example

python
import requests
import time

def find_open_access(doi, email):
    """
    Find open access version via Unpaywall
    Returns: (pdf_url, version, source) or (None, None, None)
    """
    url = f"https://api.unpaywall.org/v2/{doi}"
    params = {"email": email}

    try:
        response = requests.get(url, params=params, timeout=10)
        response.raise_for_status()
        data = response.json()

        if not data.get('is_oa'):
            return None, None, None

        best_loc = data.get('best_oa_location')
        if not best_loc:
            return None, None, None

        pdf_url = best_loc.get('url_for_pdf') or best_loc.get('url')
        version = best_loc.get('version', 'unknown')
        source = best_loc.get('host_type', 'unknown')

        return pdf_url, version, source

    except Exception as e:
        print(f"Error checking Unpaywall for {doi}: {e}")
        return None, None, None

# Usage
doi = "10.1038/nature12373"
pdf_url, version, source = find_open_access(doi, "researcher@example.com")

if pdf_url:
    print(f"Found {version} at {source}")
    print(f"PDF: {pdf_url}")
    # Download PDF
    response = requests.get(pdf_url)
    with open(f'papers/{doi.replace("/", "_")}.pdf', 'wb') as f:
        f.write(response.content)
else:
    print("No open access version found")

time.sleep(0.1)  # Rate limiting

Common Sources Found

Repositories:

  • Europe PMC / PubMed Central
  • Institutional repositories (university sites)
  • PubMed Central international mirrors

Preprint servers:

  • bioRxiv (biology)
  • medRxiv (medicine)
  • arXiv (physics, CS, math)
  • ChemRxiv (chemistry)

Publisher sites:

  • Open access journals
  • Hybrid journals (OA articles in subscription journals)
  • Delayed open access (embargo expired)

Error Handling

DOI not found:

json
{
  "error": "true",
  "message": "DOI not found"
}

→ Check DOI format, try alternative identifiers

Network errors:

  • Retry with exponential backoff
  • Maximum 3 attempts
  • Report to user if all fail

Malformed response:

  • Check for is_oa field
  • Fallback to oa_locations array if best_oa_location missing

Quick Reference

TaskCommand
Check if OA availablecurl "https://api.unpaywall.org/v2/DOI?email=EMAIL"
Get best PDF URLParse .best_oa_location.url_for_pdf
List all OA sourcesParse .oa_locations[]
Check version typeLook at .version field
Download PDFcurl -L -o paper.pdf "$pdf_url"

Integration Points

Called by:

  • evaluating-paper-relevance - When full text not in PMC
  • answering-research-questions - For highly relevant papers

Updates:

  • papers-reviewed.json - Note if OA found
  • SUMMARY.md - Include OA source info

Common Mistakes

Using placeholder email: Using claude@anthropic.com or researcher@example.com → Ask user for their real email Not including email: Required parameter, requests will fail Checking every paper: Only check when needed (score ≥7, no PMC) Ignoring version type: Published version better than preprint Single source only: Check oa_locations array for alternatives No rate limiting: Add delays even though no hard limit

Success Criteria

Successful when:

  • Paywalled paper's OA version found and downloaded
  • Version type recorded (published/accepted/submitted)
  • User informed about source and version
  • Fallback options provided if no OA available

Next Steps

After finding OA version:

  • Download PDF to papers/ folder
  • Note source and version in SUMMARY.md
  • Continue with deep dive analysis
  • If no OA: note in summary, continue with abstract only

Frequently asked questions

What does the Finding Open Access Papers AI skill do?

Use Unpaywall API to find free full-text versions of paywalled papers

Why use Finding Open Access Papers on TypingMind?

Because you install it once and use it with any model. Finding Open Access Papers is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Finding Open Access Papers in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/brycewang-stanford/Auto-Empirical-Research-Skills/tree/main/skills/05-kthorn-research-superpower/research/finding-open-access-papers. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Finding Open Access Papers?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Finding Open Access Papers?

As many as you like. As long as a model supports skills, you can use Finding Open Access Papers with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Finding Open Access Papers AI skill free?

It is published on GitHub by brycewang-stanford. Check the repository for licensing terms. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇