# Glossaries - expand acronyms for first-time use within each chapter

I am not sure if this is acceptable typographic convention - but my PhD advisor would like me to expand each acronym for its first use within each chapter of my PhD thesis.

The rationale is that, if the reader (maybe an expert) chooses to skip over the introduction (where a particular acronym was first used) and goes straight to a middle chapter, then it is quite helpful to expand the first use of acronyms in each chapter to be expanded.

How do I achieve this behavior in LaTeX using the glossaries-extra package?

Here is a minimal example demonstrating the scenario. The desired behavior is also explained and highlighted in the resulting output.

\documentclass{report}
\usepackage{glossaries-extra}
\setabbreviationstyle[acronym]{long-short}
\newacronym{tla}{TLA}{three letter acronym}

\begin{document}

\chapter{Introduction}
Hello world. We have too many \gls{tla}. The acronym in the previous sentence shall expand.

Note that the second  usage here \gls{tla} will not expand,  and is the expected
(and correct) behavior.

\chapter{Important Stuff}
The \gls{tla} acronym has been expanded  before. But since the reader might read
this chapter first, it is nice to  have its first usage in the previous sentence
expand.

Note that the second  usage here \gls{tla} will not expand,  and is the expected
(and correct) behavior.

\end{document}


The output is

The simplest method is to insert \glsresetall at the start of each chapter. Since etoolbox is automatically loaded (by the base glossaries package), you can use etoolbox's \preto command:

\documentclass{report}
\usepackage{glossaries-extra}

\preto\chapter{\glsresetall}

\setabbreviationstyle[acronym]{long-short}
\newacronym{tla}{TLA}{three letter acronym}

\begin{document}

\chapter{Introduction}
Hello world. We have too many \gls{tla}. The acronym in the previous sentence shall expand.

Note that the second  usage here \gls{tla} will not expand,  and is the expected
(and correct) behavior.

\chapter{Important Stuff}
The \gls{tla} acronym has been expanded  before. But since the reader might read
this chapter first, it is nice to  have its first usage in the previous sentence
expand.

Note that the second  usage here \gls{tla} will not expand,  and is the expected
(and correct) behavior.

\end{document}


If you use a different class (such as memoir or scrbook) there may be a convenient hook provided that can be used instead. If you want to limit the reset to just a particular glossary type, you can use the optional argument of \glsresetall.

• Wow. An answer from the package creator itself. Thank you very much. May I request to consider this as a feature request (i.e. an option to the package) for future versions of glossaries-extra? It is not too unusual to expect this type of behavior in long documents such as books or theses? – Krishna Jun 9 '18 at 11:27