diff --git a/packages/core/src/generation.ts b/packages/core/src/generation.ts index 167ee9447f..6e99bc63a4 100644 --- a/packages/core/src/generation.ts +++ b/packages/core/src/generation.ts @@ -935,6 +935,8 @@ export const generateImage = async ( seed?: number; modelId?: string; jobId?: string; + stylePreset?: string; + hideWatermark?: boolean; }, runtime: IAgentRuntime ): Promise<{ @@ -1121,9 +1123,12 @@ export const generateImage = async ( model: data.modelId || "fluently-xl", prompt: data.prompt, negative_prompt: data.negativePrompt, - width: data.width || 1024, - height: data.height || 1024, - steps: data.numIterations || 20, + width: data.width, + height: data.height, + steps: data.numIterations, + seed: data.seed, + style_preset: data.stylePreset, + hide_watermark: data.hideWatermark, }), } ); diff --git a/packages/core/src/types.ts b/packages/core/src/types.ts index 6fafa4ede8..5f83e29c66 100644 --- a/packages/core/src/types.ts +++ b/packages/core/src/types.ts @@ -718,6 +718,8 @@ export type Character = { modelId?: string; jobId?: string; count?: number; + stylePreset?: string; + hideWatermark?: boolean; }; voice?: { model?: string; // For VITS diff --git a/packages/plugin-image-generation/src/index.ts b/packages/plugin-image-generation/src/index.ts index 4600fb3a3d..1be67fca92 100644 --- a/packages/plugin-image-generation/src/index.ts +++ b/packages/plugin-image-generation/src/index.ts @@ -109,6 +109,8 @@ const imageGeneration: Action = { seed?: number; modelId?: string; jobId?: string; + stylePreset?: string; + hideWatermark?: boolean; }, callback: HandlerCallback ) => { @@ -140,6 +142,8 @@ const imageGeneration: Action = { ...(options.seed != null || imageSettings.seed != null ? { seed: options.seed || imageSettings.seed } : {}), ...(options.modelId != null || imageSettings.modelId != null ? { modelId: options.modelId || imageSettings.modelId } : {}), ...(options.jobId != null || imageSettings.jobId != null ? { jobId: options.jobId || imageSettings.jobId } : {}), + ...(options.stylePreset != null || imageSettings.stylePreset != null ? { stylePreset: options.stylePreset || imageSettings.stylePreset } : {}), + ...(options.hideWatermark != null || imageSettings.hideWatermark != null ? { hideWatermark: options.hideWatermark || imageSettings.hideWatermark } : {}), }, runtime );