werk1112

Image CLI commands and options

Build scope: canonical Linux, --no-default-features, no optional backend features. Coverage is limited to this parser/schema profile, not every platform or feature build. See conditional build options for extensions.

Generated from werk 1.10.2. See CLI semantics, media input and override rules, and the canonical parameter schema.

Every command below also accepts global options and --help. Each command lists its additional accepted options; the catalogue below gives their syntax and meaning. A parsed flag does not imply that a particular model/backend implements it.

Commands

werk image

Generate, edit, or upscale images

werk image [OPTIONS] <COMMAND>

Subcommands: werk image generate, werk image edit, werk image upscale.

werk image generate

Generate images with an installed model

werk image generate [OPTIONS] <MODEL>

Arguments:

<MODEL>

Additional options:

werk image edit

Edit or inpaint an image with an installed model

werk image edit [OPTIONS] --image <PATH> <MODEL>

Arguments:

<MODEL>

Additional options:

werk image upscale

Upscale an image with an installed model

werk image upscale [OPTIONS] --image <PATH> <MODEL>

Arguments:

<MODEL>

Additional options:

Option catalogue

Syntax ending in ... accepts repeated values. List controls also accept repeated occurrences of their flag. Boolean pairs inherit when omitted; positive and negative flags conflict. Schema defaults, units, types and task applicability are in the linked parameter table.

--accelerator

--accelerator <ACCELERATOR>

Requested accelerator, for example cpu, cuda, rocm, metal, or auto

--adapter-end

--adapter-end <ADAPTER_END>

Adapter end (runtime/model-defined control); number image.adapter_end.

--adapter-start

--adapter-start <ADAPTER_START>

Adapter start (runtime/model-defined control); number image.adapter_start.

--adapter-weight

--adapter-weight <ADAPTER_WEIGHT>

Adapter weight (runtime/model-defined control); number image.adapter_weight.

--allow-component-offload

--allow-component-offload

Permit component offload when GPU memory is insufficient and projected host RAM fits

--allow-cpu-offload

--allow-cpu-offload

Permit model CPU offload when GPU memory is insufficient and the projected host-RAM requirement fits

--allow-disk-offload

--allow-disk-offload

Allow disk-backed model offloading; boolean routing.allow_disk_offload.

--allow-sequential-offload

--allow-sequential-offload

Permit slower sequential CPU offload when GPU memory is insufficient and projected host RAM fits

--aspect-ratio

--aspect-ratio <ASPECT_RATIO>

Aspect ratio (runtime/model-defined control); string image.aspect_ratio.

--attention-backend

--attention-backend <ATTENTION_BACKEND>

Requested attention implementation

--batch-size

--batch-size <BATCH_SIZE>

Images processed per batch; integer image.batch_size.

--clip-skip

--clip-skip <CLIP_SKIP>

Clip skip (runtime/model-defined control); integer image.clip_skip.

--color-correction

--color-correction

Color correction (runtime/model-defined control); boolean image.color_correction.

--color-preservation

--color-preservation <COLOR_PRESERVATION>

Color preservation (runtime/model-defined control); number image.color_preservation.

--compile

--compile

Explicitly enable runtime compilation

--composition-preservation

--composition-preservation <COMPOSITION_PRESERVATION>

Composition preservation (runtime/model-defined control); number image.composition_preservation.

--control-end

--control-end <CONTROL_END>

Control end (runtime/model-defined control); number image.control_end.

--control-model

--control-model <CONTROL_MODEL>

Control model (runtime/model-defined control); path image.control_model.

--control-preprocessor

--control-preprocessor <CONTROL_PREPROCESSOR>

Control preprocessor (runtime/model-defined control); string image.control_preprocessor.

--control-start

--control-start <CONTROL_START>

Control start (runtime/model-defined control); number image.control_start.

--control-type

--control-type <CONTROL_TYPE>

Control type (runtime/model-defined control); string image.control_type.

--control-weight

--control-weight <CONTROL_WEIGHT>

Control weight (runtime/model-defined control); number image.control_weight.

--crop-mode

--crop-mode <CROP_MODE>

Crop mode (runtime/model-defined control); enumeration image.crop_mode.

--debug

--debug

Print the resolved media request, routing candidates, and backend details

--denoise-strength

--denoise-strength <DENOISE_STRENGTH>

Denoise strength (runtime/model-defined control); number image.denoise_strength.

--dynamic-shift

--dynamic-shift

Dynamic shift (runtime/model-defined control); boolean image.dynamic_shift.

--eta

--eta <ETA>

Eta (runtime/model-defined control); number image.eta.

--face-restoration

--face-restoration

Face restoration (runtime/model-defined control); boolean image.face_restoration.

--fallback-policy

--fallback-policy <FALLBACK_POLICY>

Fallback policy: none, backend, or degrade; degrade permits inherited memory-saving strategies

--guidance

--guidance <GUIDANCE>

Classifier-free guidance scale; number image.guidance.

--guidance-rescale

--guidance-rescale <GUIDANCE_RESCALE>

Guidance rescale (runtime/model-defined control); number image.guidance_rescale.

--height

--height <HEIGHT>

Output height in pixels; integer image.height.

--high-resolution-fix

--high-resolution-fix

High resolution fix (runtime/model-defined control); boolean image.high_resolution_fix.

--identity-preservation

--identity-preservation <IDENTITY_PRESERVATION>

Identity preservation (runtime/model-defined control); number image.identity_preservation.

--image

--image <PATH>

Source image; required where shown in the command usage. Path, HTTP(S) URL or Base64 data URL.

--image-adapter

--image-adapter <SPEC>

Repeatable item for: Adapters (runtime/model-defined control); list image.adapters.

--image-adapter-file

--image-adapter-file <PATH>

Load JSON from a UTF-8 file for: Adapters (runtime/model-defined control); list image.adapters.

--image-adapter-json

--image-adapter-json <JSON>

Load JSON from the argument for: Adapters (runtime/model-defined control); list image.adapters.

--image-control

--image-control <SPEC>

Repeatable item for: Controls (runtime/model-defined control); list image.controls.

--image-control-file

--image-control-file <PATH>

Load JSON from a UTF-8 file for: Controls (runtime/model-defined control); list image.controls.

--image-control-json

--image-control-json <JSON>

Load JSON from the argument for: Controls (runtime/model-defined control); list image.controls.

--image-lora

--image-lora <SPEC>

Repeatable item for: Loras (runtime/model-defined control); list image.loras.

--image-lora-file

--image-lora-file <PATH>

Load JSON from a UTF-8 file for: Loras (runtime/model-defined control); list image.loras.

--image-lora-json

--image-lora-json <JSON>

Load JSON from the argument for: Loras (runtime/model-defined control); list image.loras.

--image-strength

--image-strength <IMAGE_STRENGTH>

Image strength (runtime/model-defined control); number image.image_strength.

--image-vae-slicing

--image-vae-slicing

Slice VAE batches; boolean image.vae_slicing.

--image-vae-tiling

--image-vae-tiling

Tile VAE encode and decode; boolean image.vae_tiling.

--init-image

--init-image <PATH_OR_URL>

Initial image for editing; a mask additionally selects inpainting. Path, HTTP(S) URL or Base64 data URL.

--inpaint-area

--inpaint-area <INPAINT_AREA>

Inpaint area (runtime/model-defined control); enumeration image.inpaint_area.

--mask

--mask <PATH>

Mask image; requires an initial/source image. See task selection and input roles in media rules.

--mask-blur

--mask-blur <MASK_BLUR>

Mask blur (runtime/model-defined control); number image.mask_blur.

--mask-expand

--mask-expand <MASK_EXPAND>

Mask expand (runtime/model-defined control); integer image.mask_expand.

--mask-fill

--mask-fill <MASK_FILL>

Mask fill (runtime/model-defined control); enumeration image.mask_fill.

--mask-invert

--mask-invert

Mask invert (runtime/model-defined control); boolean image.mask_invert.

--negative-prompt

--negative-prompt <NEGATIVE_PROMPT>

Negative prompt text

--negative-prompt-file

--negative-prompt-file <PATH>

Read negative prompt text from a file

--no-allow-component-offload

--no-allow-component-offload

Forbid component offload

--no-allow-cpu-offload

--no-allow-cpu-offload

Forbid model CPU offload; an over-limit GPU plan fails unless another strategy is explicitly permitted

--no-allow-disk-offload

--no-allow-disk-offload

Explicitly disable: Allow disk-backed model offloading; boolean routing.allow_disk_offload.

--no-allow-sequential-offload

--no-allow-sequential-offload

Forbid sequential CPU offload

--no-color-correction

--no-color-correction

Explicitly disable: Color correction (runtime/model-defined control); boolean image.color_correction.

--no-compile

--no-compile

Explicitly disable runtime compilation

--no-dynamic-shift

--no-dynamic-shift

Explicitly disable: Dynamic shift (runtime/model-defined control); boolean image.dynamic_shift.

--no-face-restoration

--no-face-restoration

Explicitly disable: Face restoration (runtime/model-defined control); boolean image.face_restoration.

--no-high-resolution-fix

--no-high-resolution-fix

Explicitly disable: High resolution fix (runtime/model-defined control); boolean image.high_resolution_fix.

--no-image-vae-slicing

--no-image-vae-slicing

Explicitly disable: Slice VAE batches; boolean image.vae_slicing.

--no-image-vae-tiling

--no-image-vae-tiling

Explicitly disable: Tile VAE encode and decode; boolean image.vae_tiling.

--no-mask-invert

--no-mask-invert

Explicitly disable: Mask invert (runtime/model-defined control); boolean image.mask_invert.

--no-preserve-unmasked

--no-preserve-unmasked

Explicitly disable: Preserve unmasked (runtime/model-defined control); boolean image.preserve_unmasked.

--no-tiled-decode

--no-tiled-decode

Explicitly disable: Tiled decode (runtime/model-defined control); boolean image.tiled_decode.

--no-tiled-encode

--no-tiled-encode

Explicitly disable: Tiled encode (runtime/model-defined control); boolean image.tiled_encode.

--noise-strength

--noise-strength <NOISE_STRENGTH>

Noise strength (runtime/model-defined control); number image.noise_strength.

--num-images

--num-images <NUM_IMAGES>

Number of output images

--output

--output <PATH>

Output file or directory; defaults to WERK_HOME/outputs with a generated name

--output-format

--output-format <OUTPUT_FORMAT>

Output file format

--padding

--padding <PADDING>

Padding (runtime/model-defined control); integer image.padding.

--parameter-policy

--parameter-policy <PARAMETER_POLICY>

Parameter support policy: strict, warn, or permissive

--performance-preference

--performance-preference <PERFORMANCE_PREFERENCE>

Performance preference, for example speed, balanced, memory, or quality

--post-upscale

--post-upscale <POST_UPSCALE>

Post upscaling (runtime/model-defined control); string image.post_upscaling.

--precision

--precision <PRECISION>

Requested compute precision

--prediction-type

--prediction-type <PREDICTION_TYPE>

Prediction type (runtime/model-defined control); string image.prediction_type.

--preserve-unmasked

--preserve-unmasked

Preserve unmasked (runtime/model-defined control); boolean image.preserve_unmasked.

--profile

--profile <PROFILE>

Stored or built-in execution profile

--prompt

--prompt <PROMPT>

Prompt text

--prompt-file

--prompt-file <PATH>

Read prompt text from a file

--prompt-token-limit

--prompt-token-limit <PROMPT_TOKEN_LIMIT>

Prompt token limit (runtime/model-defined control); integer image.prompt_token_limit.

--prompt-weighting

--prompt-weighting <PROMPT_WEIGHTING>

Prompt weighting (runtime/model-defined control); string image.prompt_weighting.

--quality

--quality <QUALITY>

Quality profile

--quantization

--quantization <QUANTIZATION>

Requested quantization

--reference-end

--reference-end <REFERENCE_END>

Reference end (runtime/model-defined control); number image.reference_end.

--reference-image

--reference-image <PATH_OR_URL>

Repeatable item for: Reference images (runtime/model-defined control); list image.reference_images.

--reference-image-file

--reference-image-file <PATH>

Load JSON from a UTF-8 file for: Reference images (runtime/model-defined control); list image.reference_images.

--reference-image-json

--reference-image-json <JSON>

Load JSON from the argument for: Reference images (runtime/model-defined control); list image.reference_images.

--reference-start

--reference-start <REFERENCE_START>

Reference start (runtime/model-defined control); number image.reference_start.

--reference-weight

--reference-weight <REFERENCE_WEIGHT>

Reference weight (runtime/model-defined control); number image.reference_weight.

--refiner

--refiner <REFINER>

Refiner (runtime/model-defined control); path image.refiner.

--refiner-switch-point

--refiner-switch-point <REFINER_SWITCH_POINT>

Refiner switch point (runtime/model-defined control); number image.refiner_switch_point.

--resize-mode

--resize-mode <RESIZE_MODE>

Resize mode (runtime/model-defined control); enumeration image.resize_mode.

--rho

--rho <RHO>

Rho (runtime/model-defined control); number image.rho.

--safety-checker-policy

--safety-checker-policy <SAFETY_CHECKER_POLICY>

Safety checker policy (runtime/model-defined control); enumeration image.safety_checker_policy.

--sampler

--sampler <SAMPLER>

Sampler (runtime/model-defined control); string image.sampler.

--scheduler

--scheduler <SCHEDULER>

Scheduler (runtime/model-defined control); string image.scheduler.

--second-denoise

--second-denoise <SECOND_DENOISE>

Second denoise (runtime/model-defined control); number image.second_denoise.

--second-sampler

--second-sampler <SECOND_SAMPLER>

Second sampler (runtime/model-defined control); string image.second_sampler.

--second-scheduler

--second-scheduler <SECOND_SCHEDULER>

Second scheduler (runtime/model-defined control); string image.second_scheduler.

--seed

--seed <SEED>

Random seed; integer image.seed.

--set

--set <PATH=VALUE>

Set an advanced raw override; may be repeated

--shift

--shift <SHIFT>

Shift (runtime/model-defined control); number image.shift.

--sigma

--sigma <SIGMAS>

Repeatable item for: Sigmas (runtime/model-defined control); list image.sigmas.

--sigma-max

--sigma-max <SIGMA_MAX>

Sigma max (runtime/model-defined control); number image.sigma_max.

--sigma-min

--sigma-min <SIGMA_MIN>

Sigma min (runtime/model-defined control); number image.sigma_min.

--steps

--steps <STEPS>

Denoising steps; integer image.steps.

--subseed

--subseed <SUBSEED>

Subseed (runtime/model-defined control); integer image.subseed.

--target-height

--target-height <TARGET_HEIGHT>

Target height (runtime/model-defined control); integer image.target_height.

--target-width

--target-width <TARGET_WIDTH>

Target width (runtime/model-defined control); integer image.target_width.

--text-encoder-weight

--text-encoder-weight <TEXT_ENCODER_WEIGHT>

Text encoder weight (runtime/model-defined control); number image.text_encoder_weight.

--tiled-decode

--tiled-decode

Tiled decode (runtime/model-defined control); boolean image.tiled_decode.

--tiled-encode

--tiled-encode

Tiled encode (runtime/model-defined control); boolean image.tiled_encode.

--timeout

--timeout <SECONDS>

Execution timeout in seconds

--transformer-weight

--transformer-weight <TRANSFORMER_WEIGHT>

Transformer weight (runtime/model-defined control); number image.transformer_weight.

--true-cfg

--true-cfg <TRUE_CFG>

True cfg (runtime/model-defined control); number image.true_cfg.

--upscale-scale

--upscale-scale <UPSCALE_SCALE>

Upscale scale (runtime/model-defined control); number image.upscale_scale.

--vae

--vae <MODEL_OR_PATH>

Vae (runtime/model-defined control); path image.vae.

--vae-precision

--vae-precision <VAE_PRECISION>

Vae precision (runtime/model-defined control); string image.vae_precision.

--variation-strength

--variation-strength <VARIATION_STRENGTH>

Variation strength (runtime/model-defined control); number image.variation_strength.

--verbose

--verbose

Print media-specific timing, runtime, and output statistics

--watermark-policy

--watermark-policy <WATERMARK_POLICY>

Watermark policy (runtime/model-defined control); enumeration image.watermark_policy.

--width

--width <WIDTH>

Output width in pixels; integer image.width.