feat: Add Custom System Prompt Support for plugin-image-generation
Relates to:
Image generation quality improvement and prompt engineering
Risks
Low - Adds new optional parameter for system prompts and enhanced image prompt generation without modifying core functionality.
Background
What does this PR do?
This PR enhances the text generation system by:
- Adding
customSystemPromptparameter to generateText function for image gen system prompt - Implementing structured prompt engineering for image generation
- Creating detailed prompt generation guidelines with specific steps
- Setting up a standardized prompt structure for consistency
- Adding style-specific prompt customization
What kind of change is this?
Features (non-breaking change which adds functionality)
Why are we doing this?
To improve image generation quality by providing structured, detailed prompts that consider key aspects like:
- Main subject focus
- Environment and setting
- Lighting and atmosphere
- Color relationships
- Composition guidelines
- Style integration
Documentation changes needed?
My changes require a change to the project documentation to document:
- New
customSystemPromptparameter in generateText - Image prompt structure and guidelines
- Style customization options
Testing
Where should a reviewer start?
- Review the generateText changes in
packages/core/src/generation.ts - Check the image prompt system in image generation implementation
- Examine the structured prompt generation workflow
Detailed testing steps
I tested locally by running pnpm start with a new character that had ModelProviderName.HEURIST as the modelProvider and "direct" in the clients. Everything seemed to work well.
Deploy Notes
No special deployment steps required. Feature is automatically active when using the plugin-image-generation functionality.
Discord username
tao8617
SImple conflict that needs to be resolve, otherwise LGTM
I update to the latest "develop" branch and run the approval again. Seems no conflict?