representation-engineering icon indicating copy to clipboard operation
representation-engineering copied to clipboard

Steering/control vectors not working with Llama 3 chat models

Open rahulb99 opened this issue 8 months ago • 2 comments

Model: meta-llama/Meta-Llama-3-8B Code: examples/primary_emotions/emotion_concept.ipynb and others

coefficient: 1.0 to 3.0

Image Image

rahulb99 avatar Apr 14 '25 23:04 rahulb99

Have you solved this problem?

Winston-Yuan avatar May 11 '25 12:05 Winston-Yuan

Hi @Winston-Yuan @rahulb99 . Just for your information, you need to use the correct template for Meta-Llama-3.1-8B-Instruct:

template = "<|start_header_id|>user<|end_header_id|>\n\n {instruction} <eot_id><|start_header_id|>assistant<|end_header_id|>\n\n"

And in some cases, setting tokenizer.padding_side to right may cause the problem of generating "!!!!!!" which are actually eos_tokens

HenryCai11 avatar May 22 '25 07:05 HenryCai11