wikicitation-mcp

v0.5.2
wikicitation-mcp Checked 1 day ago Published 1 month ago

MCP server providing Wikipedia citation-science tools for Claude -- pure Python, no R required

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

get_article_history Get Article History

Retrieve the full revision history of a Wikipedia article. Returns one row per revision: art, revid, parentid, user, userid, timestamp, size, comment, tags -- sorted oldest first. Wikitext is not included; use get_article_recent for that.

ParameterTypeDescription
article_name *stringArticle title (e.g. "Zeitgeber").
date_limitUpper date bound, ISO 8601 (default: now).
langstringWikipedia language code (default "en").

get_article_recent Get Article Recent

Retrieve the latest revision of an article (at or before date_limit), including its full wikitext. Returns {"metadata": {...}, "wikitext": "..."}.

ParameterTypeDescription
article_name *stringArticle title.
date_limitUpper date bound, ISO 8601 (default: now).
langstringWikipedia language code (default "en").

get_article_initial Get Article Initial

Retrieve the first (creation) revision of an article with its wikitext. Returns {"metadata": {...}, "wikitext": "..."}.

ParameterTypeDescription
article_name *stringArticle title.
langstringWikipedia language code (default "en").

get_article_info Get Article Info

Current page metadata: pageid, title, length, last revision id, touched timestamp. A non-existent page is reported with "missing": true.

ParameterTypeDescription
article_name *stringArticle title.
langstringWikipedia language code (default "en").

get_tables_all Get Tables All

Info + initial revision + latest revision + full history in one call. Returns {"info", "initial", "recent", "history"}.

ParameterTypeDescription
article_name *stringArticle title.
date_limitUpper date bound, ISO 8601 (default: now).
langstringWikipedia language code (default "en").

get_category_pages Get Category Pages

Article titles (namespace 0) directly in a category.

ParameterTypeDescription
category *stringCategory name, with or without the "Category:" prefix.
langstringWikipedia language code (default "en").

get_pages_in_cat_table Get Pages In Cat Table

Pages directly in a category as a table (pageid, ns, title, type).

ParameterTypeDescription
category *stringCategory name.
langstringWikipedia language code (default "en").

get_subcat_table Get Subcat Table

Direct subcategories of a category.

ParameterTypeDescription
catname *stringCategory name.
langstringWikipedia language code (default "en").
replacementstringCharacter substituted for spaces in titles (default "_").

get_subcat_multiple Get Subcat Multiple

Direct subcategories for several categories (rows carry source_category).

ParameterTypeDescription
catname_list *arrayCategory names (max 20).
langstringWikipedia language code (default "en").

get_subcat_with_depth Get Subcat With Depth

Recursively collect subcategories down to `depth` levels (1-5).

ParameterTypeDescription
catname *stringRoot category name.
depthintegerLevels to descend (default 1, max 5).
langstringWikipedia language code (default "en").
replacementstringCharacter substituted for spaces in titles (default "_").

get_page_in_cat_multiple Get Page In Cat Multiple

Pages in several categories (rows carry source_category).

ParameterTypeDescription
catname_list *arrayCategory names (max 20).
langstringWikipedia language code (default "en").

get_category_history Get Category History

Full revision history for a list of articles, concatenated.

ParameterTypeDescription
article_list *arrayArticle titles (max 100).
langstringWikipedia language code (default "en").

get_category_recent Get Category Recent

Latest revision metadata and wikitext for a list of articles. Returns {"metadata": [...], "wikitext": [...]} in input order.

ParameterTypeDescription
article_list *arrayArticle titles (max 100).
date_limitUpper date bound, ISO 8601 (default: now).
langstringWikipedia language code (default "en").

get_category_creation Get Category Creation

Creation (first revision) metadata for a list of articles.

ParameterTypeDescription
article_list *arrayArticle titles (max 100).
langstringWikipedia language code (default "en").

get_doi_count Get Doi Count

Count DOIs in a wikitext string. Returns {"count": n}.

ParameterTypeDescription
text *string

get_ref_count Get Ref Count

Count <ref> tags in a wikitext string. Returns {"count": n}.

ParameterTypeDescription
text *string

get_url_count Get Url Count

Count http(s) URLs in a wikitext string. Returns {"count": n}.

ParameterTypeDescription
text *string

get_isbn_count Get Isbn Count

Count ISBNs in a wikitext string. Returns {"count": n}.

ParameterTypeDescription
text *string

get_any_count Get Any Count

Count matches of a regular expression in a text. Returns {"count": n}.

ParameterTypeDescription
regexp *stringPython regular expression (max 500 chars).
text *stringText to search.

extract_citations Extract Citations

Return every {{cite ...}} template found in a wikitext string.

ParameterTypeDescription
text *string

parse_cite_type Parse Cite Type

Parse one {{cite ...}} template string. Returns {"cite_type": "journal", "fields": {...}}, or {} if none is found.

ParameterTypeDescription
text *string

extract_with_regex Extract With Regex

Apply a regular expression to an article's latest wikitext.

ParameterTypeDescription
article_name *stringArticle title.
regexp *stringPython regular expression (max 500 chars).
date_limitUpper date bound, ISO 8601 (default: now).
langstringWikipedia language code (default "en").

extract_all_regex Extract All Regex

Apply all built-in patterns (doi, url, ref, isbn, wikilink, pmid, cite_all) to an article's latest wikitext.

ParameterTypeDescription
article_name *stringArticle title.
date_limitUpper date bound, ISO 8601 (default: now).
langstringWikipedia language code (default "en").

parse_citations Parse Citations

Structured citation table, one row per citation template (doi, isbn, pmid, url, title, author, year, journal, publisher, accessdate). Understands the native templates of en/fr/de/es/it/pt Wikipedias.

ParameterTypeDescription
article_name *stringArticle title.
date_limitUpper date bound, ISO 8601 (default: now).
langstringWikipedia language code (default "en").

parse_all_citations Parse All Citations

Long-form citation table, one row per template field (variable, value, canonical_field).

ParameterTypeDescription
article_name *stringArticle title.
date_limitUpper date bound, ISO 8601 (default: now).
langstringWikipedia language code (default "en").

get_citation_types Get Citation Types

Count citation templates by canonical type (journal, book, web, news, ...) for an article.

ParameterTypeDescription
article_name *stringArticle title.
date_limitUpper date bound, ISO 8601 (default: now).
langstringWikipedia language code (default "en").

get_source_type_counts Get Source Type Counts

Count citation templates by canonical type in a raw wikitext string.

ParameterTypeDescription
text *stringWikitext.
langstringWikipedia language code whose templates to recognise (default "en").

get_sci_score Get Sci Score

SciScore: the fraction of an article's citation templates that cite journals (0-1). Returns {"sci_score", "article", "lang", "revid"}.

ParameterTypeDescription
article_name *stringArticle title.
date_limitUpper date bound, ISO 8601 (default: now).
langstringWikipedia language code (default "en").

get_top_cited_papers Get Top Cited Papers

The (up to) 40 most-cited DOIs in an article, annotated through EuropePMC and ranked by how many times the article cites them (wiki_count).

ParameterTypeDescription
article_name *stringArticle title.
date_limitUpper date bound, ISO 8601 (default: now).
langstringWikipedia language code (default "en").

get_revert_counts Get Revert Counts

Revert-tagged edits (mw-reverted, mw-undo, mw-rollback) per article in a date window, most reverted first. Wikipedia only keeps recent changes for about 30 days, so older windows return partial or empty results. The scan can take a minute or more.

ParameterTypeDescription
endLast day, YYYY-MM-DD (default: today, UTC).
langstringWikipedia language code (default "en").
startFirst day, YYYY-MM-DD (default: 7 days before `end`).

annotate_dois_europmc Annotate Dois Europmc

Annotate DOIs through EuropePMC: PMID/PMCID, title, authors, journal, year, citation_count, is_open_access. One row per input DOI.

ParameterTypeDescription
doi_list *arrayDOIs such as "10.1038/nature02260" (max 200).

annotate_dois_crossref Annotate Dois Crossref

Annotate DOIs through CrossRef: title, authors, journal, year, publisher, type, is_referenced_by_count, url.

ParameterTypeDescription
doi_list *arrayDOIs (max 200).

annotate_dois_bibtex Annotate Dois Bibtex

BibTeX entries for DOIs (CrossRef content negotiation). Returns {"bibtex_entries": [...]}.

ParameterTypeDescription
doi_list *arrayDOIs (max 200).

annotate_isbn_google Annotate Isbn Google

Book metadata from Google Books for one ISBN. The keyless quota is small; set GOOGLE_BOOKS_API_KEY in the server's environment to avoid HTTP 429, or use annotate_isbn_openlib instead.

ParameterTypeDescription
isbn *stringISBN-10 or ISBN-13, hyphens allowed.

annotate_isbn_openlib Annotate Isbn Openlib

Book metadata from Open Library for one ISBN.

ParameterTypeDescription
isbn *stringISBN-10 or ISBN-13, hyphens allowed.