Searches MIT Libraries via TIMDEX GraphQL API — catalog books, DSpace theses, ArchivesSpace collections, digital images, GIS data, and LibGuides. Supports title/author/subject search, source/language/format filters, and semantic vector search.
Ships in mit-timdex. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
Search MIT Libraries' catalog, repository, archives, and digital collections in one API. No API key needed.
TIMDEX is MIT Libraries' official discovery API. It is a GraphQL API: you send one POST request to one URL, with a query that names the fields you want back.
POST https://timdex.mit.edu/graphql
{"query": "{ search(searchterm: \"明史\") { hits records { title sourceLink } } }"}
Source (--source) | Content |
|---|---|
MIT Alma | Library catalog: books, e-books, journals, media (~480,000 records) |
DSpace@MIT | Theses, working papers, articles |
MIT ArchivesSpace | Archival collections and finding aids |
Digital Collections | Images (e.g. architecture and art slides) |
MIT GIS Resources | Geospatial data |
Research Databases, LibGuides, MIT Libraries Website | Guides and database listings |
MIT also has an Alma SRU endpoint (see alma-sru-catalogs). For catalog books, both find the same records. Counts for 明史 on 26 October 2026:
| Search | Results |
|---|---|
| TIMDEX, default (any word, OR) | 591, mostly noise |
TIMDEX, --boolean AND | 26 |
TIMDEX, --boolean AND --phrase (title contains 明史) | 2 (明史研究, 明史研究論叢) |
Alma SRU, title 明史 (with or without --phrase) | 2 (明史研究 first) |
So TIMDEX does not find more books. Use TIMDEX for what SRU lacks: DSpace theses and papers, ArchivesSpace, digital collections, facet counts and semantic search. Use alma-sru-catalogs to compare MIT with other libraries.
GraphQL rejects unknown fields with an error such as Field 'callNumber' doesn't exist on type 'Holding' (it is callnumber). The script asks for a tested field list. Use TimdexAPI.query() for custom queries.
searchterm (all fields), title, contributors, subjects, identifiers, locations, citation.source, content_type, language (lowercase, e.g. chinese), format, subject_filter, contributor_filter, place, literary_form, access. Run with --facets to see the values.keyword (default), semantic (vector search, good for concepts like "Ming dynasty painting"), hybrid.--boolean AND requires all words, but only for searchterm: field searches (--title, --subjects, …) ignore it (title="Ming shi" gives 1369 hits with or without AND).title="文廟" returns 1122 records (华文文学, 文化文本, …), and AND cannot narrow it.searchterm with AND instead, then keep the titles that really contain the term with phrase=True (CLI --phrase). 明史 → 26 records with AND → 2 with the phrase filter (明史研究, 明史研究論叢). Even AND alone is not a phrase search: searchterm="文廟" with AND returns two titles without 文廟.phrase=True filters each page after the search, so total is the server's count and returned is the page size before filtering. Page through with start to scan more.Ming shi also matches jian ming shi). Check the records.MIT is a science and engineering library. Its holdings in Chinese, Japanese and Korean are small, so many Chinese titles are simply not there, or only in translation. Example (26 October 2026): search 天工開物 gives 2,764 hits, all noise; --boolean AND gives 1 (a Springer book on ancient Chinese machines); --boolean AND --phrase gives 0. Only an author search found the book, as the 1966 English translation: search --contributors "Song, Yingxing". For Chinese-language books, try Harvard (harvard-library-catalog) or the East Asian collections in alma-sru-catalogs first.
start is a 0-based offset (from in GraphQL); limit is perPage (default 20 in both Python and the CLI; max 100).
python scripts/timdex_api.py search 明史 --limit 5 --facets
python scripts/timdex_api.py search 明史 --boolean AND --phrase --limit 50 # titles containing 明史
python scripts/timdex_api.py search --title "Ming shi" --source "MIT Alma" --language chinese
python scripts/timdex_api.py search "Ming dynasty painting" --mode semantic
python scripts/timdex_api.py search --subjects China --source "DSpace@MIT"
python scripts/timdex_api.py search --subjects China --source "MIT ArchivesSpace"
python scripts/timdex_api.py search --identifiers 9789863503996 # ISBN or OCLC number
python scripts/timdex_api.py record alma:9936111333206761
from scripts.timdex_api import TimdexAPI
mit = TimdexAPI()
result = mit.search("明史", source="MIT Alma", language="chinese", limit=10, facets=True)
print(result["total"], result["facets"]["source"])
for rec in result["records"]:
print(rec["title"], rec["publishers"], rec["url"])
mit.search("明史", boolean="AND", phrase=True, limit=50) # titles containing 明史
mit.search("Ming shi", boolean="AND", start=20, limit=20) # page 2 (AND works on searchterm only)
mit.get_record("alma:9936111333206761")
mit.query("{ search(title: \"Ming\") { hits } }") # raw GraphQL
Each summary has id, title, alternate_titles, source, content_type, format, languages, contributors, dates, publishers, edition, physical_description, summary, subjects, identifiers (by kind, e.g. ISBN, OCLC Number), call_numbers, holdings, links, citation, and url (the record page in Primo, DSpace, or ArchivesSpace).
source when you want only books (MIT Alma) or only theses (DSpace@MIT).--facets first on broad searches to see sources, languages, and formats.references/api_reference.md — endpoint, arguments, filters, record fields, examplesscripts/timdex_api.py — client and CLI (zero dependencies)tests/test_timdex_api.py — offline testsReport a problem. This skill is part of the public repository kltng/humanities-skills. If it fails (an API changed, a script errors, or these instructions are wrong), report it as a GitHub issue:
gh issue list --repo kltng/humanities-skills --state all --search "mit-timdex"gh issue create --repo kltng/humanities-skills --label bug --title "[mit-timdex] <short summary>" --body "<details>". Without gh, give the user this link: https://github.com/kltng/humanities-skills/issues/new?template=skill-problem.ymlCredit the source. The records come from TIMDEX, the discovery index built and run by MIT Libraries. Under the MIT Libraries open metadata policy, metadata made by MIT Libraries staff is CC0 1.0, and "Metadata discovered through TIMDEX should be afforded the same rights as those applied to the originating metadata records and systems." MIT asks that you "give attribution to MIT Libraries, the OCLC Online Computer Library Center, Inc., and any other original metadata sources, as appropriate". So name MIT Libraries and the source system shown in source (for example DSpace@MIT or MIT ArchivesSpace). Theses, images and archival material have their own rights.
Cite. If this skill helped work that is published, please cite it, together with the source credited above:
Tang, Kwok-leong. humanities-skills: mit-timdex (version ). GitHub, . https://github.com/kltng/humanities-skills
When you help a user write up results that relied on this skill, remind them once about this citation and the credit above.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
/mit-timdex:mit-timdexfrom mit-timdex
npx claudepluginhub kltng/humanities-skills --plugin mit-timdexOther plugins' skills for the same job