vimalinx/bio-agent / .claude/skills/pma2apa
pma2apa
VerifiedUse when converting `PubmedArticle` XML from EDirect into APA-style citation text or APA-structured XML for downstream parsing.
pma2apa
Quick Start
- Command:
efetch -db pubmed -id <PMID> -format xml | pma2apa - Local executable:
/home/vimalinx/miniforge3/envs/bio/bin/pma2apa - Primary modes: default one-line citation text,
-xmlfor structured XML,-asciifor accent-normalized output
When To Use This Tool
- Turn PubMed XML records into APA-style citation strings inside shell pipelines.
- Keep an intermediate XML representation of parsed citation fields when downstream
xtractsteps need structure. - Normalize accented characters to ASCII before exporting to plain-text systems.
- Stay inside EDirect tooling after
efetch -format xmlinstead of post-processing citations elsewhere.
Common Patterns
# 1) Default APA citation line, prefixed by PMID
efetch -db pubmed -id 19212835 -format xml | pma2apa
# 2) Keep structured APA XML instead of flattening to one line
efetch -db pubmed -id 19212835 -format xml | pma2apa -xml
# 3) Force accent-normalized ASCII output
efetch -db pubmed -id 19212835 -format xml | pma2apa -ascii
Recommended Workflow
- Fetch
PubmedArticleXML withefetch -db pubmed -format xml. - Decide whether you need flat citation text or the structured XML intermediate.
- Add
-asciionly when the downstream consumer cannot handle accented characters. - Check the emitted title, journal, pages, and DOI fields before storing or reusing the citation.
Guardrails
- The tool reads
PubmedArticleXML from stdin; it does not fetch PubMed records by itself. - There is no built-in
--helpor--version; unknown arguments fail withUnrecognized argument .... - Accepted mode switches are the bare or dashed forms
xml/-xml,apa/-apa, andascii/-ascii. - Default text mode emits a single tab-delimited line that starts with the PMID and then the formatted citation.
-xmlkeeps the<APASet><APAFormat>...</APAFormat></APASet>intermediate instead of flattening to text.- The wrapper depends on EDirect helpers such as
transmuteandxtractbeing available onPATH.
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack." | Stars: 196k | Updated | Claude CodeCodex | Verified | Install |
| ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read. | Stars: 193k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report. | Stars: 193k | Updated | Claude CodeCodex | Verified | Install |
| ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt. | Stars: 193k | Updated | Claude CodeCodex | Verified | Install |