sd-dynamic-prompts icon indicating copy to clipboard operation
sd-dynamic-prompts copied to clipboard

Is there a way to weight the line items in a YAML file?

Open demoran23 opened this issue 1 year ago • 5 comments

I'd like to have one of the items in the array be used more often than the others.

demoran23 avatar Aug 28 '23 02:08 demoran23

try this

{
  2::red
  | 3::blue
  | 1:: green
}

adieyal avatar Aug 28 '23 09:08 adieyal

That would be to weight the tokens usage in a particular line item. I want to weight the usage of the line item itself.

demoran23 avatar Aug 28 '23 10:08 demoran23

Could you elaborate? Perhaps provide an example prompt? In the example above, blue would be chosen 50% of the time red 33% of the time and green 17%

If you want to weight a wildcard, you could do something like:

{0.7::__warm_colors__|0.3::__cold_colors__}

Is that what you mean?

adieyal avatar Aug 28 '23 10:08 adieyal

The yaml file might look like this:

demoran:
  - line item 1
  - line item 2

I want to have line item one selected more often than line item 2 when prompting __demoran__.

demoran23 avatar Aug 28 '23 11:08 demoran23

I wish this worked:

demoran:
  - 3::line item 1
  - 2::line item 2

acorderob avatar Sep 20 '23 14:09 acorderob