Skip to content
New issue

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

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

Already on GitHub? # to your account

feat: Add Custom System Prompt Support for plugin-image-generation #839

Merged
merged 5 commits into from
Dec 28, 2024

Conversation

tsubasakong
Copy link
Contributor

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:

  1. Adding customSystemPrompt parameter to generateText function for image gen system prompt
  2. Implementing structured prompt engineering for image generation
  3. Creating detailed prompt generation guidelines with specific steps
  4. Setting up a standardized prompt structure for consistency
  5. 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 customSystemPrompt parameter in generateText
  • Image prompt structure and guidelines
  • Style customization options

Testing

Where should a reviewer start?

  1. Review the generateText changes in packages/core/src/generation.ts
  2. Check the image prompt system in image generation implementation
  3. 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

@odilitime odilitime changed the base branch from main to develop December 14, 2024 17:31
odilitime
odilitime previously approved these changes Dec 14, 2024
@odilitime
Copy link
Collaborator

SImple conflict that needs to be resolve, otherwise LGTM

@odilitime odilitime deleted the branch elizaOS:develop December 17, 2024 02:33
@odilitime odilitime closed this Dec 17, 2024
@odilitime odilitime reopened this Dec 17, 2024
@shakkernerd shakkernerd deleted the branch elizaOS:develop December 17, 2024 03:45
@odilitime odilitime reopened this Dec 17, 2024
@shakkernerd shakkernerd deleted the branch elizaOS:develop December 22, 2024 07:01
@odilitime odilitime reopened this Dec 22, 2024
@tsubasakong
Copy link
Contributor Author

I update to the latest "develop" branch and run the approval again. Seems no conflict?

Copy link
Member

@shakkernerd shakkernerd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is good work!

@shakkernerd shakkernerd merged commit bc5e50e into elizaOS:develop Dec 28, 2024
5 checks passed
1to3for5vi7ate9x pushed a commit to 1to3for5vi7ate9x/eliza that referenced this pull request Jan 26, 2025
feat: Add Custom System Prompt Support for plugin-image-generation
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants