createImagePrompt_v2 {chatAI4R}R Documentation

Generate Image Prompts version 2

Description

Generates optimal prompts for creating images using the OpenAI API. Given a base prompt, image attributes, and model parameters, it generates the optimal prompts for image creation. This is an experimental function.

Usage

createImagePrompt_v2(
  Base_prompt = "",
  removed_from_image = "",
  stable_diffusion = "N/A",
  Model = "gpt-3.5-turbo-16k",
  len = 1000
)

Arguments

Base_prompt

A string. This is the base prompt that forms the basis for the generated prompts.

removed_from_image

A string. This is an attribute that should be removed from the image.

stable_diffusion

A string. This parameter is used to control the stability of the diffusion process.

Model

A string. This is the model used for generating the prompts. Default is "gpt-3.5-turbo-16k".

len

An integer. This is the maximum length of the generated prompts. Must be between 1 and 1000. Default is 1000.

Details

Generate Image Prompts version 2

Value

A vector of strings. Each string in the vector is a generated prompt.

Author(s)

Satoshi Kume

Examples

## Not run: 
# Define the base prompt and image attributes
base_prompt = "A sunset over a serene lake"
removed_from_image = "The sun"
stable_diffusion = "Moderate"

# Generate image prompts
res <- createImagePrompt_v2(Base_prompt = base_prompt, removed_from_image = removed_from_image,
stable_diffusion = stable_diffusion, len = 100)

# Print the generated prompts
print(res)

## End(Not run)

[Package chatAI4R version 0.2.10 Index]