Closed Junjie-Chu closed 3 months ago
A good catch, thanks. I introduced this mistake in https://github.com/tml-epfl/llm-adaptive-attacks/commit/f82e6f9a0e45f314cf3c7b4eb2c1325a4728401d when I was refactoring the code for Vicuna and Llama.
It should be fixed now in https://github.com/tml-epfl/llm-adaptive-attacks/commit/43a49412ece9200a90d7ecfd8ddabeb30bbcafb9. I.e., formatted_prompt
should be just conv.get_prompt()
.
In conversers.py, about vicuna part, the formatted_prompt has not been defined yet.
elif "vicuna" in self.model_name: conv.append_message(conv.roles[1], None) full_prompts.append(formatted_prompt)