Skip to main content

MCP server — web search, patent details, video transcripts, scholar profiles, and browser tools for Claude Code

Project description

docduty-search

MCP server that unifies web search, academic papers, videos, news, and patents behind a small set of composable tools — with optional Chrome browser integration for fetching JS-rendered pages, running JavaScript, parsing with Python, and taking screenshots.

Install

uv tool install docduty-search            # search + details only
uv tool install "docduty-search[browser]" # + fetch, js, py, screenshot

Setup

docduty-search setup

One command does everything:

  1. Prompts for API keys → saves to ~/.config/docduty-search/.env
  2. Installs the research skill → ~/.claude/skills/docduty-search/SKILL.md
  3. Registers the MCP server with Claude Code (if claude CLI is found)

API keys:

Tools

search

Search across 7 source types.

search("svelte 5 runes")                                      # web
search("machine learning", type="scholar")                     # papers with citations
search("react tutorial", type="video")                         # YouTube
search("AI regulation EU", type="news")                        # news
search("piezoelectric transducer", type="patents")             # patents
search("svelte logo", type="images")                           # images
search("electric vehicles", type="trends")                     # Google Trends
Parameter Description
query Search query (required)
type web · scholar · video · news · patents · images · trends
domains Filter by domain. Prefix with - to exclude: ["-reddit.com"]
language ISO 639-1 code: "en", "no", "de"
recency hour · day · week · month · year
num Max results (default 10)

Patent-specific filters:

Parameter Description
before "priority:YYYYMMDD" or "publication:YYYYMMDD"
after Same format as before
inventor Filter by inventor name
assignee Filter by assignee/company
country Country codes: "US,WO,EP"
status "GRANT" or "APPLICATION"
sort "new" or "old" (by filing date)

Per-type extras in results:

Type Extra fields
scholar authors, cited_by, result_id, resources (PDF links), author_ids
video duration, channel, views, video_id
news source
patents patent_id, pdf, filing_date, inventor, assignee

details

Get structured details for a result. Returns a summary inline; full data (claims, articles, transcript text) goes to the py() namespace.

details("patent/US11734097B1/en")          # patent claims, citations, similar
details("scholar/6497879044063343659")     # scholar article via Google Patents
details("t-NybWd6Sz0J")                   # citation formats (MLA, APA, BibTeX)
details("video/dQw4w9WgXcQ")              # video metadata + description
details("transcript/dQw4w9WgXcQ")          # full transcript text
details("author/nTJ7ihUAAAAJ")            # author profile, h-index, articles
ID format Inline response In py() namespace
patent/... title, abstract, dates, classifications, counts claims, patent_citations, cited_by, similar_documents
scholar/... same as patent same as patent
video/... title, channel, views, description_preview description
transcript/... chars, chapters full_text
author/... name, affiliations, h-index, articles_count articles, co_authors
result_id citation formats + export links

fetch (browser extra)

Navigate Chrome to a URL and extract content. Returns a summary with preview; full content available via py().

fetch("https://svelte.dev/docs/svelte/$state")
→ { url, title, chars, content_preview }

py("content[:500]")    # full extracted markdown
py("soup.select('h2')") # BeautifulSoup on raw HTML

Handles Cloudflare challenge pages automatically (waits for real Chrome to pass the challenge). Also handles documents (PDF/DOCX/PPTX/XLSX) via Content-Type detection and MarkItDown conversion.

js (browser extra)

Run JavaScript on the current page.

js("document.title")
js("[...document.querySelectorAll('h2')].map(h => h.textContent)")

py (browser extra)

Run Python with access to page content and all previous results.

py("len(content)")
py("[h.text for h in soup.select('article h2')]")
py("cache.clear()")

Available in namespace:

  • content — clean extracted markdown from last fetch()
  • html — raw HTML from last fetch()
  • soup — BeautifulSoup parsed HTML
  • url — current page URL
  • _ / _1.._N — result history across all tools
  • js_result — last js() result
  • cache — TTL cache, call cache.clear() to reset
  • claims, cited_by, full_text, etc. — from last details() call

screenshot (browser extra)

Capture the current page as PNG.

screenshot()                    # saves to temp file
screenshot("/tmp/page.png")    # saves to specific path

Example: Patent Research

# Search with filters
search("MEMS transducer", type="patents", assignee="Murata", country="US,JP", status="GRANT")

# Get structured details — claims, citations, similar documents
details(_1[0]["patent_id"])
py("len(claims)")           # 55 claims
py("claims[0][:200]")       # first claim preview
py("len(cited_by)")         # 61 forward citations

# Find prior art (replicates Google Patents "Find Prior Art" button)
search(" ".join(_2["prior_art_keywords"]), type="patents",
       before=f"priority:{_2['prior_art_date'].replace('-','')}")

# Follow a citation chain
details(_2["cited_by"][0]["patent_id"])

Example: Video Learning

# Find tutorials
search("svelte 5 runes tutorial", type="video", num=5)

# Get video details
details(f"video/{_1[0]['video_id']}")

# Get the full transcript
details(f"transcript/{_1[0]['video_id']}")
py("full_text[:500]")    # first 500 chars of spoken content

Example: Scholar Research

# Search papers
search("piezoelectric micromachined ultrasonic transducer review", type="scholar")

# Get citation formats
details(_1[0]["result_id"])    # MLA, APA, Chicago, BibTeX

# Author profile
details(f"author/{_1[0]['author_ids'][0]}")
py("articles[:3]")             # top 3 papers
py("co_authors")               # collaborators

Backends

Backend Used when API key
SerpAPI All search types + details SERPAPI_API_KEY (required)
Perplexity type="web" + domains set PERPLEXITY_API_KEY (optional)
Chrome CDP fetch, js, py, screenshot None (uses local Chrome)

Development

git clone https://github.com/user/docduty-search
cd docduty-search
uv sync --extra browser
ruff format src/ && ruff check src/

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

docduty_search-0.1.2.tar.gz (19.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

docduty_search-0.1.2-py3-none-any.whl (23.6 kB view details)

Uploaded Python 3

File details

Details for the file docduty_search-0.1.2.tar.gz.

File metadata

  • Download URL: docduty_search-0.1.2.tar.gz
  • Upload date:
  • Size: 19.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"EndeavourOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for docduty_search-0.1.2.tar.gz
Algorithm Hash digest
SHA256 19f469a5ec0ff796474790b43985ef13dca300f42f0e568f19321657bb7e6f9e
MD5 adc15328416b0a7fb8b1c62a2adb2d81
BLAKE2b-256 f64c35f3f428ff1faef8fbd088754189cf20230d50516bcab2a21a3fb55e1b74

See more details on using hashes here.

File details

Details for the file docduty_search-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: docduty_search-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 23.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.21 {"installer":{"name":"uv","version":"0.11.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"EndeavourOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for docduty_search-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 c8c554bdc20974ddb684c13fa54306f6df4c289954b3dbc62a3017a9fd4969fd
MD5 938ff6718f66e42f8f1a2fb32896654c
BLAKE2b-256 4f6d2a25587cd651538a77012a75e3a60ae1d82d3c7b76a78119f330205e7277

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page