/ra-mcp-tools:archive-searchfrom ra-mcp-tools
Guides querying the Swedish National Archives (Riksarkivet) search tools with verified syntax for fuzzy, wildcard, and multi-term searches. Load before calling search_transcribed or search_metadata.
Ships in ra-mcp-tools. 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.
None: SKILL.md is the whole skill.
Search strategy, syntax, and best practices for the Riksarkivet search tools
(search_transcribed and search_metadata).
| Research goal | Tool | Key params |
|---|---|---|
| Find text mentions in court records | search_transcribed | keyword |
| Find a person by name | search_metadata | name="Svensson" |
| Find documents from a place | search_metadata | place="Norrköping" |
| Find documents by title/type | search_metadata | keyword="bouppteckning" |
| Church records, estate inventories | search_metadata | keyword + place (not AI-transcribed) |
| Read full page content | browse_document | reference_code, pages |
The search API is a plain free-text engine, NOT a full Solr/Lucene endpoint. Every syntax claim below is verified against the live API.
| Syntax | Example | Meaning |
|---|---|---|
| Single term | Stockholm | Find the word |
| Several terms | pest smitta | ALL terms required in the same document (implicit AND) |
| Wildcard | troll*, st?ckholm, *holm | * = many chars, ? = one char |
| Fuzzy | Stockholm~1 | Similar words (edit distance) |
NOT supported — never use:
AND / OR / NOT / | / parentheses. There is no boolean parser. The
words AND/OR/NOT are searched as literal text: and alone matches 1.6M
volumes, so pest AND smitta returns ~1.64M junk hits instead of the
33-document conjunction pest smitta. The server rejects such queries.troll*, then häx*, and merge what you learn.search_transcribed; use plain multi-term search
(kyrka stöld = both words anywhere in the volume). In search_metadata,
quotes work only for reference codes: "SE/RA/720660" lists an archive's
volumes, but quoted title phrases return 0."a b"~10. Not honored — returns 0 like any quoted phrase.term^4). Unverified; adds nothing. Leave it out.All searchable text is AI-generated using HTR (Handwritten Text Recognition) and OCR models. These transcriptions contain recognition errors: misread characters, merged or split words, and garbled passages — especially in older, damaged, or poorly legible documents.
Always use fuzzy search (~) by default to compensate for transcription errors:
stockholm~1 finds "Stockholm", "Stockholn", "Stookholm" (common HTR misreads)trolldom~1 finds "trolldom", "trolldoin", "trolldorn"präst~1 finds "präst", "prast", "prest"Without fuzzy search, you will miss many relevant results because the transcription of the exact word you're looking for may contain errors.
Rule of thumb: Use ~1 (edit distance 1) for short words, ~2 for longer words or
very old/damaged documents. For stem variants use a wildcard instead: troll*.
search_transcribed(keyword, offset=0) for initial hitssearch_metadata to find documents by title, person, or placepest smitta
returns only documents containing bothbrowse_document to examine interesting matches in fullCommon spelling pairs to search for — always try both modern and archaic forms (as separate searches, or covered by one wildcard/fuzzy term):
| Modern | Archaic / Variant | Covered by |
|---|---|---|
| präst | prest | pr?st or präst~1 |
| silver | silfver, silfv | sil*er or silf* |
| guld | gull | gul* |
| kyrka | kyrcka, kyrck | kyrk* or kyrck* |
| kvinna | qvinna, qwinna | q*inna or kvinna~1 |
| stöld | tiufnad, tjufnad | separate searches |
| häxa | hexa | h?xa |
| trolldom | trulldom | tr?lldom |
| djävul | djäfvul, diefvul | dj?f* + separate searches |
General letter drift: ä↔æ/e, ö↔ø/o, v↔f/fv/w, k↔ck/c — ? and ~1 absorb most of it.
troll* finds "trolldom", "trolleri", "trollkona"Stockholm~1 catches HTR/OCR misreadskyrka stöld silver = volumes containing all threeyear_min/year_max to narrow time periodssort="timeAsc" for earliest mentions, sort="timeDesc" for most recentname and place parameters in search_metadata
for targeted person/place searches instead of putting everything in keywordWhat SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
riksarkivet, swedish-archives, historical-search, fuzzy-search, htr
npx claudepluginhub ai-riksarkivet/ra-mcp --plugin ra-mcp-tools8 skills in this plugin
/archival-guideWhich Swedish records exist and where — maps a research topic to the right Förvaltningshistorik chapter (served as MCP resources), so you know what record type answers a question and which authority created it. Use when the user asks where to find records about something, what a record type is, or about court, church, tax, military, or population records (folkbokföring, bouppteckning, dombok, husförhörslängd, mantalslängd).
/archive-researchHow to browse, cite, and present archival findings — load AFTER search, when reading documents or reporting results. Covers research-integrity rules (never fabricate reference codes, always cite the exact page), old-Swedish translation, and the browse→synthesize workflow. Use when the user wants to browse or read pages, examine or interpret a document, translate old Swedish, or have findings cited and presented.
/feedback-lsSend document pages to Label Studio for human review — pre-annotated tasks from ALTO XML, or blank image-only tasks to annotate from scratch. Use when the user wants human review, correction, or quality assurance of transcriptions or line/region segmentation, or wants to build annotation tasks from browse results.
/htr-transcriptionTranscribe handwritten historical documents with the HTRflow MCP tools — batch images into one htr_transcribe call and present the interactive viewer. Use when the user wants to transcribe or OCR handwriting, read old handwriting, or digitize a manuscript.
/pdf-guideSearches and reads Riksarkivet's archival PDF guides (medieval Sweden, governance 1520-1920, Sami history). Use when user asks about Swedish history, archives, medieval charters, governance, Sami, or wants to open/search PDF guides. Provides section-level references with page numbers for citation./upload-filesTurn local files or user attachments into public URLs by uploading them to the Gradio server, so tools that require http(s) URLs (htr_transcribe, the viewer) can reach them. Use when you have local images or ALTO/PAGE XML — an attachment or a file path — but a tool needs a URL.
Other plugins' skills for the same job