Summary
This work proposes a toxicity detection method for LLMs that incurs negligible additional inference cost, and shows superior performance compared with two existing methods. The main observation of this work is that the logits of the first generated token (after prompt) are informative about toxicity of the prompt. The authors propose 2 baseline methods, PoR (crude probability of refusal) and PoRT (probability of refusal according to the logits of a pre-selected token, eg. "sorry"). They show that PoRT is effective, paving the path to their flagship method MULI.
In MULI, a sparse logistic regression classifier is trained on top of the first token logits. L1 regularization on the weights is applied, as well as a non-linear function on the logits (ablations for both the regularization strength and the non-linear function are provided).
MULI shows excellent performance compared with LlamaGuard and OMod, with lower computational complexity. The improvement over these methods supposes a jump in performance in toxicity detection. MULI also shows more robustness than the other methods to modality shifts (tested with 2 toxicity datasets).
Strengths
*Originality:*
* This work proposes simple yet original solution to toxicity detection. Analyzing the logits of the first token is surprisingly effective, sound and simple.
*Quality:*
* This work contains experimental results on 2 toxicity datasets, a comparison with 2 existing methods and a comparison among several LLMs. The experimental setup is of great quality.
* I really appreciated the experiment comparing LLMs (fig 6) and the ablation of dataset size to estimate MULI (fig 7).
*Clarity:*
* The paper is well written, all the proposed evaluations and methods are sound and well explained.
*Significance:*
* This work tackles the important topic of toxicity detection in intruction-tuned LLMs. This is an important topic nowadays, since practically the everyone is using LLMs in daily life, with millions of queries per day. Being able to better distinguish toxic queries from non-toxic with low computational methods is key to improve quality and also to reduce costs associated with LLM inference.
Weaknesses
*Quality:*
* One possible weakness is the lack of justification to analyze the first token only. I missed some discussion on how is this token "attending" to the prompt or how can this method fail? Intuitively, this method can suffer from adversarially designed prompts, some analysis in this sense would be interesting. In general, a limitations section is missing.
Questions
* One question that immediately came to my mind while reading is what happens beyond the first token logits. My intuition is that including the 2nd token would disambiguate many more answers. I believe the same MULI formulation could be applied to the 2nd token by appending the 2nd token logits to the 1st token ones, and using that 2x larger vector to train the logistic regression. Some discussion on this would be great.
* I missed some discussion on the possible jailbraking of MULI. How could MULI suffer from adversarially designed prompts, such that they are toxic but can deceive the logistic regression?
* How does MULI perform with sub-work tokenizers, or tokenizers that strongly split words? In general, how is MULI impacted by the tokenizer, since only the 1st token is used.
---
**Overall comment:**
Despite the method's simplicity, it provides excellent results and major improvement in terms of compute. I find this combination very interesting, being able to combine simplicity and a leap forward in terms of results is hard to achieve. Moreover, the experimental results are solid and reproducable. Overall, I find this paper of good quality for NeurIPs and I recommend acceptance.
Limitations
The authors mention that the method limitations are discussed in Section 7 (conclusion). However, section 7 only contains: _"Nevertheless, there are limitations, as the information hidden in the output of LLMs is much more than what we extract by MULI. It encourages researchers to look deeper into the information hidden in LLMs in the future."_
I encourage the authors to include a dedicated limitations section, with discussion on the topics mentioned in previous sections of this review. For example, how MULI could be jailbroken, limitation of using only the 1st token vs more, etc. Additionally, the authors should expand on _"the information hidden in the output of LLMs is much more than what we extract by MULI"_. What, in the authors opinion, could be extracted that MULI does not?
Please, take these only as constructive suggestions.