Merge pull request #843 from JeLuF/prompthook

Add hook to implement custom prompt preprocessors
This commit is contained in:
cmdr2 2023-02-10 17:18:06 +05:30 committed by GitHub
commit baa8afd9eb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 0 deletions

View File

@ -1020,6 +1020,8 @@ function getPrompts(prompts) {
promptsToMake = applyPermuteOperator(promptsToMake)
promptsToMake = applySetOperator(promptsToMake)
PLUGINS['GET_PROMPTS_HOOK'].forEach(fn => { promptsToMake = fn(promptsToMake) })
return promptsToMake
}

View File

@ -25,6 +25,7 @@ const PLUGINS = {
* })
*/
IMAGE_INFO_BUTTONS: [],
GET_PROMPTS_HOOK: [],
MODIFIERS_LOAD: [],
TASK_CREATE: [],
OUTPUTS_FORMATS: new ServiceContainer(