Skip to main content
Glama

Format a citation

format_citation
Read-only

Generates a ready-to-paste APA, MLA, or BibTeX citation for a paper from its DOI or OpenAlex ID, leaving out missing record fields instead of inventing them.

Instructions

Returns a ready to paste reference for one paper in APA, MLA or BibTeX, built from the OpenAlex record. Parts the record does not have, such as authors or a venue, are left out instead of invented, so check the result against the paper before you hand it in. A wrong or unknown reference returns a not found error that suggests searching by title or checking the DOI format. Inputs: paper (required, a DOI like 10.1038/nature14539, a doi.org link, or an OpenAlex id like W2741809807), style (required, apa, mla or bibtex). Example prompt: 'give me an APA citation for DOI 10.1038/nature14539.'

Input Schema

NameRequiredDescriptionDefault
paperYesA DOI like 10.1038/nature14539, a doi.org link, or an OpenAlex id like W2741809807.
styleYesThe citation style: apa, mla or bibtex.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.1.8

TDQS

A4.1/5.0
Behavior4/5

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

Beyond the readOnly/openWorld annotations, it discloses real behavior: missing fields are omitted rather than fabricated, and invalid references produce a not-found error with remediation hints (search by title, check DOI format). It does not discuss output length or any failure modes beyond not-found, which keeps it at a 4.

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?

The purpose is front-loaded in the first clause, followed by caveats and inputs, which is the right ordering. The input enumeration and the example prompt partially duplicate the schema, making it slightly longer than strictly necessary.

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

Completeness4/5

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

With no output schema, the description does the right thing by characterizing the return value as a paste-ready reference and by describing the error path. For a two-parameter, single-purpose formatter this is close to complete, though it could say more about what the reference contains when fields are missing.

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

Parameters3/5

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

Schema description coverage is 100%, and the description restates both parameters (paper formats, style values) essentially verbatim from the schema. The example prompt adds a little concreteness but no semantics beyond what the schema already encodes, so baseline 3 applies.

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?

The opening clause names a specific verb and artifact ('Returns a ready to paste reference for one paper') plus the supported styles (APA, MLA, BibTeX) and the data source (the OpenAlex record). This distinguishes it cleanly from retrieval siblings like get_paper or search_papers, which return records rather than formatted citations.

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?

The description gives a concrete trigger ('give me an APA citation for DOI ...') and a caution about verifying the result before submission, which frames the appropriate use. It does not explicitly name a sibling tool or state when not to use it, so it falls just short of full alternatives guidance.

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