[Tex/LaTex] Citing acronyms with acro package

acroacronymsciting

using the cite and cite-cmd features of the acro package seems to have at least two problems for me.

  1. When an acronym occurs only once, it is spelled out without the abbreviation, which is fine. However, I would like the citation to still be printed (the first time at least)!

  2. When using the author-year citation style, two consecutive parenthesis aren't particularly pleasing. I'd like to have something like (AIS, Neal 2009) instead of (AIS) (Neal 2009). Is this possible?

The points are illustrated by the following MWE:

\documentclass{article}
\usepackage{filecontents}
\begin{filecontents*}{sample.bib}
@article{neal2001annealed,
    title = {{Annealed importance sampling}},
    author = {Neal, R},
    journal = {Statistics and Computing},
    year = {2001},
}
\end{filecontents*}

\usepackage[natbib,citestyle=authoryear,backend=bibtex]{biblatex}
\addbibresource{sample.bib}
\usepackage{acro}
\acsetup{single,sort,cite-cmd=\citep}
\DeclareAcronym{AIS}{
  short=AIS,long=Annealed Importance Sampling,cite={neal2001annealed}
}
\DeclareAcronym{AIS2}{
  short=AIS,long=Annealed Importance Sampling,cite={neal2001annealed}
}
\begin{document}
   This \ac{AIS} lacks the citation, because it only occurs once!

   This \ac{AIS2} occurs twice (\ac{AIS2}), but has double parenthesis, I'd prefer (AIS, \textbackslash \texttt{citealp\{key\}})

   \printacronyms
\end{document}

result of mwe

Best Answer

Since v2.0 (2015/08/17) there are the options group-citation and group-cite-cmd:

\acsetup{
  group-citation = true ,
  group-cite-cmd = \citealp
}

acro now (since v2.0) also adds the citation to a single use (IMHO this makes a lot more sense than omitting it).

A full example:

enter image description here

% http://tex.stackexchange.com/q/246008/
\documentclass{article}

\usepackage{filecontents}
\begin{filecontents*}{\jobname.bib}
@article{neal2001annealed,
  title   = {Annealed importance sampling} ,
  author  = {Neal, R} ,
  journal = {Statistics and Computing} ,
  year    = {2001}
}
\end{filecontents*}

\usepackage[natbib,citestyle=authoryear,backend=biber]{biblatex}
\addbibresource{\jobname.bib}

\usepackage{acro}[2015/08/16]
\acsetup{
  single         = true ,
  sort           = true ,
  cite-cmd       = \citep ,
  group-citation = true ,
  group-cite-cmd = \citealp
}

\DeclareAcronym{AIS}{
  short = AIS,
  long = Annealed Importance Sampling,
  cite = {neal2001annealed}
}
\DeclareAcronym{AIS2}{
  short = AIS,
  long = Annealed Importance Sampling,
  cite = {neal2001annealed}
}

\begin{document}

\ac{AIS} -- only used once

\ac{AIS2} and \ac{AIS2} -- used twice

\printacronyms

\end{document}