Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default Output Trigger Regex seems incorrect #11

Closed
TheInvisibleMage opened this issue Jan 3, 2024 · 2 comments
Closed

Default Output Trigger Regex seems incorrect #11

TheInvisibleMage opened this issue Jan 3, 2024 · 2 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@TheInvisibleMage
Copy link

TheInvisibleMage commented Jan 3, 2024

Description

The default stable_diffusion-interactive_mode_output_trigger_regex within settings.debug.yaml (currently " .[(\b.+?\b(image|pic(ture)?|photo|snap(shot)?|selfie|meme)(s?)") seems to have an issue: The "[*([]" block appears to be searching for those characters directly, which are unlikely to appear in most output most strings, causing image output to almost always be prevented.

Caveats

  • I'm not familiar enough with regex to tell exactly what that block is trying to accomplish. However, I can confirm that it is the cause of the match failing; see images below.

  • Before:
    image

  • After manually changing pattern to remove block:
    image

  • As this is a default, it is already easily changed, but modifying the default directly would likely help prevent confusion

Additional Suggestions

Adding "draws|paints|creates" to the first group here would help increase the chances of image production when it would make sense to occur.

Why not just make a PR?

I want to confirm what the intended behavior of that block is before I go about pulling it out.

@TheInvisibleMage
Copy link
Author

TheInvisibleMage commented Jan 3, 2024

Oddly enough, reviewing my message has given me an indication; The "[*([]" block appears to be used to hide text, presumably to hide the SD prompts from the user. Will close this issue; the regex is likely fine, and the lack of hidden SD prompts coming through is a separate issue.

@Trojaner
Copy link
Owner

Trojaner commented Jan 3, 2024

The [*([] block is used to specify that the message should start with a *, ( or [ as the models I use often generate messages such as: *Sends an image of ...*.

Regex-wise, it just a simple [xyz]-style character group containing these symbols. You can make this optional by appending a ? at the end of it, like this: [*([]?

It makes sense to remove this block (or make it optional) and append the draws|paints|creates keywords, so I am reopening the issue.

@Trojaner Trojaner reopened this Jan 3, 2024
@Trojaner Trojaner added enhancement New feature or request good first issue Good for newcomers labels Jan 3, 2024
@Trojaner Trojaner closed this as completed Jan 7, 2024
Trojaner added a commit that referenced this issue Jan 7, 2024
- Add support for FaceID feature of SD.Next
- Add support for IP Adapters feature of SD.Next
- Add hires.fix related params
- Update default generation params to what RealisiticVision v6.B recommends
- Rename "enhace_face" related params to "restore_face"
- Fix some params not updating via UI, especially params set to default value and params of type boolean or enum
- Fix UI wrongly setting password as endpoint
- Fix UI wrongly setting username as endpoint
- Fix some AUTOMATIC1111 related API incompatibilities
- Fix trigger on output message, fixes #11
- Fix multithreading issues related to context, fixes #13
- Fix full_quality param not set for SD.Next
- Fix missing trace log when errors are logged
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants