compose_highwire_tags#
- documenteer.citations.compose_highwire_tags(citation, *, url=None)#
Compose one citation as the Highwire
<meta>tags a page carries in its<head>, escaped and ready to emit.- Parameters:
citation (
Mapping[str,Any]) – The citation whose landing page this page is, as the mappingGuideCitation.to_html_contextcomposes and Sphinx’shtml_contextpublishes.url (
str|None, default:None) – The page’s own absolute URL, emitted ascitation_fulltext_html_url— the site’s base URL for the site’s own citation, or a claimed page’s URL.Nonewhen the site declares no base URL, in which case the tag is omitted rather than falling back to the doi.org redirect, which is not where the full text is.
- Returns:
The tags, one per line, in this order:
citation_title, then acitation_authorper author followed by that author’scitation_author_institutionandcitation_author_orcid, thencitation_publication_date,citation_doi,citation_publisher,citation_fulltext_html_url, andDC.identifier. Every value is escaped withhtml.escape; a field the citation does not state emits no tag.- Return type:
Notes
Highwire tags are what Google Scholar’s inclusion guidelines specify and what Zotero’s embedded-metadata translator reads, so a page that carries them gets a one-click “Save to Zotero” with the right title, creators, date, and DOI. The Dublin Core
DC.identifieris emitted alongside them as the complement DataCite’s landing-page guidance asks for.These tags are single-valued and describe the page’s landing-page subject, so exactly one citation composes them: the
selfentry for the site, or the single entry that claims a page (seedocumenteer.ext.citationpage). A page several entries claim emits none of them, because there is no one work the tags could be about.The date is written as
citation_publication_date, the spelling Google Scholar documents and the one thetechnotepackage emits since 0.11.0 (it wrotecitation_datebefore). Scholar documents only two forms for its value — a fullYYYY/MM/DDdate, or a year alone — so a work dated to the year alone emits2025rather than an invented2025/01/01, and a work dated to the month emits its year rather than a2025/06no guideline describes (see_highwire_date).