Skip to main content
Glama

Download article

article_download

Download a paper from Anna's Archive by DOI or MD5 hash, reusing an existing local file when its MD5 matches or saving a new copy.

Instructions

Download a selected paper by exactly one of doi or hash. The hash field accepts a bare MD5 or an Anna's Archive /md5/ page URL. Resolves a DOI to its hash, then returns an existing file in ANNAS_DOWNLOAD_PATH if its full MD5 matches, otherwise downloads under a unique name. Returns path and bytes; downloads_left is omitted on local reuse. Optional title and format control a new file's name.

Input Schema

NameRequiredDescriptionDefault
doiNoDOI, doi: identifier or https://doi.org/ URL. Supply exactly one of doi or hash
hashNo32-character MD5 hash or Anna's Archive /md5/ page URL. Supply exactly one of doi or hash
titleNoOptional title override for the saved filename
formatNoOptional filename extension such as pdf. Inferred when omitted; does not convert the file
timeout_secondsNoTotal operation timeout in seconds, including retries. Defaults to 1800; maximum 86400

Output Schema

NameRequiredDescriptionDefault
pathYes
bytesYes
downloads_leftNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv0.7.0
    • changedInput schema / properties / doi / description
      Previous value: -"DOI, doi: identifier, or https://doi.org/ URL. Supply exactly one of doi or hash"New value: +"DOI, doi: identifier or https://doi.org/ URL. Supply exactly one of doi or hash"
    • changedInput schema / properties / hash / description
      Previous value: -"32-character MD5 hash from search. Supply exactly one of doi or hash"New value: +"32-character MD5 hash or Anna's Archive /md5/ page URL. Supply exactly one of doi or hash"
    • addedOutput schema / properties / downloads_left
      Added value: +{
      +  "type": [
      +    "null",
      +    "integer"
      +  ]
      +}
  2. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations only declare the mutation/openWorld profile (readOnlyHint=false, destructiveHint=false, idempotentHint=false, openWorldHint=true). The description goes well beyond that, disclosing the resolution flow (DOI to hash), the local-reuse behavior when the full MD5 matches, the fallback of downloading under a unique name, and that downloads_left is omitted on reuse — exactly the operational detail an agent needs.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the identifier constraint, then the resolution/reuse flow, then the parameter caveat. Dense but each clause carries information; the only cost is that the third sentence reads as a run-on, slightly hurting scannability.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a download tool with a full output schema, the description covers everything an agent needs: identifier rules, resolution and reuse behavior, naming effects of optional params, and the fact that downloads_left is conditionally present. Nothing material is left to inference.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description adds value by tying title and format to the reuse path ('control a new file's name'), implying they are ignored when an existing file is reused. That is meaningful semantics not spelled out in the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Download a selected paper') and immediately constrains the identifier to 'exactly one of doi or hash'. Combined with the word 'paper', an agent can distinguish it from the sibling book_download and from article_search without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives clear selection conditions: use exactly one of doi or hash, and the hash field accepts either a bare MD5 or an Anna's Archive /md5/ page URL. It does not explicitly name a sibling alternative (e.g., book_download for non-article items), so it stops short of full when/when-not routing, but the implied scope is unambiguous.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.