All Downloads are FREE. Search and download functionalities are using the official Maven repository.

fi.evolver.ai.spring.provider.replicate.ReplicateRequestParameters Maven / Gradle / Ivy

package fi.evolver.ai.spring.provider.replicate;

public final class ReplicateRequestParameters {

	/**
	 * Random seed. Set for reproducible generation
	 */
	public static final String SEED = "seed";

	/**
	 * Number of outputs to generate
	 */
	public static final String NUM_OUTPUTS = "num_outputs";

	/**
	 * Format of the output images.
	 * Options: "webp", "jpg" or "png". Default: "png"
	 */
	public static final String OUTPUT_FORMAT = "output_format";

	/**
	 * Quality when saving the output images, from 0 to 100. 100 is best quality, 0
	 * is lowest quality. Not relevant for .png outputs
	 */
	public static final String OUTPUT_QUALITY = "output_quality";

	/**
	 * Approximate number of megapixels for generated image. Only 1 or 0.25
	 * supported as of 15.10.2024. Default: 1
	 */
	public static final String MEGAPIXELS = "megapixels";

	/**
	 * Run faster predictions with model optimized for speed (currently fp8
	 * quantized); disable to run in original bf16. Default: true
	 */
	public static final String GO_FAST = "go_fast";

	/**
	 * Controls the balance between adherence to the text prompt and image
	 * quality/diversity. Higher values make the output more closely match the
	 * prompt but may reduce overall image quality. Lower values allow for more
	 * creative freedom but might produce results less relevant to the prompt. Only
	 * supported by Flux dev
	 */
	public static final String GUIDANCE = "guidance";

	/**
	 * Aspect ratio for the generated image.
	 * Options (Dev and Schnell): "1:1", "16:9", "21:9", "2:3", "3:2", "4:5", "5:4",
	 * "9:16", "9:21"
	 * Options (Pro): "1:1", "16:9", "2:3", "3:2", "4:5", "5:4", "9:16"
	 */
	public static final String ASPECT_RATIO = "aspect_ratio";

	/**
	 * Prompt strength when using img2img. 1.0 corresponds to full destruction of
	 * information in image
	 */
	public static final String PROMPT_STRENGTH = "prompt_strength";

	/**
	 * Number of denoising steps. Recommended range is 28-50
	 */
	public static final String NUM_INTERFERENCE_STEPS = "num_inference_steps";

	/**
	 * Disable safety checker for generated images
	 */
	public static final String DISABLE_SAFETY_CHECKER = "disable_safety_checker";

	/**
	 * Number of diffusion steps.
	 * Min 1, max 50, default 25
	 * 
	 * @deprecated Not supported anymore with Flux 1.1 pro
	 */
	@Deprecated
	public static final String STEPS = "steps";

	/**
	 * Interval is a setting that increases the variance in possible outputs letting
	 * the model be a tad more dynamic in what outputs it may produce in terms of
	 * composition, color, detail, and prompt interpretation. Setting this value low
	 * will ensure strong prompt following with more consistent outputs, setting it
	 * higher will produce more dynamic or varied outputs.
	 * Min 1, max 4, default 2
	 * 
	 * @deprecated Not supported anymore with Flux 1.1 pro
	 */
	@Deprecated
	public static final String INTERVAL = "interval";

	/**
	 * Safety tolerance, 1 is most strict and 5 is most permissive
	 */
	public static final String SAFETY_TOLERANCE = "safety_tolerance";

	/**
	 * Automatically modify the prompt for more creative generation
	 */
	public static final String PROMPT_UPSAMPLING = "prompt_upsampling";
	
	/**
	 * Width of the generated image in text-to-image mode. Only used when aspect_ratio=custom. Must be a multiple of 32 (if it's not, it will be rounded to nearest multiple of 32).
	 */
	public static final String WIDTH = "width";
	
	/**
	 * Height of the generated image in text-to-image mode. Only used when aspect_ratio=custom. Must be a multiple of 32 (if it's not, it will be rounded to nearest multiple of 32).
	 */
	public static final String HEIGHT = "height";
	
	/**
	 * Generate less processed, more natural-looking images
	 */
	public static final String RAW = "raw";

	private ReplicateRequestParameters() { /* Utility class */ }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy