showlab/BoxDiff

How can I specify token index for muti words phrases like "Teddy Bear" or "Green T-shirt"?

Closed this issue · 2 comments

Hi! Thanks for the interesting work. I have a question about specifying token index for phrases (or say, class names) that contain multiple words and possibly symbols.

For instance, for a prompt like A teddy bear sitting next to a boy wearing a green T-shirt, if the concepts I want to alter are "teddy bear", "boy" or "green T-shirt", how can I specify token indices? Because we can only specify a single index such as 1 or 2 for a word, but these concepts contain multiple words.

Could you please help me to clarify this?

Thank you very much!

Hi, you can specify the tokens of 'nouns' like bear, and shirt

Got it. Thank you!