Variables - altoiddealer/ad_discordbot GitHub Wiki

Syntax is {variable}


Variables can be used in:

  • Your prompts (including Spontaneous Messaging prompts)

  • The format_prompt tag (see Tags)

  • In any tag values nested in Flows feature tags (again, see Tags). Variables like {llm_0} can be very powerful via Flows, such as prompting a custom character and using its response as the value for anything in the next Flow Step, a future Flow Step, or your final output.


Example uses:

  • "Hey! It's {time}! What are you doing up so late?"
  • 'You just said earlier: "{llm_6}". Why are you contradicting yourself now?!'

Variable Will be replaced with:
{prompt} Your current prompt. Intended for use with the 'format_prompt' tag. This allows you to insert your prompt anywhere in a predefined text string.
{time} The current time
{date} The current date
{user_#} A recent user prompt. {user_0} represents the most recent user prompt. {user_9} is from 10 prompts ago.
{llm_#} A recent LLM response. {llm_0} represents the most recent LLM response. {llm_4} is from 4 responses ago.
{history_#} A recent message exchange. Similar to {user/llm_#}, except the messages are prefixed with the user and char names, and separated by new lines (\n)
{last_image} Shortcut for __temp/temp_img_0.png which will be the most recently generated image. Useful in Flows tag as a dynamic value for img2img or controlnet inputs.
{time_since_last_msg} The time since a message was sent by a user or bot, such as "24 seconds" or "2 hours and 5 minutes"

Note:

For {user/llm_#} and {history_#}, this is limited to the first 10 messages (0-9)