Agent skill

Pubmed Search

by wu-yc in wu-yc/LabClaw

Search PubMed biomedical literature with natural language queries powered by Valyu semantic search.

MITAuto-check passedResearch & Science

Install Pubmed Search

skills CLI
$ npx skills add wu-yc/LabClaw --skill pubmed-search -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install wu-yc/LabClaw pubmed-search --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/wu-yc/LabClaw.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/literature/pubmed-search .claude/skills/pubmed-search && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
pubmed-search
GitHub stars
1.1k
Token cost
~1.4k tokens
SKILL.md length
286 words
Files
1
Skills in repo
68
Repo updated
First seen
Licence
MIT

At a glance

Search PubMed biomedical literature with natural language queries powered by Valyu semantic search.

  • Works in 2 steps: Node.js 18+ (uses built-in fetch) → Valyu API key from…
  • Tasks that involve Academic paper search
  • SKILL.md covers Why This Skill is Powerful, Requirements, CRITICAL: Script Path Resolution and API Key Setup Flow, plus 8 more sections
  • Calls jq; reaches platform.valyu.ai and api.valyu.ai

What it does

Pubmed Search is an agent skill from wu-yc/LabClaw. Search PubMed biomedical literature with natural language queries powered by Valyu semantic search. Full-text access, integrate into your AI projects.

Its SKILL.md is about 1.4k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Research & Science, covering Academic paper search. It works with PubMed. The repository describes itself as: LabClaw – Operating Layer for LabOS (Stanford-Princeton AI Co-Scientists). The licence is MIT.

When your agent uses it

  • Tasks that involve Academic paper search

Example prompts

  • “/pubmed-search”

Requirements

  • Python 3
  • Node.js

Workflow steps

2 steps, taken from the first numbered list in SKILL.md.

  1. Node.js 18+ (uses built-in fetch)
  2. Valyu API key from https://platform.valyu.ai ($10 free credits)

What it can do on your machine

Read from SKILL.md and the folder at commit df37802. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • jq

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Hosts in commands or code, which the agent is likely to contact:

    • platform.valyu.ai
    • api.valyu.ai
    • pubmed.ncbi.nlm.nih.gov

    Also links to:

    • docs.valyu.ai

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Pubmed Search loads about 1.4k tokens when it runs. Until then it costs about 41 tokens; SKILL.md has 286 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~41
When it runs · the whole SKILL.md, loaded when a task matches
~1.4k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from wu-yc/LabClaw at commit df37802, republished under its MIT licence (© wu-yc). 286 words, ~1,426 tokens.

Download SKILL.mdSave it as .claude/skills/pubmed-search/SKILL.md (or your agent's skills folder).
name
pubmed-search
description
Search PubMed biomedical literature with natural language queries powered by Valyu semantic search. Full-text access, integrate into your AI projects.
keywords
pubmed, biomedical-literature, medical-research, semantic-search, natural-language-queries, full-text-search, research-integration
license
MIT

Search the complete PubMed database of biomedical literature using natural language queries powered by Valyu's semantic search API.

Why This Skill is Powerful

  • No API Parameter Parsing: Just pass natural language queries directly - no need to construct complex search parameters
  • Semantic Search: Understands the meaning of your query, not just keyword matching
  • Full-Text Access: Returns complete article content, not just abstracts
  • Image Links: Includes figures and images from papers
  • Comprehensive Coverage: Access to all of PubMed's biomedical literature

Requirements

  1. Node.js 18+ (uses built-in fetch)
  2. Valyu API key from https://platform.valyu.ai ($10 free credits)

CRITICAL: Script Path Resolution

The scripts/search commands in this documentation are relative to this skill's installation directory.

Before running any command, locate the script using:

bash
PUBMED_SCRIPT=$(find ~/.claude/plugins/cache -name "search" -path "*/pubmed-search/*/scripts/*" -type f 2>/dev/null | head -1)

Then use the full path for all commands:

bash
$PUBMED_SCRIPT "CRISPR gene editing" 15

API Key Setup Flow

When you run a search and receive "setup_required": true, follow this flow:

  1. Ask the user for their API key: "To search PubMed, I need your Valyu API key. Get one free ($10 credits) at https://platform.valyu.ai"

  2. Once the user provides the key, run:

    bash
    scripts/search setup <api-key>
  3. Retry the original search.

Example Flow:
User: Search PubMed for CAR-T cell therapy advances
→ Response: {"success": false, "setup_required": true, ...}
→ Claude asks: "Please provide your Valyu API key from https://platform.valyu.ai"
→ User: "val_abc123..."
→ Claude runs: scripts/search setup val_abc123...
→ Response: {"success": true, "type": "setup", ...}
→ Claude retries: scripts/search "CAR-T cell therapy advances" 10
→ Success!

Usage

bash
scripts/search "your natural language query" [maxResults]
Examples
bash
# Search for recent COVID-19 research
scripts/search "COVID-19 vaccine efficacy studies" 15

# Find papers on a specific gene
scripts/search "BRCA1 mutations and breast cancer risk" 20

# Search for treatment approaches
scripts/search "immunotherapy for melanoma clinical trials" 10

# Drug mechanism research
scripts/search "mechanism of action of metformin in type 2 diabetes" 12
Setup Command
bash
scripts/search setup <api-key>

Output Format

json
{
  "success": true,
  "type": "pubmed_search",
  "query": "CRISPR gene editing",
  "result_count": 10,
  "results": [
    {
      "title": "Article Title",
      "url": "https://pubmed.ncbi.nlm.nih.gov/...",
      "content": "Full article text with figures...",
      "source": "pubmed",
      "relevance_score": 0.95,
      "images": ["https://example.com/figure1.jpg"]
    }
  ],
  "cost": 0.025
}

Processing Results

With jq
bash
# Get article titles
scripts/search "query" 10 | jq -r '.results[].title'

# Get URLs
scripts/search "query" 10 | jq -r '.results[].url'

# Extract full content
scripts/search "query" 10 | jq -r '.results[].content'

Common Use Cases

Literature Review
bash
# Find all papers on a topic
scripts/search "mechanisms of aging in humans" 50
Drug Discovery
bash
# Search for drug targets
scripts/search "novel targets for Alzheimer's disease treatment" 20
Clinical Research
bash
# Find clinical trial results
scripts/search "phase 3 trials for rheumatoid arthritis biologics" 15
Gene Function
bash
# Research gene function
scripts/search "role of TP53 in cancer development" 25

Error Handling

All commands return JSON with success field:

json
{
  "success": false,
  "error": "Error message"
}

Exit codes:

  • 0 - Success
  • 1 - Error (check JSON for details)

API Endpoint

  • Base URL: https://api.valyu.ai/v1
  • Endpoint: /search
  • Authentication: X-API-Key header

Architecture

scripts/
├── search          # Bash wrapper
└── search.mjs      # Node.js CLI

Direct API calls using Node.js built-in fetch(), zero external dependencies.

Adding to Your Project

If you're building an AI project and want to integrate PubMed search directly into your application, use the Valyu SDK:

Python Integration
python
from valyu import Valyu

client = Valyu(api_key="your-api-key")

response = client.search(
    query="immunotherapy for melanoma",
    included_sources=["valyu/valyu-pubmed"],
    max_results=20
)

for result in response["results"]:
    print(f"Title: {result['title']}")
    print(f"URL: {result['url']}")
    print(f"Content: {result['content'][:500]}...")
TypeScript Integration
typescript
import { Valyu } from "valyu-js";

const client = new Valyu("your-api-key");

const response = await client.search({
  query: "immunotherapy for melanoma",
  includedSources: ["valyu/valyu-pubmed"],
  maxResults: 20
});

response.results.forEach((result) => {
  console.log(`Title: ${result.title}`);
  console.log(`URL: ${result.url}`);
  console.log(`Content: ${result.content.substring(0, 500)}...`);
});

See the Valyu docs for full integration examples and SDK reference.

© wu-yc, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in skills/literature/pubmed-search of wu-yc/LabClaw.

Open the folder on GitHubat commit df37802

Compare with similar skills

Pubmed Search next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Pubmed Search compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Pubmed Search this skillwu-yc/LabClaw1.1k—~1.4kAutomated safety check: PassMIT
Literature Reviewneflibata-feng/MyArxiv-Agent12620 repos~5.9kAutomated safety check: NotesMIT
Citation ManagementK-Dense-AI/claude-scientific-writer2.4k2 repos~3.9kAutomated safety check: NotesMIT
Citation Managementneflibata-feng/MyArxiv-Agent12619 repos~8.1kAutomated safety check: NotesMIT
Paper Searchopenags/paper-search-mcp2.8k—~1.2kAutomated safety check: NotesMIT
Nature Academic Searchwp-a/nature-academic-search304—~1.4kAutomated safety check: PassMIT

Similar skills

  • Literature Review

    neflibata-feng/MyArxiv-Agent

    Conduct comprehensive, systematic literature reviews using multiple academic databases (PubMed, arXiv, bioRxiv, Semantic Scholar, etc.).

    126 GitHub starsUsed in 20 repos~5.9k tokens
    Research & ScienceAuto-check: notes
  • Citation Management

    K-Dense-AI/claude-scientific-writer

    Finds papers in OpenAlex, PubMed and Google Scholar, turns DOIs, PMIDs and arXiv IDs into clean BibTeX, and validates citations for a manuscript or thesis.

    2.4k GitHub starsUsed in 2 repos~3.9k tokens
    Research & ScienceAuto-check: notes
  • Citation Management

    neflibata-feng/MyArxiv-Agent

    Comprehensive citation management for academic research. An agent skill from neflibata-feng/MyArxiv-Agent.

    126 GitHub starsUsed in 19 repos~8.1k tokens
    Research & ScienceAuto-check: notes
  • Paper Search

    openags/paper-search-mcp

    Search, download, and read academic papers from 20+ sources (arXiv, PubMed, Semantic Scholar, CrossRef, etc).

    2.8k GitHub stars~1.2k tokensUpdated 9 days ago
    Research & ScienceAuto-check: notes
  • Nature Academic Search

    wp-a/nature-academic-search

    A skill your agent uses when users ask to 找文献、做文献检索、查论文、查临床试验、核验引用、去重文献、设计 PubMed/MeSH 检索式、追踪上下游引文、解析 DOI/PMID/PMCID/arXiv/OpenAlex/Semantic Scholar/NCT ID, 或导出 RIS、BibTeX、NBIB、ENW;also use for…

    304 GitHub stars~1.4k tokensUpdated 9 days ago
    Research & ScienceAuto-check passed
  • Journal Selector for Manuscripts

    huangwb8/ChineseResearchLaTeX

    Recommends journals for a manuscript by filtering a bundled impact-factor catalog, verifying scope and quality online, and writing a ranked Markdown report.

    2.9k GitHub stars~1.7k tokensUpdated 7 days ago
    Research & ScienceAuto-check passed

More from wu-yc/LabClaw

All 68 skills in this repo
  • Retrieves chemical compound information from PubChem and ChEMBL with disambiguation, cross-referencing, and quality assessment.

    1.1k GitHub starsUsed in 2 repos~2.3k tokens
    Auto-check passed
  • Search and retrieve clinical practice guidelines across 12+ authoritative sources including NICE, WHO, ADA, AHA/ACC, NCCN, SIGN, CPIC, CMA, CTFPHC, GIN, MAGICapp, PubMed, EuropePMC, TRIP, and…

    1.1k GitHub starsUsed in 2 repos~4.9k tokens
    Auto-check passed
  • Generate comprehensive disease research reports using 100+ ToolUniverse tools.

    1.1k GitHub starsUsed in 2 repos~4.7k tokens
    Auto-check passed
  • Identify drug repurposing candidates using ToolUniverse for target-based, compound-based, and disease-driven strategies.

    1.1k GitHub starsUsed in 2 repos~4.4k tokens
    Auto-check passed
  • Retrieves gene expression and omics datasets from ArrayExpress and BioStudies with gene disambiguation, experiment quality assessment, and structured reports.

    1.1k GitHub starsUsed in 2 repos~2.6k tokens
    Auto-check passed
  • Perform comprehensive gene enrichment and pathway analysis using gseapy (ORA and GSEA), PANTHER, STRING, Reactome, and 40+ ToolUniverse tools.

    1.1k GitHub starsUsed in 2 repos~4k tokens
    Auto-check passed

Works with

Questions about Pubmed Search

What does Pubmed Search do?

Search PubMed biomedical literature with natural language queries powered by Valyu semantic search. Pubmed Search is an agent skill from wu-yc/LabClaw. Search PubMed biomedical literature with natural language queries powered by Valyu semantic search.

When should I use Pubmed Search?

Pubmed Search fits situations like: tasks that involve Academic paper search.

How do I install Pubmed Search in Claude Code?

Run `npx skills add wu-yc/LabClaw --skill pubmed-search -a claude-code`. Or copy the skill folder (skills/literature/pubmed-search in wu-yc/LabClaw) into .claude/skills/pubmed-search in your project. Claude Code loads it when a task matches its description.

How do I install Pubmed Search in Codex?

Run `npx skills add wu-yc/LabClaw --skill pubmed-search -a codex`. Or copy the skill folder (skills/literature/pubmed-search in wu-yc/LabClaw) into .agents/skills/pubmed-search in your project. Codex loads it when a task matches its description.

Can I use Pubmed Search in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add wu-yc/LabClaw --skill pubmed-search -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/pubmed-search, .gemini/skills/pubmed-search, .github/skills/pubmed-search and .opencode/skills/pubmed-search in your project.

What does Pubmed Search need to run?

Going by SKILL.md and its folder, Pubmed Search needs the command-line tools its instructions call (jq). Our summary lists: Python 3; Node.js.

Does Pubmed Search access the network?

SKILL.md names 4 domains. In commands or code: platform.valyu.ai, api.valyu.ai and pubmed.ncbi.nlm.nih.gov; the agent is likely to contact these when it follows the instructions. As links in the text: docs.valyu.ai. This is read from the text; nothing was executed.

Is Pubmed Search safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Pubmed Search use?

Pubmed Search is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Pubmed Search use?

About 1.4k tokens (SKILL.md is roughly 5.7k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Pubmed Search?

Skills that share tags, products or a category with Pubmed Search: Literature Review (neflibata-feng/MyArxiv-Agent, 126 stars), Citation Management (K-Dense-AI/claude-scientific-writer, 2.4k stars), Citation Management (neflibata-feng/MyArxiv-Agent, 126 stars) and Paper Search (openags/paper-search-mcp, 2.8k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Pubmed Search?

wu-yc (a GitHub user) maintains it in wu-yc/LabClaw, which has 1,055 GitHub stars. The repository holds 68 skills in this directory. The repository was last updated on March 19, 2026.

Source: wu-yc/LabClaw on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.