% arara: pdflatex
% arara: makeglossaries
% arara: pdflatex
\documentclass{article}

\usepackage{glossaries-extra}
\usepackage{glossaries-prefix}

\makeglossaries

\newabbreviation
 [prefix={an\space},
 prefixfirst={a~}]
 {svm}{SVM}{support vector machine}

\begin{document}

This is a sample document to test prefixes.
First use: \pgls{svm}.
Next use: \pgls{svm}.

\printglossaries

\end{document}
