## 4 Discussion  
The _Maskteeer_ algorithm represents an efficient tool that pseudonymizes unstructured free text written by authors of different professional backgrounds in colloquial German  
Figure 3: Runtime of Maskteer 2.0 depending on (**a**) note length and (**b**) corpus size. \begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Metric** & _Maskteeer 1.0_ & \multicolumn{2}{c}{**spaCy**} & \multicolumn{2}{c}{_Maskteeer 2.0_} \\  & **Result** & **Result** & **95\% CI** & **Result** & **95\% CI** \\ \hline Accuracy & 84\% & 40.21\% & [36.15–44.38\%] & 93.99\% & [90.77–96.34\%] \\ \hline Specificity & 0.62 & 0.804 & [0.749–0.851] & 0.933 & [0.859–0.975] \\ \hline Sensitivity & 0.94 & 0.082 & [0.057–0.121] & 0.943 & [0.904–0.969] \\ \hline Precision & n/a * & 0.409 & [0.262–0.461] & 0.973 & [0.943–0.987] \\ \hline \hline \end{tabular}  
* The precision of _Maskteer 1.0_ is not available since it had not been investigated in [20].  
\end{table} 
Table 8: Pseudonymization performance of three algorithms: (1) precursor _Maskteeer 1.0_[25], (2) out-of-the-box spaCy NER, and (3) _Maskteer 2.0_ as described in the present work. language, in a medical context, including the heavy use of abbreviations and nicknames, and with frequent typing errors. The evaluation of the algorithm yielded high performance (Table 8), outperforming both an earlier version (1.0) and a third-party tool (spaCy). The low sensitivity observed in spaCy can likely be attributed to the fact that the texts used for the model were from a foreign domain (news articles) and therefore not accustomed to the nature of clinical notes. Salutations were the most important factor (see Table 7), which were not optimized in spaCy for colloquial medical language. However, specificity was less affected in the spaCy algorithm, even showing a better false-negative rate than the 1.0 version of _Masketeer_. The most common source for false negatives in the current version (_Masketeer 2.0_) was either extremely rare names that were not in any dictionary and occurred without salutation or typing mistakes in names that were therefore not found by any _Masker_. Naturally, manually written text, especially under the conditions in which our medical texts were written (e.g., time constraints, transcription of verbally transmitted names, diverse educational background, diverging first languages of authors, and no implemented grammar/spelling checks), is imperfect, and thus, algorithms are unlikely to perfectly mask all identifiable PHI from them. In fact, assessing correct de-identification was challenging during evaluation even for human observers in rare cases. Therefore, setting a general performance threshold to determine whether a pseudonymization algorithm is sufficient is unfeasible and depends on the underlying problem. For our purposes, _Masketeer's_ performance was satisfactory. De-identifying the clinical notes opens up possibilities for secondary analyses of the texts. For example, the de-identified note texts could be processed without privacy concerns by NLP and AI experts to extract crucial information valuable for developing predictive models that could be used to anticipate major adverse events from text data. Furthermore, de-identifying the notes could enable the application of popular, publicly available, and powerful LLMs (e.g., ChatGPT, Gemini), which cannot be utilized with personalized notes due to privacy regulations. These LLMs could, for example, derive patient summaries from the notes for the time-efficient rotation of healthcare personnel, ultimately leaving more time for patient care. LLMs could also extract information from the notes to fill gaps in electronic medical records (e.g., missing medication list) or extract and save data in a structured form, which is often exchanged only as free text (e.g., laboratory results). In general, there seem to be two main approaches to removing identifiable text from medical free text in the literature.